Tuesday, February 1, 2011

setting up VMware 7.1 with kernel 2.6.36.x

If you are reading this post, you probably know what virtualization is and that VMWare is the most popular virtualization solution. You can use VMWare player (free) to run virtual machines already created by others for you or you can try VMWare server (free) or VMWare workstation (paid) to create your own virtual machines.

There is one problem though, VMWare 7.1.x releases (the latest at the time of this writing) are incompatible with 2.6.36[.x] kernel series. In order to run correctly VMWare products compile a few kernel modules that they use upon first startup. The process normally works without a problem if you are using a stock kernel from your distribution but may fail if you have a different kernel (my case). The error you get is:

"Unable to build kernel module.

See log file /tmp/vmware-root/setup-NNNNN.log for details"

Fear not as there is a patch out there for solving exactly this problem. Here is what you need to do.

1. Download the patch from


2. Save the patch to your /usr/lib/vmware/modules/source directory.

3. Extract the sources:

tar xf vmblock.tar; tar xf vmci.tar; tar xf vmmon.tar; tar xf vmnet.tar; tar xf vsock.tar

4. Apply the patch:

patch -N -p1 < vmware-7.1-2.6.36-generic.patch

5. Compress the archives again:

tar cf vmblock.tar vmblock-only; tar cf vmci.tar vmci-only; tar cf vmmon.tar vmmon-only; tar cf vmnet.tar vmnet-only; tar cf vsock.tar vsock-only;

6. Now just start your VMWare product and it should compile the modules without any problems. You can also compile and install the modules from the command line using the command:

vmware-modconfig --console --install-all

Many thanks to Ad0@#vmware [freenode] & archangelamael, balding_parrot, pure_hate@#backtrack-linux[freenode] for their help, tips and guidance.