Installing Ubuntu 9.04 Desktop Edition with full support of VMware Tools - Simplified!
WoodyZ May 14, 2009 3:51 AMAt the present time Ubuntu 9.04 is not a supported OS with VMware products however it certainly can be installed and with a few tweaks even VMware Tools will work normally.
The purpose of this discussion thread is to provide a shell script to facilitate the necessary patching of and then installing VMware Tools along with some other modifications that need to be made in order to have a complete and successful install. I wrote this shell script to bring together all the bits and pieces of information that have already been placed out into the community by others and a referencing credit section is included below.
Note: This shell script was originally intended only to be used on a normal manual install (non Linux Easy Install) of Ubuntu 9.04 Desktop Edition in VMware Fusion 2.0.2, 2.0.3 or 2.0.4 however I have now modified the original shell script to handle being used in either type of install. If you did use Linux Easy Install then VMware Tools must be uninstalled first and this shell script will detect that and offer to automatically remove and reboot or give you directions on how to do it manually. The new version of the shell script does a preflight conditions check and employs the necessary error handling which means basically you just execute the shell scrip by double-clicking it and select Run in Terminal and it will tell you if something isn't ready to go.
This shell script, "Patch_and_Install_VMware_Tools_for_Ubuntu_9_04.sh", brings together the necessary steps to patch and install VMware Tools to have full functionality and make additional changes to easily resolve other issues so after the install of Ubuntu 9.04 Desktop Edition and running this script you’ll be set and ready to go without having to gather up all the information that has been spread about and make the necessary changes one at a time as you find all the various resolutions to the issues at hand which are issues with the Mouse, patching the VMware Tools Install to enable VMware Shared Folders and editing the /etc/fstab file to enable access to the VMware Shared Folders HGFS Shares.
The attached zip archive "Patch_and_Install_VMware_Tools_for_Ubuntu_9_04.zip" contains a Read Me First.txt file and three additional files which contain the shell script packaged three different ways for ones choice of placing it on the Ubuntu 9.04 Desktop Edition's User's Desktop to be able to run the shell script. You can download this directly to the Ubuntu Desktop and use the enclosed "Patch_and_Install_VMware_Tools_for_Ubuntu_9_04.sh.zip" file and extract and run the shell script or you can download it to the Mac Desktop and use the ISO Image or Floppy Disk Image to enable access to the shell script from the Ubuntu 9.04 Desktop Edition's Desktop. It shouldn't be needed to say however I'll say it anyway, read the Read Me First.txt file.
======================
How to use the Shell Script
1. Install Ubuntu 9.04 Desktop Edition in VMware Fusion 2.0.2, 2.0.3 or 2.0.4
2. After the install and upon reboot to the Desktop mount the VMware Tools linux.iso file by clicking Install VMware Tools on the Virtual Machine menu and then close the cdrom0 - File Browser windows that opens on the Desktop as the rest is then handled by my shell script.
3. Double-click the Patch_and_Install_VMware_Tools_for_Ubuntu_9_04.sh shell script and select Run in Terminal and follow the prompts in the shell script as you normally would.
Note: When the shell script is double-clicked if for some reason it just opens in Text Editor then just close it and set the executable permission via a right-click > Properties > Permissions tab > and then check the Execute: Allow executing file as program check box then click the Close button.
4. With the exception of typing your password when prompted and selecting the Screen Resolution and or which uninstall type (automatic or manual) the remaining prompts can be responded to by pressing the Enter key thus accepting the default answer to these prompts. Once the shell script is finished the Terminal window will remain open for you to copy and paste the output to a text file for later review and reference after you reboot the Virtual Machine when done running the script enabling changes to take place.
Note: Once you have copied and pasted the output to Text Editor and have saved it you can press Enter for it to automatically reboot or you can just close the Terminal window and manually restart Ubuntu 9.04 Desktop Edition.
======================
For those not familiar with installing VMware Tools in a Linux Virtual Machine from the Command Line with the Tar Installer understand that it can appear that nothing is happening after you’ve responded to various prompts however be patient as things are happening and the next prompt will appear shortly. You will also notice activity on the hard drive icon on the Status Bar to show that things are moving along between those prompts that don’t return immediately once having pressed Enter.
The entire process of using this shell script only takes around five minutes or a bit longer if you’re a slow reader.
=================
Referencing Credits
Information regarding accessing the HGFS Shared Folders issue under Linux came from etung's Frequently Asked Questions about Guest OSes. Note that this is not because Ubuntu 9.04 isn't officially supported at this time but with Fusion and Linux Virtual Machines in general. I consider this a bug in the VMware Tools Installer under Linux in that it doesn't properly modify the fstab file to begin with.
Information regarding getting HGFS to work by patching the page.c source file in VMware Tools came from a link in a post by c718333, VMWare Tools/Ubuntu 9.04 issue - "Unable to build the vmhgfs module.". This issue would be due to Ubuntu 9.04 being official supported at this time.
Information regarding the Mouse issue came from reading davidliu's post, Running Ubuntu 9.04 in VMware Fusion 2. This issue would be due to Ubuntu 9.04 being official supported at this time.
=================
My shell script address these issues and while it may be able to be used on Ubuntu 9.0.4 Desktop Edition running under other VMware products note that I have only tested it under Ubuntu 9.04 Desktop Edition ( both x86 and x64) running under VMware Fusion 2.0.4 and have verified by diffing the target in the VMware Tools included in Fusion 2.0.2 and 2.0.3. The contents of the page.c file in the VMware Tools in Fusion 2.0.0 and 2.0.1 did not have the target line and therefore those versions are not supported by my shell script. That said, I make no assumptions for use with any other VMware product because I just do not have the time to test/verify on other products.
Message was edited by: WoodyZ - Updated Shell Script and Original Discussion Thread Content.