Hi, I'm searching for a PowerCLI script that i can use to uninstall vmware tools on a specific machine.
The reason for this is because we're migrating to Hyper-V, and this requires that you remove vmware tools on the machine you want to convert.
We have a lot of VM's running, so it would save me a lot of time by doing this by PowerCLI .
Xtravirt has a oneliner for dismounting the tools at http://xtravirt.com/powercli-vmware-tools-one-liners
(Get-VM | Get-View | Where {$_.Runtime.ToolsInstallerMounted}) | % {Dismount-Tools -VM $_.Name}
You could use this to at least dismount them and then use Invoke-Script to run a command to remove the application. Perhaps something like the following.
http://stackoverflow.com/questions/113542/how-can-i-uninstall-an-application-using-powershell
As he says in the post. YMMV
I may be able to find some time to try this out later today for windows systems.
Hi,
How about the script to uninstall the VMware tool VSS component only ?
is it possible ?
Hello, AlbertWT-
Yes, you should be able to remove certain modules using the "REMOVE" parameter. See the VMware KB about this and other parameters to the VMware Tools installer at http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=200039....
It might be in the form of an upgrade (possibly even an "upgrade" using the same version of the Tools installer, just specifying which modules to ADDLOCAL and which to REMOVE?), but looks like it should work fine.
Thanks for the assistance Matt,
Now I'll try to script that in powershell and hoping that it can be done to execute it in bulk.
Cheers,
Albert