[wpkg-users] uninstall software using WPKG (Ninnig, Alexander)

Casey Mirch cmirch at leadps.org
Tue May 10 18:54:25 CEST 2011

It may make more sense if you know that WPKG keeps a record on the client machine of what software it has installed.  That file is at %windir%\system32\wpkg.xml.  When wpkg.js runs on the machine, it reads hosts.xml, profiles.xml, and packages.xml (or their included directories) and determines what packages and versions should be installed.  If a package logged in the local system32\wpkg.xml is installed but is no longer specified for that host based on the server-side xml files, then wpkg.js runs the remove commands for that package.  There is not an explicit directive anywhere to "remove package x", nor is it necessary in normal circumstances.

If you were to run wpkg.js on a machine, then delete system32\wpkg.xml and change the server-side xml files so that the package no longer applies to that machine, and then run wpkg.js again, it would not remove the software.  In effect, WPKG would be unaware that the package is something it had installed and falls within its scope of management.

If you need WPKG to uninstall software that it never installed originally, you can create a package for that in a sort of reverse way.  Make checks that evaluate to true if the software is NOT present on the machine, and use the package's install commands to call your uninstaller routines.  

Casey Mirch

-----Original Message-----

Message: 6
Date: Tue, 10 May 2011 10:15:20 +0200
From: "Ninnig, Alexander" <Alexander.Ninnig at rechnungshof.rlp.de>
To: <wpkg-users at lists.wpkg.org>
Subject: Re: [wpkg-users] uninstall software using WPKG
	<827211DCBA63E646B18B98F735ABE474012D88A3 at rh-sp-02.rhdomain.rechnungshof.rlp.de>
Content-Type: text/plain;	charset="iso-8859-1"

Hi John,

thank you very much.

I understand your answer in the following way:
Eachs package that exists and is not assigned to a profile will get uninstalled on all clients, that are assigned to this profile.

Is that right?


Alexander Ninnig

-----Urspr?ngliche Nachricht-----
Von: John Danks [mailto:john.danks at gmail.com] 
Gesendet: Montag, 9. Mai 2011 17:18
An: Ninnig, Alexander
Cc: wpkg-users at lists.wpkg.org
Betreff: Re: [wpkg-users] uninstall software using WPKG

Remove the package line from the profile in profiles.xml.

On Mon, May 9, 2011 at 6:56 AM, Ninnig, Alexander <Alexander.Ninnig at rechnungshof.rlp.de> wrote:
> Hi folks,
> sorry, I just don't get it:
> I'm trying to figure out how to uninstall software using WPKG.
> As far as I get it (I am a newbie):
> there's
> * hosts.xml - meaning: which profile is assigned to which computer
> * profiles.xml - meaning: which softwarepackages are assigned to which 
> profile
> * packages.xml - meaning: all the actions (line install, upgrade, 
> remove plus checks) So far, so good.
> The point is: in those packaging.xml-files, there are three actions
> described: install, upgrade, remove. How does the computer know, which 
> action to take? I'm kinda looking for a assignment like: uninstall 
> package firefox in profile custom, which is assigned to host pc001
> So far, I deployed hardcopy, which worked fine. Packages.xml contains:
> <install cmd='"%SOFTWARE%\installers\hc.exe" /InstallSilent 
> /InstallCommonGroup /InstallDir="%Programfiles%\Hardcopy"' /> <upgrade 
> cmd='%WINDIR%\SwSetupuexe "%PROGRAMFILES%\Hardcopy\hardcopy.del" 
> /Silent' /> <upgrade cmd='"%SOFTWARE%\installers\hc.exe" 
> /InstallSilent /InstallCommonGroup 
> /InstallDir="%Programfiles%\Hardcopy"' /> <remove 
> cmd='%WINDIR%\SwSetupuexe "%PROGRAMFILES%\Hardcopy\hardcopy.del"
> /Silent' />
> As I said, installation worked fine. What would I have to do to 
> uninstall Hardcopy? How do I tell the clients to use the remove-cmd?
> Greetings,
> Alex
> ----------------------------------------------------------------------
> --- wpkg-users mailing list archives >> 
> http://lists.wpkg.org/pipermail/wpkg-users/
> _______________________________________________
> wpkg-users mailing list
> wpkg-users at lists.wpkg.org
> http://lists.wpkg.org/mailman/listinfo/wpkg-users


wpkg-users mailing list
wpkg-users at lists.wpkg.org

End of wpkg-users Digest, Vol 43, Issue 1

More information about the wpkg-users mailing list