Installing VMware tools on Debian/Linux box

Just follow these instructions to install VMware tools on a Debian machine.

1. Run upgrade and update on the debian machine

apt-get upgrade
apt-get update

In case you’re having issues with upgrade or update, try checking your /etc/apt/source.list file to make sure it has the right settings.

2. VSphere: Edit the settings of the VM and click on “CD/DVD drive 1”. Click the “Connected” box at the top of the window and say OK. Then return to the SSH session.

3. Ensure gcc and make are installed on the machine. Execute the following commands to check if they are installed.

which gcc
which make

If you don’t get a path to gcc & make back when you invoke the “which” commands, those tools are not installed and must be:

apt-get install make gcc

4. Determine what kernel you’re using:

uname -r

5. Install linux headers. Execute the following:

apt-get install linux-headers

(I’m not specifying a version of linux-headers because by leaving it off, apt-get will return a list of linux-kernel packages). This will give you a list of packages to install. Look for one that has your kernel version in it (i.e.: I chose linux-headers-2.6.32-5-686 because both the kernel version AND architecture matched). Install the matching version:

apt-get install linux-headers-2.6.32-5-686

6. Install build essentials for your kernel

cd /usr/local/src

NOTE: If you get an error “wget” doesn’t exist, install it: “apt-get install wget”

apt-get -f install dpkg-dev
dpkg -i build-essential_11.6_i386.deb

7. Right-click on the VM, go to Guest -> Install/Upgrade VMWare Tools

mount /dev/cdrom  /media/cdrom0    #(/dev/cdrom points to /dev/sr0. If /dev/cdrom does not exist, navigate to /dev and check the name for the cdrom link and use that instead)
cd /media/cdrom0
cp VMwareTools-8.6.0-425873.tar.gz /tmp
cd /tmp
tar -zxvf VMwareTools-8.6.0-425873.tar.gz
cd /tmp/vmware-tools-distrib

NOTE: Follow all the prompts. I have went through this entire procedure twice now on brand-spanking new Debian machines and just accepting all defaults has worked each time.

7. Remove the VMWare Tools tar-ball and un-packed files.

cd /tmp
rm -rf  VMwareTools*  vmware-tools-distrib

NOTE: The installation script automatically un-mounts the virtual CDROM/DVD drive.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s