Tuesday, August 7, 2012

Installing VMware Tools in a Linux virtual machine using a Compiler

SkyHi @ Tuesday, August 07, 2012

Note: If your Linux distribution is not RPM-based, has a custom kernel, or is unsupported, use the steps below to compile VMware Tools, otherwise, see Installing VMware Tools in a Linux virtual machine using RPM (1018392).
 
To install VMware Tools in a Linux guest operating system using Compiler:
  1. Ensure that your Linux virtual machine is powered on.
  2. If you are running a GUI interface, open a command shell.

    Note: Log in as a root user, or use the sudo command to complete each of these steps.
  3. Click VM in the virtual machine menu, then click Guest > Install/Upgrade VMware Tools and click OK.
  4. To create a mount point, run:
    mkdir /mnt/cdrom
  5. To mount the CDROM, run:
    mount /dev/cdrom /mnt/cdrom
  6. To copy the Compiler gzip tar file to a temporary local directory, run:
    cp /mnt/cdrom/VMwareTools-.tar.gz /tmp/
    Where  is the VMware Tools package version.
  7. To change to the tmp directory and extract the contents of the tar file into a new directory called vmware-tools-distrib, run:
    • cd /tmp
    • tar -zxvf VMwareTools-.tar.gz
  8. To change directory to vmware-tools-distrib and run the vmware-install.pl PERL script to install VMware Tools, run:
    • cd vmware-tools-distrib
    • ./vmware-install.pl
      Notes:
      • Follow the screen prompts to install the VMware Tools. Options in square brackets are default choices and can be selected by pressing Enter.
      • To compile VMware Tools successfully, you need gcc Compiler and Linux Kernel sources provided by your Linux distribution. Consult your Linux distribution documentation for details on how to install these packages.
      • It is normal for the console screen to go blank for a short time during the installation when the display size changes.
      • Some warnings or errors are normal, like when a files does not exist.
      • Depending on the Linux distribution, your network service might restart after installation. VMware recommends that you invoke this command from the console and not remotely.
  9. If you are running a GUI interface, restart your X Window session for any mouse or graphics changes to take effect.
  10. To start VMware Tools running in the background during an X Window session, run:
    /usr/bin/vmware-toolbox &
  11. Depending on your environment you may need to unmount the CDROM. To unmount the CDROM, run:
    umount /mnt/cdrom
  12. Depending on your environment, you may need to manually end the VMware Tools installation. To end the VMware Tools install, click VM in the virtual machine menu, then click Guest > End VMware Tools Install.
  13. To remove VMware Tools installation packages, run:
    • cd
    • rm /tmp/VMwareTools-.tar.gz
    • rm -rf /tmp/vmware-tools-distrib



REFERENCES
http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1018414