VMware tools are an absolute must for SLES virtualised on VMware platforms. Normally, we have to rely on the VMware administrator installing the tools for us, and the standard tools are not rpm based so it can be difficult to maintain or to see which version is installed.
Thankfully, VMware have a very elegant solution to this problem – the Operating System Specific Packages (OSP – nope, I don’t know where the second S went either) from here: https://www.vmware.com/support/packages
Although it’s relatively easy to follow the docs, it can be tedious! So, what does any decent Linux administrator do when faced with a repetitive, boring task?? Yep, write a script! So, I am now sharing with you a script that I have been developing since 2011 that installs the OSP tools for you.
The highlights of the script are as follows:
- Support for SLES 10 up to SP4
- Support for SLES/SLED 11 up to SP3
- Automatic SLE version/architecture detection
- Automatic Hypervisor version detection (as long as dmidecode is installed)
- Command line options allowing you to specify ESXi version
- Automatic uninstall of old tools (ancient rpm and recent tar based versions)
- Uses your proxy server if configured
- v1.8: The script can be used to upgrade the OSP tools after a SLE service pack has been applied
- v1.9: Removed the workaround for SLES 11 SP3 now that VMware’s repos have been updated
- v1.9: Added SLES 12 detection. At this point there are no OSP tools for SLE 12, so the script installs the open-vm-tools package from the standard media instead.
- v1.10: Split package deletion and repo deletion into separate actions as some Service Pack upgrades remove the OSP packages but leave the old repo lying around!
Of course, I will continue to update the script as SUSE or VMware release new versions. If you have any feedback please leave comments below.