Preparing the system
VMware expects a traditional SysV init as found on popular Linux distributions such as Red Hat, Fedora, and Mandriva Linux, when it installs its services. It expects to write to a structure such as /etc/init.d/rcx.d (where X represents the various runlevels). Slackware is not setup like this at all since it uses the BSD init system, placing all of it's scripts in a flat format located in the /etc/rc.d/ directory. It's actually a very simple way to organize things, as SysV in my opinion is overly complicated. In any event, you can get around this issue by creating a “dummy” init directory for VMware to install to. If it isn't present, VMware will fail miserably.To create a dummy System V FS init structure, issue these commands at the shell prompt:
mkdir /etc/init.d
cd /etc/init.d
for i in {0,1,2,3,4,5,6}; do mkdir rc$i.d; done
cd /etc/init.d
for i in {0,1,2,3,4,5,6}; do mkdir rc$i.d; done
All done for now... let's move on the the actual installation.
VMware installation
I'm going to assume you've already downloaded a copy of Vmware. If you haven't you're getting ahead of yourself. Go get it and come back. Extract your VMware tarball to a directory you are comfortable with. I'll use /tmp for this example. After the tarball is extracted, issue the following commands:
cd /tmp/vmware-distrib
./vmware-install.pl
./vmware-install.pl
This will start the installation. Refer to the documentation that came with your VMware package to answer the installation prompts appropriately. In most cases, you will be safe with the defaults. Make sure to pay close attention to the networking part of the installation in order to get everything set up the way you want it.
Setup the init script
Ok, remember our dummy init structure? Well, it's time to move and remove. This is so simple it's scary.
cp /etc/init.d/vmware /etc/rc.d/rc.vmware
chmod +x /etc/rc.d/rc.vmware
chmod +x /etc/rc.d/rc.vmware
Now edit your /etc/rc.d/rc.local file and append the following text verbatim:
# begin vmware script
if [ -x /etc/rc.d/rc.vmware ]; then
/etc/rc.d/rc.vmware start
fi
# end vmware script
if [ -x /etc/rc.d/rc.vmware ]; then
/etc/rc.d/rc.vmware start
fi
# end vmware script
Now all we have left to do is clean up our dummy init.d directory and it's contents, then we are safe to run the program. To clean up the init directory, just type this at the shell prompt:
rm /etc/init.d -r
All done.
To run the program, just use /usr/bin/vmware.