Screen capture was not working in a new install of Ubuntu in VirtualBox. The attempts would result in an image of the desktop background. Weird.
Since the default app didn’t work, I installed various other ones. None worked. Finally I installed Gimp. Even that didn’t work.
I think that ruled out an application issue. Left was Ubuntu, Unity desktop, hardware, VirtualBox, or me. Certainly not I.
It was the 3D setting on the virtual machine! Doh! I thought the check box was a request; if the system has no 3D support it would just not use that setting.
Environment VirtualBox: 4.1.6 Ubuntu: 11.10 Host: Windows 7 64bit
Off topic, but what a great rant! “Why I’ve finally had it with my Linux server and I’m moving back to Windows.” I know the feeling. I had Linux running on an old laptop. Then I tried to upgrade the distro. The laptop stopped working. Now nothing installs, Windoze, other Linux distros, nada. Boot sector issues or firmwear issues. I don’t know. One day I’ll buy an enclosure and try to reuse the laptop harddrive as an external USB backup.
How I set up a new VirtualBox VM running Ubuntu that could be reached from the local network.
I first used the Bridged Network setup, which did not work. This is on VirtualBox 4.1.4. I have other VB vms where the Bridged Networking does work. hmm.
On this VM I changed networking to:
- NAT. Network Address Translation.
- Defined a Port Forward rule (via Virtual Box GUI). Ports on hosting PC get mapped to the VM guest. For example, 22.
- Made sure the Windows 7 Firewall allowed the external port.
- Defined a port forwarding at my network provider.
- Defined a port forward at my local router.
At least, that is what I think I did. In the turmoil of getting things to work, research what others tried, and then success, it is hard to get the actual process just right.
Saved, then waited; takes a while for everything to percolate through the network. Opened the URL and voila, I have access!
Installing over older version was not that hard this time.
First I created snapshots of each VM in my VirtualBox. Next create a restore point for Windows 7, just in case VB destroys stuff.
Then I downloaded and installed the new VirtualBox 4.1.4. It locked up. Went thru some stuff, showed a full taskbar but nothing. No exceptions or suspicious threads in Windows’s Proc Explorer. Install wouldn’t cancel either, had to kill it. Retried but it said there is another install going on. Did not see one in task list.
I rebooted Windows PC. Tried to start the existing Ubuntu VM, but it failed, one of the virtual network drivers is hosed. Shucks. Hmmm. Maybe VirtualBox will install again? This time I right clicked on the downloaded file and choose “Run As Admin”. It installed!
No 3D Unity interface. Guest Additions not updated. Clicked on device menu and install Guest Additions, nada!. I keep forgetting you have to install it manually for a Linux guest. For this I followed the VirtualBox user manual.
First do the steps in 4.2.2.1.1. I ran those using sudo. Second, follow steps in 4.2.2.1. Again using sudo. Shut down VM. In the VirtualBox gui, change the Ubuntu display to 3D. Start Ubuntu VM.
Success, I have the Unity interface again.
Updates
On this system I updated to Ubuntu 11.10 (codenamed Oneiric Ocelot). Works fine.
Environment
VirtualBox 4.1.4.
Host: Windows 7 Professional 64bit.
Guest: Ubuntu 11.10 codenamed “Oneiric Ocelot”, Unity desktop.
PC: AMD quad with 8GB ram.
Brain: of carbon-based life form, Earth, Homo sapiens sapiens.
Han Solo and The Princess (Love Theme) from “Empire Jazz”
Took a bit of effort but I got with my Windows 7 64bit host the VB 4.0.8 update to work with Ubuntu 11.04 w Unity.
When I go to the menu Machine > Session Information, the runtime tab says my Guest Additions is 4.0.4_OSEr70112. Shouldn’t that be 4.0.8_711778, since that is what I loaded?
Hmm, this does show 4.0.8 for one property. Maybe I’m missing some step?
Issues with upgrade?
What were my issues with the upgrade? Ubuntu VM would not complete the boot up. First it was the freeze at checking battery state, then after getting by that, it was the freeze at installing new binary file formats.
I tried some of the suggestions found on the web. The final one I tried is listed below. But, even that didn’t work. Yet after a few reboots of the vm and setting the 3D mode for graphics it finally rebooted fully.
Environment
Host: Windows 7 Professional 64bit.
Guest: Ubuntu 11.04 “Natty Narwhal”, Unity desktop.
PC: AMD quad with 8GB ram.
Brain: Belonging to carbon-based life form, Earth, Homo sapiens sapiens.
The upgrade to Natty Narwhal was pretty smooth. At first it failed cause my 8GB virtual drive did not have enough free space for the upgrade process. So I ran the Computer Janitor (I think that was the app) to make room. One day I’ll have to figure out how to increase my vm disk size (the snapshots, I read, make this complex).
After that it was pretty quick though at some points it prompted with some Linux geeky questions I had no way of answering, like “do you want to keep the cosmic figenbouton driver file?”. Yea, I said to keep everything. Finally restarted and then it said the Unity Desktop interface could not be used, I needed 3D. So, I shut Ubuntu down and in VirtualBox enabled the 3D options for the Ubuntu VM. Restarted and 3D worked. Hmmm, never did before, and I always had the same graphics card.
Unity looks good. I don’t see the revolution in it yet. The task bar is on the side, the “Start” button is on top, etc. The Launcher is ok. I could not find the Admin apps. It should have at least migrated the former menus into a legacy category. And the default transparency is too transparent.
But, it does rise to the Windows 7 level of usability (I don’t know about the Apple world, I’m not rich). Microsoft needs to innovate more. Stop copying and come up with something. Ubuntu is looking sweet.
Right now I’m listening to a Triple Concerto by Bach that is on my Windows 7 hard drive. It is playing in Ubuntu via the automatic shared drive that VirtualBox now allows. Chrome, FireFox, and Solitare is running in Ubuntu. A bunch of stuff in Windows 7. Pretty cool.
Verdict?
I recommend Ubuntu 11.04 and the Unity interface.
Update
Have been using it today. Unity Desktop has some warts. Once I was moving the mouse into a window so I can drag its right edge and make it wider. The little thumby scroll widget kept cropping up. Ugh! Little things like that. Not much, but they add up. No right mouse button click for properties and other things? Weird. Maybe its an option setting.
I was once successful installing Ubuntu on this very old laptop. Since then the hard drive was wiped. Maybe I can install Linux again?
Nope! The latest Ubuntu 10.10 would not. But I think that was a CD media errors since I was getting: SQUASHFS error: Unable to read page, block [letters/digits], size [letters/digits] And, this page says so.
I had an Ubuntu 10.04 LTS CD available so I tried that. Installed fine. However, after I login, the screen gui is blank. I remember this issue and their is a fix or if I have time try to burn another Ubuntu 10.10 CD. Unfortunately the laptop cannot boot off of thumb drive.
VirtualBox 4.0 can now mount shared folders automatically!
Yes, you could always do it with a few edits of some system config files, but this puts it at a non-geek average user level, a file sharing for idiots perhaps. The instructions on creating shares is in the VB manual section 4.3.2 Automatic Mounting.
I tried it and can now see my full C drive on Windows 7 from the Ubuntu guest running in VirtualBox (VB). But, at first, it did not work, and a previous manually mounted share also stopped working, both with access permission problem. The big detail I missed:
Access to auto-mounted shared folders is only granted to the user group vboxsf, which is created by the VirtualBox Guest Additions installer. Hence guest users have to be member of that group to have read/write access or to have read-only access in case the folder is not mapped writable.
So after you create the share you have to add users to the vboxsf group. Using the Ubuntu UI you navigate to System, Administration, Users and Groups, then Manage Groups. Now find vboxsf and show its properties, from there you can add users. Reboot.
From the Oracle VM VirtualBox manual:
4.3.2. Automatic mounting
Starting with version 4.0, VirtualBox can mount shared folders automatically, at your option. If automatic mounting is enabled for a specific shared folder, the Guest Additions will automatically mount that folder as soon as a user logs into the guest OS. The details depend on the guest OS type:
With Windows guests, any auto-mounted shared folder will receive its own drive letter (e.g. E:) depending on the free drive letters remaining in the guest.
If there no free drive letters left, auto-mounting will fail; as a result, the number of auto-mounted shared folders is typically limited to 22 or less with Windows guests.
With Linux guests, auto-mounted shared folders are mounted into the /media directory, along with the prefix sf_. For example, the shared folder myfiles would be mounted to /media/sf_myfiles on Linux and /mnt/sf_myfiles on Solaris.
The guest property /VirtualBox/GuestAdd/SharedFolders/MountPrefix determines the prefix that is used. Change that guest property to a value other than “sf” to change that prefix; see Section 4.6, “Guest properties” for details.
Note
Access to auto-mounted shared folders is only granted to the user group vboxsf, which is created by the VirtualBox Guest Additions installer. Hence guest users have to be member of that group to have read/write access or to have read-only access in case the folder is not mapped writable.
To change the mount directory to something other than /media, you can set the guest property /VirtualBox/GuestAdd/SharedFolders/MountDir.
Solaris guests behave like Linux guests except that /mnt is used as the default mount directory instead of /media.
To have any changes to auto-mounted shared folders applied while a VM is running, the guest OS needs to be rebooted. (This applies only to auto-mounted shared folders, not the ones which are mounted manually.)
I’ve been running Ubuntu Linux 10.03 on a VirtualBox VM with the Windows 7 host PC. Works fine. Updated to Ubuntu 10.10 – the Maverick Meekat, restarted the system, and now it comes up in console mode and asks for a user/pass. I give it what I have, and it doesn’t accept it. Hosed. Gee ain’t Linux grand.
Hmmm. Let me try again. Ah, it accepted another username/password, which is not the one in my Keepass database, now that needs maintenance.
GUI
But, now how do I get the Ubuntu gui back. Tried to reinstall the Guest Additions. Nope, even though I do the Devices->Install Guest Additions, I don’t see the CD in /media/cdrom folder.
Hero waits. Villain will come, maniacally cackle and talk. Hero can loosen bonds and save the world. Villain comes in, shoots the hero.------4 months ago