VMware

From ArchWiki
Revision as of 14:08, 20 September 2011 by Eigrad (Talk | contribs)

Jump to: navigation, search

This template has only maintenance purposes. For linking to local translations please use interlanguage links, see Help:i18n#Interlanguage links.


Local languages: Català – Dansk – English – Español – Esperanto – Hrvatski – Indonesia – Italiano – Lietuviškai – Magyar – Nederlands – Norsk Bokmål – Polski – Português – Slovenský – Česky – Ελληνικά – Български – Русский – Српски – Українська – עברית – العربية – ไทย – 日本語 – 正體中文 – 简体中文 – 한국어


External languages (all articles in these languages should be moved to the external wiki): Deutsch – Français – Română – Suomi – Svenska – Tiếng Việt – Türkçe – فارسی

Summary help replacing me
This article will explain how to install and configure VMware Workstation/Player in Arch.
Related
Installing Arch Linux in VMware
Virtualbox

This article is about installing VMware in Arch, you may also be interested in Installing Arch Linux in VMware.

Installation

VMware Server

1. Install vmware-server from the AUR.

2. Install vmware-server-console. Alternatively, on Arch64, the bin32 version can also be installed.

3. Download the image from VMWare website.

4. Copy the image to the build directory.

5. Finish building.

VMware Workstation/Player

Note: VMware Workstation/Player will not be manageable with pacman as the files are not installed with it.

To install Workstation or Player on a Linux host using a bundle:

1. Download VMware Workstation (you may also try the testing (Beta/RC) versions).

2. Start the installation (Template:Codeline uses terminal instead of the GUI):

# chmod +x VMware-<edition>-<version>.<release>.<architecture>.bundle
# ./VMware-<edition>-<version>.<release>.<architecture>.bundle --console

3. Read & accept the EULA to continue.

4. Set Template:Codeline to:

/etc/rc.d

5. (Optional) Enter the directory path to the Integrated Virtual Debugger for Eclipse if Eclipse is installed.

6. Ignore the error about the "rc*.d style init script". In the GUI installer this comes a pop-up.

7. Create links for the daemons:

# ln -s /etc/init.d/vmware /etc/rc.d/vmware
# ln -s /etc/init.d/vmware-workstation-server /etc/rc.d/vmware-workstation-server

Configuration

VMware patches

Note: This is not required with VMware Workstation 8. Except for 3.1rc kernels
Tip: There is also a package called Template:Package AUR in the AUR with the intention of trying to automate the patching process.

3.1rc kernels

In addition to the kernel 3.0 patch just apply this one.

To works with VMware Workstation 8 after a fresh install, you have to use this script : here

# wget http://88.191.137.189/vmware3.1rc.sh
# chmod +x vmware3.1rc.sh
$ ./vmware3.1rc.sh

3.0 kernels

There is a set of patches that handle correctly the linux kernel 3.0 here.

VMware module builder does not handle correctly the new kernel version string which has only two parts (3.x) instead of three (2.6.xx). See this thread.

The easier solution for that point is to patch two binaries:

# sed 's/\x83\xe8\x03\x83\xf8\x01\x0f\x96\xc0/\x83\xe8\x02\x83\xf8\x01\x0f\x96\xc0/' -i /usr/lib/vmware/lib/libvmware-modconfig-console.so/libvmware-modconfig-console.so
# sed 's/\x83\xe8\x03\x83\xf8\x01\x0f\x96\xc0/\x83\xe8\x02\x83\xf8\x01\x0f\x96\xc0/' -i /usr/lib/vmware/lib/libvmware-modconfig.so/libvmware-modconfig.so

2.6.39 kernels

$ mkdir /tmp/vmware && cd /tmp/vmware
# for t in /usr/lib/vmware/modules/source/*.tar; do tar xf $t; mv $t{,.original}; done
# wget -qO- http://kaslit.com/downloads/vmware2.6.39fixed.patch | patch -Np1
# for d in *-only; do tar cf /usr/lib/vmware/modules/source/${d/%-only/}.tar $d; done

A Fedora community member has also uploaded the Template:Filename folder in a compressed tarball here.

2.6.37 and .38 kernels

cd /tmp
$ wget http://www.russo79.com/vmware7.1.3-patch-kernel-2.6.37.sh
$ chmod +x vmware7.1.3-patch-kernel-2.6.37.sh
# ./vmware7.1.3-patch-kernel-2.6.37.sh

2.6.36 kernels

$ cd /tmp
$ wget http://files.archlinux.org.il/vmmon_fix_2.6.36.sh
$ chmod +x vmmon_fix_2.6.36.sh
# ./vmmon_fix_2.6.36.sh

2.6.35 kernels

$ cd /tmp
$ wget http://www.sputnick-area.net/scripts/vmware7.1.1-patch-kernel-2.6.35.bash
$ chmod +x vmware7.1.1-patch-kernel-2.6.35.bash
# ./vmware7.1.1-patch-kernel-2.6.35.bash

VMware modules

8. At this point you would want to install the modules. First you need to either change the Template:Codeline in Template:Filename from Template:Filename to Template:Filename:

# sed -i "s|/sbin/lsmod|/bin/lsmod|g" /etc/rc.d/vmware

or create a symlink with:

# ln -s /bin/lsmod /sbin/lsmod

9. Now you can install the modules. You can do this with either by launching VMware and letting it install the modules with the GUI or executing:

# vmware-modconfig --console --install-all

10. (Optional) Add vmware to the DAEMONS array in Template:Filename so that the service is started automatically on boot.

11. Install and run HAL <-- HAL is still being used?:

# pacman -S hal
# rc.d start hal

12. Now, open your VMware Workstation (Template:Codeline in the console) or VMware Player (Template:Codeline in the console) to configure & use!

Note: When upgrading the kernel you will have to rebuild the vmware modules with:
# vmware-modconfig --console --install-all
Failure to do so may result in a system crash upon powering up Virtual Machines.

Tips & Tricks

Extracting the VMware BIOS

To extract the VMware BIOS, which can be manipulated and later used with your virtual machines:

$ objcopy /usr/lib/vmware/bin/vmware-vmx -O binary -j bios440 --set-section-flags bios440=a bios440.rom.Z
$ perl -e 'use Compress::Zlib; my $v; read STDIN, $v, '$(stat -c%s "./bios440.rom.Z")'; $v = uncompress($v); print $v;' < bios440.rom.Z > bios440.rom

To use the modified BIOS, move it to Template:Filename, and add it to the Template:Codeline file:

bios440.filename = "bios440.rom"

Troubleshooting

Could not open /dev/vmmon: No such file or directory.

The full error is:

Could not open /dev/vmmon: No such file or directory.
Please make sure that the kernel module `vmmon' is loaded.

This means that at least the vmmon VMware service is not started. You can start them all up by running (as root):

# rc.d start vmware

Kernel headers for version 3.x-xxxx were not found. If you installed them[...]

Install them with:

# pacman -S linux-headers

Printing does not work

If printing from the guest OS is not working there may be a permission problem with the ThinPrint CUPS filter (thnucups), which is used by VMware. First make sure your Template:Filename says something like:

E [22/Nov/2010:14:10:11 -0800] Unable to execute /usr/lib/cups/filter/thnucups: insecure file permissions (0104755)

In which case you may try:

# chmod u-sw /usr/lib/cups/filter/thnucups
# rc.d restart cupsd

The installer will not start

If you just get back to the prompt when opening the Template:Filename, then you probably have an old version of the vmware installer and you should remove it (you may also refer to the Uninstallation section of this article):

# rm -r /etc/vmware-installer

Uninstallation

Check the product name:

# vmware-installer -l

and uninstall:

# vmware-installer -u <vmware-product>

Manually included parts in Template:Filename have to be deleted manually:

# unlink /etc/rc.d/vmware
# unlink /etc/rc.d/vmware-workstation-server

Remember to also remove Template:Codeline from the Template:Filename Template:Codeline array.