It’s somehow perverse but nevertheless wonderful 🙂 Rod McFarland made a CLI (command line interface) theme for WordPress. So now you can read my blog as if you were logged in to a UNIX-like system and having a directory structure for the categories, and a bunch of text files (for the blog posts). Try it (refresh afterwards), if your browser is capable of JavaScript and is not called Internet Explorer (because it doesn’t seem to work with Internet Explorer, which is no big problem, because nobody should use this browser anyway).
VMware guest networking just stopped working [solved]
I just spent some time figuring out why the hell VMware guest networking (all virtual machines, Windows and Linux) just stopped working! I couldn’t remember to have anything changed except a kernel update on the host system, but the VMware kernel module compiled fine against it, and also the VMware services are running as they should.
I’m usually configuring my VMs to have access to the outside world via VMware’s NAT feature, which always worked fine for me.
While analysing the problem, I found out that the default NAT network address is 10.0.0.0 (on interface vmnet8). Now guess what happened! Some tomfool over at my ISP configured a host to have the IP address 10.0.0.1, which is handed out by the VMware DHCP service as the default gateway to all VMs. I found that out by running a traceroute on 10.0.0.1, which gave me several hops to a host, probably belonging to my ISP. The workaround is simple: just add the network address of the NAT interface (vmnet8) on the host. This can be done with vmware-config.pl on Linux hosts, and I’m sure there is also a way to do that on Windows hosts. I set it to a 192.168.x.y address, which works well now.
I really wonder how this could have happend – I always believed that the 10.x.y.z addresses aren’t being routed! Then why is this D-Link router AND the DSL router/modem combo in this flat routing requests to 10.0.0.1 to the Internet? Anyone?
How to properly setup Kubuntu in a VMware virtual machine
Well, this is the end of a long day, and I used WAY TOO MUCH time on getting a simple Kubuntu installation in a VMware virtual machine running.
The scenario is the following:
- VMware Player will be used for “playing back” the machine
- Copy & Paste must work
- Auto mouse-grabbing and -releasing must work
Those requirements make installing Kubuntu in a VM more tricky than you might think – here is a cookbook recipe:
- Use VMXBuilder or some other tool to generate the Virtual Machine (because VMplayer can only play it back, as the name suggests)
- Make sure that you have TWO IDE controllers (like most real PCs), and connect a virtual harddisk (10 GB or so) to the first controller. Connect a virtual CD drive to the second IDE controller. If you try to use only one IDE controller and connect both devices to that one, the VM will be AWFULLY slow. At least that’s what happened here.
- Supply the Kubuntu-CD-image to the virtual CD drive.
- Boot up the VM.
- Install Kubuntu to the virtual harddrive, that shouldn’t be much of a problem.
- After the installation is finished, shutdown the VM.
- Boot up the VM and disable the CD drive, or press ESC during bootup and select harddisk. Now it will boot your newly installed Kubuntu. Apply all the pending updates (as of today that were 125). Go and do something else, if you don’t have a REALLY fast machine & internet connection.
- Install “alien”, a program that will convert .rpm packages to .deb packages, and thus will enable you to use Kubuntu’s package manager to install VMware tools, which is imo the best solution available.
- Shutdown your VM.
Now the trouble begins. How to get VMware Tools into this VM, because only with those, you can have Copy & Paste and automatic mouse grabbing/releasing. Here’s the solution.
- You need to have access to a VMware Workstation installation, or some other way to obtain the file “VMwareTools-5.5.0-18463.i386.rpm” (or perhaps a different version). It’s part of the linux.iso file which itself is part of VMware Workstation, and usually installed under “VMware Workstation installation/lib/isoimages/linux.iso”. Perhaps you can find it somewhere on the net, too – didn’t check. The file has 15 MB, the whole iso image has around 30 MB.
- Open your VMX file again and put the ISO into your virtual CD drive.
- Boot your VM again. Copy the VMwareTools-5.5.0-18463.i386.rpm file to /tmp or somewhere else where you have write access and run
alien --script VMwareTools-5.5.0-18463.i386.rpm
. This will take a surprisingly long time, but will give you a file called VMwareTools-5.5.0-18463.i386.deb (or something like it). Now you can conveniently install the deb by runningdpkg -i VMwareTools-5.5.0-18463.i386.deb
.
VMware Tools are now installed into your Kubuntu VM, but that doesn’t mean they work. In fact they don’t. Not at all.
- First, run
ln -s /usr/lib/vmware-tools/lib32/libgdk-1.2.so.0/libgdk-1.2.so.0 /usr/lib/libgdk-1.2.so.0
. - Then, run
vmware-config-tools.pl
as root, let it compile the kernel module and set your desired Xorg resolution. - Now, the vmmouse driver for Xorg has to be copied to an Xorg directory – don’t know why this isn’t done automatically, perhaps the rpm-deb-conversion doesn’t work so well after all – this could also be the reason for the libgdk stuff… Do it by running
cp /usr/lib/vmware-tools/configurator/XOrg/7.0/vmmouse_drv.so /usr/lib/xorg/modules/input/
. - Activate the vmmouse driver in xorg.conf (change “Driver “mouse”” to “Driver “vmmouse”” in Section “InputDevice”), which will finally give you auto mouse-grabbing/releasing (after you restart your X server, of course).
- You still won’t be able to copy & paste text between the VM and your host system – to get this to work, there must be an instance of “vmware-toolbox” running inside your user’s X session. I recommend to use the following .desktop file and place it under ~/.kde/Autostart/vmware-toolbox.desktop or something like that.
[Desktop Entry]
Comment=
Comment[en_US]=
Encoding=UTF-8
Exec=ksystraycmd --ownicon --window "VMware Tools Properties" --icon "/usr/share/app-install/icons/vmware-player.png" --hidden vmware-toolbox
GenericName=
GenericName[en_US]=
Icon=/usr/share/app-install/icons/vmware-player.png
MimeType=
Name=VMWare Toolbox to Tray
Name[en_US]=VMWare Toolbox to Tray
Path=
StartupNotify=true
Terminal=false
TerminalOptions=
Type=Application
X-DCOP-ServiceType=
X-KDE-SubstituteUID=false
X-KDE-Username=
X-Ubuntu-Gettext-Domain=desktop_kdebase
Notice the line with ksystraycmd --ownicon --window "VMware Tools Properties" --icon "/usr/share/app-install/icons/vmware-player.png" --hidden vmware-toolbox
, where ksystraycmd is being used to put that ugly VMware toolbox program into the tray, and give it a nice icon.
- Open the VMX file again and remove the Kubuntu ISO from the CD drive. Instead specify that the VM should use your real CD/DVD drive. Turn off legacy emulation (I had trouble with this some other time, don’t remember the specific problem though).
You’re done! Finally…