VMware Cloud Community
jitendrakmr
Hot Shot
Hot Shot
Jump to solution

Script to upgrade VMWare tools on multiple Servers

Hello Everyone,

I have approx 80 VMs running in a cluster and I need to updgrade VMWare Tools on them. Is there any script or any other option with which I can install VMware tools on all the VMs? Or do I really need to install it one by on individual VMs?

Thanks.

Jitendra

MCSE 2003, VCP, CCNA, ITIL Foundation

VCP, MCSE 2003, MCITP Enterprise Admin, CCNA, ITIL Foundation, Netapp NS0-153 (Storage Networking) Personal Website - http://www.virtualizationtrainings.com, http://www.hillsindia.com
0 Kudos
1 Solution

Accepted Solutions
azn2kew
Champion
Champion
Jump to solution

If that is your limitation, than read this thread it will show you exactly how to scripted silently install.

http://communities.vmware.com/message/165941

You can still use SMS console and manage deployment to specified servers group or machine names without worry about OUs!

If you found this information useful, please consider awarding points for "Correct" or "Helpful". Thanks!!!

Regards,

Stefan Nguyen

iGeek Systems Inc.

VMware, Citrix, Microsoft Consultant

If you found this information useful, please consider awarding points for "Correct" or "Helpful". Thanks!!! Regards, Stefan Nguyen VMware vExpert 2009 iGeek Systems Inc. VMware vExpert, VCP 3 & 4, VSP, VTSP, CCA, CCEA, CCNA, MCSA, EMCSE, EMCISA

View solution in original post

0 Kudos
11 Replies
nsusa
Contributor
Contributor
Jump to solution

Use group policy to upgrade. Just experiment with the different switches and you should be fine.

0 Kudos
vmroyale
Immortal
Immortal
Jump to solution

Check this discussion or this one.

Brian Atkinson | vExpert | VMTN Moderator | Author of "VCP5-DCV VMware Certified Professional-Data Center Virtualization on vSphere 5.5 Study Guide: VCP-550" | @vmroyale | http://vmroyale.com
0 Kudos
jitendrakmr
Hot Shot
Hot Shot
Jump to solution

Using AD it will install it on physical servers also because I do have physical servers and they are all not in single OU as well; so how it is possible to use AD to deploy VMware tools?

Thanks.

Jitendra

MCSE 2003, VCP, CCNA, ITIL Foundation

VCP, MCSE 2003, MCITP Enterprise Admin, CCNA, ITIL Foundation, Netapp NS0-153 (Storage Networking) Personal Website - http://www.virtualizationtrainings.com, http://www.hillsindia.com
0 Kudos
azn2kew
Champion
Champion
Jump to solution

You should use the command listed below and save it as a .cmd file and create a Windows Group Policy to apply it to your workstations/servers OU and have it done with. You can deploy using SMS server as well.

Use Notepad:

msiexec -i "c:\path\vmwaretoolsfile.msi" addlocal=all /qn REBOOT="ReallySuppress"

and save it as vmtools.cmd file and upload to your netlogon share from domain controller. Apply the GPO to this and you should be fine.

If you found this information useful, please consider awarding points for "Correct" or "Helpful". Thanks!!!

Regards,

Stefan Nguyen

iGeek Systems Inc.

VMware, Citrix, Microsoft Consultant

If you found this information useful, please consider awarding points for "Correct" or "Helpful". Thanks!!! Regards, Stefan Nguyen VMware vExpert 2009 iGeek Systems Inc. VMware vExpert, VCP 3 & 4, VSP, VTSP, CCA, CCEA, CCNA, MCSA, EMCSE, EMCISA
0 Kudos
jitendrakmr
Hot Shot
Hot Shot
Jump to solution

The problem with using AD is that I cant put all VMs in single OU because that will need to go through change management process and I am sure that getting that approved from security will be difficult because machines are already in different other OUs with application related policy applied.

Is there any other way than using AD to do this?

Thanks.

Jitendra

MCSE 2003, VCP, CCNA, ITIL Foundation

VCP, MCSE 2003, MCITP Enterprise Admin, CCNA, ITIL Foundation, Netapp NS0-153 (Storage Networking) Personal Website - http://www.virtualizationtrainings.com, http://www.hillsindia.com
0 Kudos
azn2kew
Champion
Champion
Jump to solution

If that is your limitation, than read this thread it will show you exactly how to scripted silently install.

http://communities.vmware.com/message/165941

You can still use SMS console and manage deployment to specified servers group or machine names without worry about OUs!

If you found this information useful, please consider awarding points for "Correct" or "Helpful". Thanks!!!

Regards,

Stefan Nguyen

iGeek Systems Inc.

VMware, Citrix, Microsoft Consultant

If you found this information useful, please consider awarding points for "Correct" or "Helpful". Thanks!!! Regards, Stefan Nguyen VMware vExpert 2009 iGeek Systems Inc. VMware vExpert, VCP 3 & 4, VSP, VTSP, CCA, CCEA, CCNA, MCSA, EMCSE, EMCISA
0 Kudos
jitendrakmr
Hot Shot
Hot Shot
Jump to solution

Thanks Everyone. Finally I got the script working. I created following script named VMT.bat -

net use K: "\Network Path to VMware Tools" password /USER:domainname/username /PERSISTENT:no

msiexec -i "K:\vmware tools.msi" addlocal=all /qn REINSTALLMODE=vamus REINSTALL=ALL REBOOT="ReallySuppress"

Using another bat file (text mentioned below) I copied above script(VMT.bat) and ran it to all the VMs (names were saved in another file called servernames.txt which was in the same directory as of below script) on which Vmtools were need to be updated -

@ECHO OFF

:: Batch File at Remote Server

::

set _comp=servernames.txt

set _rpt=Report.txt

echo Ran at %date% %time% > %_rpt%

echo. >> %_rpt%

for /f %%a in (%_comp%) do call :Task %%a

exit /b

:Task

ECHO CHECKING %1

ECHO >>%_rpt%

start psexec \%1 -c "\network path to vmt.bat created above"

sleep 1

exit /b

Please note that the psexec.exe and servernames.txt needs to be copied into the same directory as of above script to copy and run VMT.bat to all the servers.

I ran this script using my domain admin account and all the servers were in the same domain so there were no access issues. Everything worked fine and for confirmation I checked application logs which were showing VMware tool configured successfully.

Thanks again.

Jitendra Kumar

MCSE 2003, VCP, CCNA, ITIL Foundation

VCP, MCSE 2003, MCITP Enterprise Admin, CCNA, ITIL Foundation, Netapp NS0-153 (Storage Networking) Personal Website - http://www.virtualizationtrainings.com, http://www.hillsindia.com
0 Kudos
mike_laspina
Champion
Champion
Jump to solution

Hi,

I have taken a different approach to solve this issue.

BTW you really do need to restart a Windows VM for it to work correctly (the drivers force this issue).

Here are the details.....

http://blog.laspina.ca/ vExpert 2009
0 Kudos
tdubb123
Expert
Expert
Jump to solution

how do I upgrade tools for linux machines? I can do it for windows but what about linux?

0 Kudos
mike_laspina
Champion
Champion
Jump to solution

The process I am using upgrades both. It invokes the install command by using script based VC -> ESX control and the host the starts the install on the VM.

Some linux targets are not upgradable and these will simply fail the automated method.

http://blog.laspina.ca/ vExpert 2009
0 Kudos
PerryWhittle
Enthusiast
Enthusiast
Jump to solution

Hi

if all your servers are in the same OU you would need to use Group Policy filtering so that only VM's get the GPO applied. The 2 permissions required on the GPO to apply it are

Read

Apply group policy object

Regards

Pez

#############################################

please dont forget to award points if you found this useful

Please rememeber to award points if you found this helpful or correct
0 Kudos