Due to the popularity of my Fedora 12 version of this how to, I have copied it here and made the necessary changes for (K)Ubuntu 10.04 Guests (I actually did this while making said changes so I know it works…) :)
step by step instructions for getting shared folders to work in a Kubuntu 10.04 VM on VirtualBox (post OS installation)
- open a console window (I am a huge fan of Yakuake)
- sudo apt-get update
- sudo apt-get dselect-upgrade
- sudo apt-get install gcc gcc+ linux-kernel-headers
- restart the VM to boot with the newest kernel
- sudo apt-get autoremove (this will remove the old kernel files and decrease your used space on the virtual drive)
- goto the Devices drop down menu for VirtualBox and select install Guest additions
- sudo mount /cdrom /media
- sudo /media/VBoxLinuxAdditions-x86.run
- You will need to reboot the VM to reinitialize the HAL daemon (or manually restart the daemon if you know how; however restarting will let (K)Ubuntu auto resize your display as well)
- (special note, if you have already run the VBox Additions from the cd and just need to update it, or it was not working, then skip steps 7-10 and just type this “sudo /etc/init.d/vboxadd setup“
- sudo mkdir /mnt/[name you want your shared folder to have in the VM]
- mount -t vboxsf [name you gave the share in VBox] /mnt/[name you used in step 12]
- then you can now access your shared host directory from your (K)Ubuntu 10.04 install in the /mnt/[name you used in step 12] folder!!!
Really not that hard, but nowhere in the documentation for VirtualBox does it tell you that you have to do all of that!
Bonus step!!
now I bet you want to know how to make it comeback after a reboot, don’t cha!
- sudo vi /etc/fstab
- “G” (uppercase letter)
- “o” (lowercase number)
- [name you used in VBox shared folders] [tab] [fullpath to the mount point in the VM, or #12 above] [tab] vboxsf [tab] noauto,rw [tab] 0 [tab] 0 (both of those are the number zero)
- [esc] (the escape key, probably is labeled “esc” on your keyboard in the top left corner)
- “wq!” (lowercase letters and an exclamation (sometimes called a “BANG” by unix people, older people, and those who were taught by one of the afore mentioned.))
- now reboot
- sudo mount [name you used in VBox shared folders] (you will have to do this everytime you reboot (I just do a save state, so not an issue very often) as the fstab loads the mounts BEFORE the VBox additions are run, causing a “not found” error if it is not setup this way)
Special note: the folder name from VirtualBox shared folders is normally the name of the last directory in the path, for example if you are sharing /home/[my username]/Downloads/mystuff – then your VBox shared name will be “mystuff”
Also, check out my post on getting this to work in Fedora 12!!
just want to get this started as I hope it will motivate me to finish it, since I have done a LOT of things on my computer since my last post, and obviously I have posted none of it.
So, I got a little impatient about not having my PC functioning, so I I installed Fedora 12 x64 on the rest of my FreeBSD boot drive and I have about 80% of the things on my list done and working. I’ll reference them by numbers here, and you can go read what they were by clicking on “my list” above. I am still hoping to get FreeBSD as my host OS; however everything is working right now with Fedora (except that stupid wireless NIC), although I am still having my “system reached critical temp” error from ACPI, yet the system resource monitor I have running shows a nice pleasant 30C CONSTANT temp. maybe this summer I’ll pickup a liquid CPU cooler… I already have 5 exhaust fans and 2 intake fans, 2 x 240mm exhaust and a 160mm or 180mm intake, I think I have air flow covered. (talked to a friend who is more into the details of technical issues, a network engineer, and he says that an inactive CPU, like when the system shutsdown, can drop 40F in about 7-10 seconds so it might be why I cannot catch it reporting a high temp in the BIOS) The BIOS does not report any temps reaching above 45C ever, so I have no idea why this is happening, I do run widgets reporting the internal temp, but have never seen it change!!!) . most of the time when it shuts there is/has been high CPU/disk IO usage (all 4 cores over 60% sustained, multiple long term large/multiple file movements across drives and/or multiple VMs running). So it could be valid.
I have come up with a couple of things to try to resolve this issue (going with the cheapest first, even if it is not really going to help a CPU issue, it can’t hurt…)
- I could just upgrade some hardware and see if a different BIOS/MB manufacturer makes a difference. I would love a lower watt CPU (or 6 core!), more L2/L3 cache, and USB 3.0 and SATA 6GB/s, since my current system bottleneck is the SATA 3GB/s HDDs.
- Switch to liquid cooling and installing a new thermal sensor with an external readout.
- buy cute little 5cfm coolling fans to place on my NorthBridge, SouthBridge, and onboard GPU passive cooling fins (cheapest option, not necessarily attacking the actual issue though)
- purchase a pretty new Video card and disable the onboard video (the chip is within an inch or two from the CPU, so there maybe some issue with residual heat from the GPU causing my overheating).
in order from cheapest to most expensive would be 3, 2, 4/1 (really close and might be a tie or within a $20-$30)
My List of things to get working, except this one is for Fedora.
1. VirtualBox is installed, working and I have multiple VMs up and running.
2. Install VMWare Workstation, I have downloaded the newest trial version and it is good for another 3 weeks, but have not gotten around to installing it.
3. Mounting my NTFS drives, all mounted, where I want them, even went through and deleted the Windows OS system folders from all but one.
4. SSH connections, I have started this and was working on it when I decided to start this post, should be done tomorrow.
5. I am posting this from Google Chrome on my Fedora 12 installation right now, so I’d say installed and working. Java shows up in the plugins, although java.com cannot detect it in my browser.
6. Hulu works great in Firefox or Google Chrome, although is a bit spotty when I have VMs running, and the playback is laggy in Chrome… So I am trying to get the Hulu Desktop app running. will make a post after I get some work done on it and let you know how it goes.
7. So far everything is working great, going to try a couple of VM’ed games next week after I get the rest of this done.
8. Firefox is up, running, and is playing hulu; however it does not report Java as installed from the about:plugins page, even though it is and I followed all the steps to link the correct files to the correct places. I believe this is the Firefox 3.6 doesn’t support Java issue though and not an issue on my part.
9. access NTFS drives remotely via ssh and a chrooted account with links to the mounts. After I get my SSH working tomorrow I should be able to test this. I was reading something online I no longer have open and may not have bookmarked that said that I can double mount drives (mount a drive to more than one, specifically 2, locations)
10. convert my NTFS drives to a more suitable linux FS, this again is a last thing item, to be done after everything else is working.
11. convert my drives from MBR to GPT, most likely to be done at the same time as the FS change.
12. GUI package manager for KDE, done, comes with Fedora.
13. eliminate all traces of Gnome from my computer… again, have to be last thing, once all is up and working.
14. build my first kernel, normally done immediately after install, I’ll do it last after EVERYTHING else (including the other things I said I would do last)
15. Wine is installed and works. will try out some things that I have installed in VMs to see about dropping those VMs
16. install older apps, again part of a couple of other items, I will of course be installing older apps on older OS installation I have, and will try them in Wine as stated.
17. X.org port forwarding to Cygwin on a windows machine (laptop) something I might do in a week or two…
18. start regular backups… I’m getting there, I have the drive formated in ext3, I just have not started backing things up.
19. Java, I think it works in Chrome, I was able to see the animated maps on the NOAA website, which most people use to test their Java. not working in Firefox 3.5.9.2
20. Flash, Hulu is working in Firefox and Chrome, so all good here.
21. Yakuake is fully functional and working.
22. Picasa 3.6 (I think) is installed and working great, except I don’t seem to be able to find the facial recognician system.
23. No idea on this one, can not find where I posted what it was, only that it was completed on BSD.
Unfinished items for Fedora: 2, 4, 9, 10, 11, 19?
apparently Open Office will not load, for an unknown reason, looking into it at this time.
ok, so I woke up and now can’t get back to sleep. nothing new, but this time I decided to do something instead of just laying there hoping to fall asleep before the sun rises. Now, I thought that I already had this working, but apparently not… —edit okay, so I need to note I was doing these steps while writing this post and when I got to the step to reboot Fedora, step 6, I fell asleep.
I was and am currently using, a Fedora 12 VM from my laptop, now I thought I had the shared folders from the host OS (Win XP) setup, but could not find the mount point, so I just attempted to re-mount it. fyi I’m using VirtualBox 3.1.2 so I attempted to remount the shared folder to a simple location…
$ sudo mount -t vboxsf documents /home/finndo/Documents/local
mount: unknown filesystem type ‘vboxsf’
so I do some Googling and come up with some interesting tidbits…
so, if you didn’t look at the link, here it is in a nutshell, to get the mount to work (yes I installed the VM additions, but did not notice the error…) please read the whole post before trying this, as there are some steps you may need to do a little differently and I have noted this, but not until after I list them!
ok, let me start from the beginning…
step by step instructions for getting shared folders to work in a Fedora 12 VM on VirtualBox (after you get fedora installed)
- open a console window (I am a huge fan of Yakuake)
- type “sudo yum install system-config-display”
- give it your password (you may have to do this every time you type sudo)
- type “sudo system-config-display”
- this will open a window in your GUI (KDE, Gnome, XFCE, ICE, whatever) choose the options for your display (if using Yakuake you need to hit F12 to make the console window go away so you can see this new window)
- type “sudo yum install gcc kernel kernel-devel kernel-headers”
- restart the VM to boot with the newest kernel
- goto the Devices menu and select install Guest additions
- back to the console and type “sudo mount /cdrom /media”
- type “sudo /media/VBoxLinuxAdditions-x86.run”
- (special note, if you have already run the VBox Additions from the cd, skip steps 7-10 and just type this “sudo /etc/init.d/vboxadd setup”
- now I do not remember if I had to create the share for My Documents in VirtualBox or if it was there by default, but I have one, called “documents” and that is the one I am using in this example. so, type the following “sudo mkdir /mnt/shared-docs”
- type “mount -t vboxsf documents /mnt/shared-docs”
- then you can now access your Windows XP My Documents folder from your Fedora 12 install in the /mnt/shared-docs folder!!!
Really not that hard, but nowhere in the documentation for VirtualBox does it tell you that you have to do all of that!
Now, you can type “su -” and give it your password, then you do not have to use “sudo” at all for the entire process. you may ask why I do it then, and it is because I work on linux and unix systems for a living (or at least I am trying to) and for security reasons they tell you to never su to root (become the root user) as it is too easy to type an accidentally command in that will make the entire system irreversibly broken (with out restoring from a backup) and since I have been logged into some servers that are used in the monitoring/maintenance of the space shuttle and international space station, so making one of those stop working for several hours or more is a really bad idea! therefore you sudo every command you need to run as root instead of becoming root, gets annoying at times, but almost eliminates the chance of accidental termination of your employment!
Ok, so a note, I am running this Fedora 12 VM on a single core laptop with 2GB of Ram (1.5GB given to Fedora, and nothing running in the host except the VM) and when I ran step 5 step 6 (I added a step later), it practically halted my system and took almost 30 minutes (part of the reason why I fell asleep) it would say it was downloading a 8.6 meg file and take 14 minutes to do so, at 858Mb/s (which is impossible I know, but that is what it did and said) anyway, the main reason I did this, is that I had downloaded some other Fedora .iso files and filled my Virtual HDD and needed to get them off!!
So, now you know… and as we all know… Knowing is half the battle!
************editing updates and bonus steps! *********** May 10th 2010 ****************
Bonus step!!
now I bet you want to know how to make it comeback after a reboot, don’t cha!
- sudo vi /etc/fstab
- “G” (uppercase letter)
- “o” (lowercase number)
- [name you used in VBox shared folders] [tab] [fullpath to the mount point in the VM, or #12 above] [tab] vboxsf [tab] noauto,rw [tab] 0 [tab] 0 (both of those are the number zero)
- [esc] (the escape key, probably is labeled “esc” on your keyboard in the top left corner)
- “wq!” (lowercase letters and an exclamation (sometimes called a “BANG” by unix people, older people, and those who were taught by one of the afore mentioned.))
- now reboot
- sudo mount [name you used in VBox shared folders] (you will have to do this everytime you reboot (I just do a save state, so not an issue very often) as the fstab loads the mounts BEFORE the VBox additions are run, causing a “not found” error if it is not setup this way)
Special note: the folder name from VirtualBox shared folders is normally the name of the last directory in the path, for example if you are sharing /home/[my username]/Downloads/mystuff – then your VBox shared name will be “mystuff”
***note
you can now visit my Ubuntu 10.04, VirtualBox, and shared folders – a how to
[finndo@fedora12KDE yum.repos.d]$ sudo mount -t vboxsf documents /home/finndo/Documents/localmount: unknown filesystem type ‘vboxsf[finndo@fedora12KDE yum.repos.d]$ sudo mount -t vboxsf documents /home/finndo/Documents/localmount: unknown filesystem type ‘vboxsf’
Twitter: finndo77
- New blog post... Diablo III closed Beta http://t.co/dKC2ChWm 01:36:32 PM December 07, 2011 from joelperryproductions.com ReplyRetweetFavorite
- New blog post... resolving video problems with K-L-Ubuntu and XFX Radeon 6850 http://t.co/H6bXuMqi 06:59:18 AM October 22, 2011 from joelperryproductions.com ReplyRetweetFavorite
- New blog post... Computer upgrades http://t.co/6PWVNy4m 01:39:35 PM October 20, 2011 from joelperryproductions.com ReplyRetweetFavorite
- $7 for $15 Worth of Hand-Tossed Pizza, Calzones, and Drinks at Andolini's Pizza Charleston, SC http://t.co/QnKwPwB 11:49:26 AM August 29, 2011 from Tweet Button ReplyRetweetFavorite
- New blog post... is zdnet.com/news down http://t.co/DThuI4r 07:57:28 AM August 17, 2011 from joelperryproductions.com ReplyRetweetFavorite
- New blog post... Netflix Down? http://bit.ly/q74Svu 07:39:30 PM August 08, 2011 from joelperryproductions.com ReplyRetweetFavorite
Blogroll
programming
Tech Websites
- a good coder I found on CodeProject
- Barebones HTML coding chart
- Code Project
- Extreme Overclocking
- FreeBSD blog
- Legit Reviews – Tech Hardware Review
- Linuxtopia
- Notion Ink – homepage
- Plug Computing web site and forums
- Tablet Roms – used to be – Notion Ink Hacks
- Ubuntu Forums post on the mount command and fstab file
- VMWare ESX blogger
- Wikipedia.org main page
- ZDNet's blog pages

