I love virtualisation: Download VMWare Player, download an appliance from
http://www.vmware.com/appliances/, run it and you have a new Linux installation ready. The only problem: How to access the host file system (yes, there were some security issues with that bus since the VMWare image i am using is just for development and i am the only user, i ignore that for a moment).
The appliance should come with the VMWare-Tools and then it should be a question of setting in your vmx file:
isolation.tools.hgfs.disable = "FALSE"
sharedFolder.maxNum = "1"
sharedFolder0.present = "TRUE"
sharedFolder0.enabled = "TRUE"
sharedFolder0.readAccess = "TRUE"
sharedFolder0.writeAccess = "TRUE"
sharedFolder0.hostPath = "<path-to-my-files>"
sharedFolder0.guestName = "<name-of-share>"
sharedFolder0.expiration = "never"
So far, so good. Next, you need to mount the share on the guest fs. If you look in the documentation, you read "all hgfs mounts show up in /mnt/hgfs". Unfortunately this was empty.
So i started vmware-config-tools.pl beacuse some google result pointed me at it. Unfortunately my Ubuntu 8.04 was too new to be supported by the binary distribution of the tools. So the config script proposed to compile the tools for me. This worked fine for most of the tools but not for vmhgfs. Unfortunately there was some identifier defined differently in different places and this prevented the compiler from building my binary. I have done some C coding and even assembler, but i was not ready (yet) to dive in this deep at the moment. So i googled again and found a "any-any" update patch for vmware prodcuts. Unfortunately, this also didnt help.
Then i became angry. After some more digging i found the open-vm-tools on Sourceforge. It came with some documentation (but not with much). I downloaded it and started compling. After about 2 hours of downloading additional packages and building them (http://www.icu-project.org/ and http://libdnet.sourceforge.net/) i finally succeeded to build the tools.
But there is no make install. It says in the "documentation" that the perl script that VMWare tools bring was kind of rocket science and that they rather describe how the binaries can be installed manually. In the last time i did not do so much "low level work" therefore i needed to consult the Linux Loadable Kernel Module HOWTO in order to find out what exactly to do. After i had found that after the build, the kernel module is located under modules/linux/vmhgfs.ko, i did an insmod with this module and - voila - no error message. I verified that there already was a /sbin/mount.vmhgfs (the tools config programm obviously already had installed that), i just tried a
mount -t vmhgfs .host:/ /mnt/hgfs
and it worked! I then inserted an entry in /etc/fstab to mount on system startup and here i go! After just some hours of research and learning i can now do what VMWare Workstation would probably have bought me for a hundred bucks...
Update: You can see the same solution described in a VMWare Community Blog
Update2: And even more comprehensive information can be found here.
(Very cool idea in these two blog-posts: Compile the open-vm-tools as described above, then copy the generated binaries to the vmware-tools distribution directories and use the vmware-config-tools.pl from vmware-tools to install everything right)