VirtualBox -- VMware-like but released under the GPL

Chat about Linux in general

VirtualBox -- VMware-like but released under the GPL

Postby scorp123 on Mon Jan 15, 2007 7:29 am

I just found the announcement on golem.de and I thought I share it here:

Effective as of January 15, 2007 InnoTek Systemberatung GmbH (Germany) has released their virtualisation product VirtualBox under the GNU General Public License (GPL).
http://www.virtualbox.org/

No more messing with VMware and closed source binary modules!

Kudos to InnoTek for giving us one more piece of freedom! 8)
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Linux Mint is funded by ads and donations.
 

Postby clem on Mon Jan 15, 2007 8:26 am

Hi Scorp123,

This looks really good. Did you try running it under Mint, does it work well (I saw a deb for Ubuntu Edgy..)? Also, did you try running Mint as a guest OS under VirtualBox? If it's fast enough it'll be a great help for me..

Clem
User avatar
clem
Level 15
Level 15
 
Posts: 5548
Joined: Wed Nov 15, 2006 8:34 am

Postby scorp123 on Mon Jan 15, 2007 11:57 am

clem wrote: Did you try running it under Mint
Nope, as mentioned in one of my previous postings I had to temporarily switch to OpenSUSE 10.2 ... and I am already hating it. Dependency hell and all that :D You only get to truly appreciate the beauty of apt-get and synaptic when you have to f*** around broken tools like zyppy, zen-updater and all the other "warcrimes" Novell put into this once great distro :evil: Without the few cool tools such as "smart" I'd go crazy here :roll:

clem wrote: does it work well
VirtualBox is fast like hell ... It's waaaay faster than VMware Workstation!! There is a small glitch in the installation ... at least on OpenSUSE. I don't know if this will apply to the Ubuntu version as well: The install script will create a group "vboxusers". So before you can use VirtualBox as your normal user you have to become a member of that group. And then you have to reboot ... apparently some modules need to be unloaded / reloaded and the cleanest way to do this is a reboot. But after that everything just works. VirtualBox too is using some kernel modules but different than VMware it's not forcing you to mess around with them. Anyone remember vmware-config.pl? You can just forget that here, VirtualBox just works. 8)

clem wrote: Also, did you try running Mint as a guest OS under VirtualBox? If it's fast enough ...
I booted Barbara (couldn't find Bea?) via assigning the ISO file as virtual CD-ROM and the speed is just mind-blowing! :lol: Even ACPI, sound (via OSS; you get a virtual Intel soundcard) and USB work. You just have to activate this stuff in the settings menu before booting your virtual machine.

Screenies --- my machine is a Pentium 4 2.8 GHz, NVidia Geforce 5600FX, 2 GB RAM, KDE 3.5, Beryl + Emerald activated and running, and LinuxMint 2.0 "Barbara" running inside VirtualBox 1.3.2

Live CD boot menu:

Image


Live CD desktop:

Image


I highly recommend this package! Besides, I just had a little chat with the devs, they are reachable via IRC: irc.freenode.org, Channel #vbox


Regards,
scorp123
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby Alephcat on Mon Jan 15, 2007 1:04 pm

thank you, you have just enabled me to fully migrate to mint I have been wanting to migrate my desktop for a while, but have had to keep windows on it for certain things now I should be able to virtualise and run them on that.
User avatar
Alephcat
Level 3
Level 3
 
Posts: 132
Joined: Wed Dec 06, 2006 6:13 am
Location: Chester

Postby clem on Mon Jan 15, 2007 2:24 pm

Cool.. this looks like my new favorite toy!! I'll be trying it out shortly and it'll hopefully replace vmware/qemu to test my generated ISO files.

Clem
User avatar
clem
Level 15
Level 15
 
Posts: 5548
Joined: Wed Nov 15, 2006 8:34 am

Postby scorp123 on Mon Jan 15, 2007 3:23 pm

clem wrote:Cool.. this looks like my new favorite toy!! I'll be trying it out shortly and it'll hopefully replace vmware/qemu to test my generated ISO files.
Definitely worth a try. VirtualBox definitely feels way way faster than VMware. The GUI is straightforward. If you have worked with VMware before you won't have any trouble to understand the options in VirtualBox.

Only big differences so far:

- To get your mouse and keyboard out of a VM again press the right Control key
- no bridged ethernet ... VBox is configuring NAT instead. Inside the VM you get a 10.x.x.x IP address, but other than that it just works, ie. Mint and Ubuntu immediately got an IP address and I was able to access the Internet, no messing around with any config scripts as in VMware. Unless you really really need bridged networking for your VM this is only a minor issue. NAT works just as well.

EDIT: My statement above is wrong. They just call it differently: Host Interface Networking ... that's the same as bridged networking in VMware.
Last edited by scorp123 on Tue Jan 16, 2007 9:17 am, edited 1 time in total.
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby scorp123 on Mon Jan 15, 2007 3:54 pm

I just found a German guy's blog ... He's discussing the installation of VirtualBox on Ubuntu. Apparently the glitch I mentioned is present in the Ubuntu version as well. The blog article I am referring to is here:
http://node-0.mneisen.org/2007/01/15/installation-von-virtualbox-unter-kubuntu/

So for Ubuntu (and therefore Mint) the installation procedure is ... :

1.) Get the *.deb Package for Edgy Eft:
http://www.virtualbox.org/download/1.3.2/VirtualBox_1.3.2_Ubuntu_Edgy_x86.deb

2.) Install the package using dpkg:
Code: Select all
sudo dpkg -i VirtualBox_1.3.2_Ubuntu_Edgy_x86.deb


3.) Make sure you are a member of the group "vboxusers":
Code: Select all
sudo usermod --append --groups vboxusers yourusername


4.) Reboot ... some kernel modules need to be properly loaded / unloaded / reloaded and a reboot is the cleanest way to do this ... or else you'll run into this stupid error:

Image

Just reboot and you'll never see this message.

Voila. That's it, have fun with VirtualBox :D
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby clem on Tue Jan 16, 2007 5:24 am

Oh.. that's a pity for bridged networking. It's only a detail of course and I'm sure they'll implement it soon or later. I would have liked to be on the same subnetwork though.. it would have helped me test mintDesktop's automatic browsing and samba sharing from the virtual guest OS.

Thanks for the tips Scorp123. If you feel like posting a howto in the tips and trick section don't hesitate. That's definitely a good one :)

Clem
User avatar
clem
Level 15
Level 15
 
Posts: 5548
Joined: Wed Nov 15, 2006 8:34 am

Postby scorp123 on Tue Jan 16, 2007 6:52 am

clem wrote:Oh.. that's a pity for bridged networking. It's only a detail of course and I'm sure they'll implement it soon or later. I would have liked to be on the same subnetwork though.. it would have helped me test mintDesktop's automatic browsing and samba sharing from the virtual guest OS.
I didn't try this yet, but I suppose if you launch a routing daemon and if you do IP routing / forwarding the right way then this would probably work nontheless, as if the VM were bridged?

EDIT + UPDATE: Bridged networing is possible!!

Check their user manual. They call it Host Interface Networking ... I am now testing this.
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby clem on Wed Jan 17, 2007 10:32 am

for some strange reason I had to use

Code: Select all
sudo usermod -a -G vboxusers clem ...


instead of

Code: Select all
sudo usermod --append --groups  vboxusers clem
User avatar
clem
Level 15
Level 15
 
Posts: 5548
Joined: Wed Nov 15, 2006 8:34 am

Postby scorp123 on Wed Jan 17, 2007 10:36 am

Shouldn't these two commands be the same?? :?
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby clem on Wed Jan 17, 2007 11:44 am

yes... they should.
User avatar
clem
Level 15
Level 15
 
Posts: 5548
Joined: Wed Nov 15, 2006 8:34 am

Postby scorp123 on Wed Jan 17, 2007 6:14 pm

BTW, bridged networking works. It's explained in their manual. It's slightly more complicated to setup than in VMware though. I wish they'd integrate this functionality automagically somehow so that as a user I don't have to bother about this ... On the positive side I'd have to mention though that it's all done with Linux system utilities. So what follows here is taken from Innotek's manual:

For bridging to work you need two additional packages:

1.) uml-utilities
2.) bridge-utils

Bridged networking or "Host Interface Networking" as they call it is achieved via the utilities tunctl and brctl, together with ifconfig.

So what they basically do is to create a TAP device, either dynamically or static, define a bridged interface and then set the real interface into promiscuous mode so that bridging works and packets may pass through.

All this stuff requires root priviledges though, so it's maybe a good idea to configure sudo so that it doesn't ask you about a password everytime you want to do this.

Another idea of course could be to put that into an init script. VMware too uses some init scripts, so why not. If you know you will be using VirtualBox a lot and that you will need bridged networking for your VM's ... why not?

Example for Static TAP:
Code: Select all
#! /bin/bash
# create a new tap device ... probably this will be tap0
/sbin/tunctl

# create a new bridged interface br0
/sbin/brctl addbr br0

# make sure eth0 is promiscuous
/sbin/ifconfig eth0 0.0.0.0 promisc

# add bridge br0 to real interface eth0
/sbin/brctl addif br0 eth0

# tell the bridged interface to get its address via DHCP
/sbin/dhclient br0

# bring everything together ...
/sbin/brctl addif br0 tap0

After that you can define tap0 as your bridged interface for your VM, and voila, your VM will appear on your LAN with its own DHCP-assigned IP address.

Dynamic TAP is slightly more complicated. The VBox manual divides this into multiple smaller sections, and I'd put some of this into init scripts so I don't have to bother with it more than once.

For example, they suggest to check the permissions of /dev/net/tun every time you want to use dynamic TAP. How annoying. I'd rather put something like this into some init script (which runs as root anyway during boot so we don't need sudo) and then be done with it:
Code: Select all
chgrp vboxusers /dev/net/tun
chmod g+rw /dev/net/tun

Then the real interface and bridging need to be prepared similar to the example above. I'd put this too into an init script so I don't have to bother with it more than once:
Code: Select all
#! /bin/bash
/sbin/brctl addbr br0
/sbin/ifconfig eth0 0.0.0.0 promisc
/sbin/brctl addif br0 eth0
/sbin/dhclient br0

Now we need to write start scripts and kill scripts which take the interface name we want to create as argument ... There is a section in the VM's network configuration where you would put this info, and hence TAP interfaces would be dynamically created or destroyed, depending if you powerup or shutdown a VM which is using this.

dynamic_tap_start.sh
Code: Select all
#! /bin/bash
sudo /sbin/ifconfig $2 up
sudo /sbin/brctl addif br0 $2


dynamic_tap_kill.sh
Code: Select all
#! /bin/bash
sudo /sbin/brctl delif br0 $2


I agree that this might look a bit frightning, but basically you can copy & paste this stuff and you're done. With all the stuff in place VBox is very easy to use. And given that it offers better speeds than VMware I'd say it's worth this little hassle.
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby clem on Wed Jan 17, 2007 7:05 pm

Cool. Thanks Scorp123. It does look frightening but it's good to know that bridge networking can be achieved. It can make an awful difference to be directly on the network sometimes, either for testing purposes or for some applications.

Thanks,
Clem
User avatar
clem
Level 15
Level 15
 
Posts: 5548
Joined: Wed Nov 15, 2006 8:34 am

Postby Fragadelic on Thu Feb 15, 2007 2:08 am

Awesome find.

Works well in Bea.

Using it to test a remaster from my remaster script. No more having to reboot or burn the isos - lol
User avatar
Fragadelic
Level 4
Level 4
 
Posts: 469
Joined: Wed Nov 15, 2006 11:05 am
Location: Canada

Postby scorp123 on Thu Feb 15, 2007 4:31 am

I had a chat with one of the devs yesterday. The next release of VirtualBox will natively support VMware's *.vmdk disk format so it would become very easy to convert VMware virtual machines into VirtualBox virtual machines.

Right now this is a complicated affair, you'd have to use qemu-img and convert your vmdk image into a raw image, and then use Innotek's vditool to convert the raw image into VirtualBox's native vdi format ...
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby JohnH on Thu Feb 15, 2007 5:21 am

thanks Scorp,
I've been using VMWare server for a while. I'll look forward to seeing it in Mint.

Incidently, I tested Mint Bea on an Ubuntu 6.06 host before I made the jump to Mint.

My favourite KDE based distro is Mepis and it sits on an external drive hosted by Mint... Some of the features a hobbled by VM's default settings e.g. video driver is generic VGA.

Regards
John
User avatar
JohnH
Level 4
Level 4
 
Posts: 215
Joined: Wed Nov 22, 2006 4:15 am
Location: Caboolture, Oz

Postby JohnH on Thu Feb 15, 2007 5:23 am

Oops, I meant to write that I look forward to seeing an improved Virtual Box under Mint.

Cheers
John
User avatar
JohnH
Level 4
Level 4
 
Posts: 215
Joined: Wed Nov 22, 2006 4:15 am
Location: Caboolture, Oz

Postby Fragadelic on Thu Feb 15, 2007 8:55 am

BTW, once you install the package and add your user to the group, all you have to do is log out and back in and it should work. You shouldn't have to reboot but you have to log out and back in for your user to get the new group added.
User avatar
Fragadelic
Level 4
Level 4
 
Posts: 469
Joined: Wed Nov 15, 2006 11:05 am
Location: Canada

Postby scorp123 on Thu Feb 15, 2007 4:21 pm

Fragadelic wrote:BTW, once you install the package and add your user to the group, all you have to do is log out and back in and it should work.
Did you try it? As I said there is a kernel module that gets loaded too, and it creates some virtual devices in /dev ... Logging in and logging out still won't re-create those devices for you. Hence the need for a reboot ... :wink:
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Linux Mint is funded by ads and donations.
 
Next

Return to Chat about Linux

Who is online

Users browsing this forum: No registered users and 4 guests