LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-30-2009, 03:07 PM   #1
linus72
LQ Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: PocketWriter/MinimalX
Posts: 5,087

Rep: Reputation: 337Reputation: 337Reputation: 337Reputation: 337
Reasons for using Qemu/VMware/Virtualbox??


Just wondering, but why do members here and Linux users use virtual programs like Qemu,etc?
What things can be accomplished?
I'm sure there are many reasons-please list them...
 
Old 03-30-2009, 03:12 PM   #2
reptiler
Member
 
Registered: Mar 2009
Location: Hong Kong
Distribution: Fedora
Posts: 184

Rep: Reputation: 41
I use KVM, which build on QEmu.

Why do I use virtualization? Because it makes things easy.
  • I can easily test another distro/OS without having to leave my main distro. I simply run it in a window.
  • I can create test-environment which would more hardware than I have available. Like setting up 3 VMs for a cluster.
  • I can try out stuff without being at risk to mess up my system.
    This especially comes in handy as I work on my own distro and thus have a lot of compiling to do, which, if done wrong, could easily mess up my system.
I guess these are the main reasons.
 
Old 03-30-2009, 03:32 PM   #3
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2 on Lenovo Thinkpad W520
Posts: 7,094

Rep: Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239
I use VirtualBox in Slackware 12.2 and have two more distributions in it, namely Windows 7 beta and Slackware-current.

For that you need only between 5 and 10 GB space per distribution on your hard disk:
Code:
bash-3.1$ du --max-depth=2 -h /home/didier/.VirtualBox/
15G     /home/didier/.VirtualBox/HardDisks
208K    /home/didier/.VirtualBox/Machines/Slackware
3,1G    /home/didier/.VirtualBox/Machines/Windows7
3,1G    /home/didier/.VirtualBox/Machines
18G     /home/didier/.VirtualBox/
bash-3.1$
This way, I keep a very simple HD layout:
Code:
bash-3.1$ df -h
Sys. de fich.         Tail. Occ. Disp. %Occ. Monté sur
/dev/root              16G  7,9G  7,7G  51% /
/dev/hda2              58G   39G   19G  69% /home
tmpfs                 506M   12K  506M   1% /dev/shm
bash-3.1$
I do not have to change it when I install a new distribution, nor do I have to run lilo in the "real" system.

If you have enough disk space you can have all the distributions in your _near_to_be_released_DVD_ installed in the same box

And you can even have several distributions running at the same time, but don't forget that each needs between 256MB and 1GB of RAM to run.

Last edited by Didier Spaier; 03-30-2009 at 03:35 PM.
 
Old 03-30-2009, 03:39 PM   #4
reptiler
Member
 
Registered: Mar 2009
Location: Hong Kong
Distribution: Fedora
Posts: 184

Rep: Reputation: 41
Quote:
Originally Posted by Didier Spaier View Post
For that you need only between 5 and 10 GB space per distribution on your hard disk:
I usually assign 8. For most things I try that's plenty.

Quote:
Originally Posted by Didier Spaier View Post
And you can even have several distributions running at the same time, but don't forget that each needs between 256MB and 1GB of RAM to run.
In order to run several VMs at a time (each with a GB of RAM) I upgraded to 8GB. And probably later this year I'll go from dual-core to quad-core for even more virtualization fun.
 
Old 03-30-2009, 03:53 PM   #5
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,817

Rep: Reputation: 609Reputation: 609Reputation: 609Reputation: 609Reputation: 609Reputation: 609
Cost. Instead of buying new hardware I can use existing hardware. That hardware may need a RAM/CPU/disk upgrade, but that's still leagues cheaper than new servers.
 
Old 03-30-2009, 04:01 PM   #6
Crito
Senior Member
 
Registered: Nov 2003
Location: Knoxville, TN
Distribution: Kubuntu 9.04
Posts: 1,168

Rep: Reputation: 53
It's cheaper than buying more hardware.

Of course, that assumes your hardware is underutilized. If it's already over-utilized all you're doing is adding another straw to the camel's back. So capacity planning is critically important.
 
Old 03-30-2009, 04:46 PM   #7
linus72
LQ Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: PocketWriter/MinimalX
Posts: 5,087

Original Poster
Rep: Reputation: 337Reputation: 337Reputation: 337Reputation: 337
Alright-those are great answers!
Now I have a couple questions-I'll post a different question after somebody answers these...
OK-with Qemu-Puppy and DSL-embedded both distro's can play off CD or USB, without restarting the computer, via Qemu-right?
Now-they both use .sh scripts to do this-but in different ways it seems...?
So, can I make a multi-distro CD/USB that has Qemu, like DSL-embedded/Puppy-Qemu, and is set up so that it will "play" the 4 or 5 distro's on the CD/USB via Qemu, just by inserting the CD/USB and invoking the script?
I would need to make a script that would give me a choice of which distro for Qemu to call up-yes?
How would I go about doing this?
 
Old 04-01-2009, 02:04 PM   #8
linus72
LQ Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: PocketWriter/MinimalX
Posts: 5,087

Original Poster
Rep: Reputation: 337Reputation: 337Reputation: 337Reputation: 337
Well-no one really answered my questions above, but I have another one too.
First-how do I setup VirtualBox as Didier has his above?

Second-is the question I asked in the previous post possible-
Code:
Now I have a couple questions-I'll post 

a different question after somebody answers these...
OK-with Qemu-Puppy and DSL-embedded both distro's can play off CD or USB, without restarting the computer, 
via Qemu-right?
Now-they both use .sh scripts to do this-but in different ways it seems...?
So, can I make a multi-distro CD/USB that 
has Qemu, like DSL-embedded/Puppy-Qemu, 
and is set up so that it will "play" the 
4 or 5 distro's on the CD/USB via Qemu, 
just by inserting the CD/USB and invoking the script?
I would need to make a script that would 
give me a choice of which distro for Qemu to call up-yes?
How would I go about doing this?
Third-can a Linux distro-let's say "DSL", be remastered through Qemu, VirtualBox, etc?

Probably not-but could I try remastering through Qemu, etc so if I mess something up no harm done?

Last edited by linus72; 04-01-2009 at 02:05 PM.
 
Old 04-01-2009, 03:20 PM   #9
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2 on Lenovo Thinkpad W520
Posts: 7,094

Rep: Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239
In a pinch:

Get VirtualBox here. Follow the last link: all distributions => i386 to download it. At time of writing file's name is VirtualBox-2.1.4-42893-Linux_x86.run

Run or sh the installer as root. It will install in /opt.

Make and install the modules (of course you need the kernel source and headers):
Code:
cd /opt/VirtualBox-2.1.4/src
su
make
make install
Ctrl + d
If I remember well the installer creates itself a symlink /usr/bin/VirtualBox pointing to /opt/VirtualBox/VBox.sh. Otherwise, do it yourself.

You can now run VirtualBox. First time you do so, it will create the ~/.VirtualBox directory

Other way: use the SlackBuilds for VirtualBox-OSE @ http://sackbuilds.org to make yourself the packages and install it. You won't get support for USB in the guests machines in that case, because it is not included in the OSE edition but it works as well.
 
Old 04-01-2009, 03:26 PM   #10
linus72
LQ Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: PocketWriter/MinimalX
Posts: 5,087

Original Poster
Rep: Reputation: 337Reputation: 337Reputation: 337Reputation: 337
Ran into an issue in Slackware 12.2 installing Pulseaudio-needed by Virtualbox-
read about Vbox install here-
( http://muhrizky.wordpress.com/2008/1...slackware-122/ )
I built/installed all the dependencies on that page with sbopkg-except when installing pulseaudio it says-
Code:
Building pulseaudio
Building Slackware package for pulseaudio...
  Must have a pulse group to run this script.
    # groupadd pulse
  Or something similar.
What does that mean?
 
Old 04-01-2009, 03:36 PM   #11
AlucardZero
Senior Member
 
Registered: May 2006
Location: USA
Distribution: Debian
Posts: 4,817

Rep: Reputation: 609Reputation: 609Reputation: 609Reputation: 609Reputation: 609Reputation: 609
It means you must have a group named pulse already. Run
Code:
groupadd pulse
 
Old 04-01-2009, 03:44 PM   #12
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2 on Lenovo Thinkpad W520
Posts: 7,094

Rep: Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239
That means that you should do what is written. As root:
Code:
groupadd pulse
To know more: "man groupadd".

There are plenty of guides, how-to and tutorials on the web on that topic, see for instance this one.

Last edited by Didier Spaier; 04-01-2009 at 03:45 PM.
 
Old 04-01-2009, 03:46 PM   #13
linus72
LQ Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: PocketWriter/MinimalX
Posts: 5,087

Original Poster
Rep: Reputation: 337Reputation: 337Reputation: 337Reputation: 337
Then why am I getting this error?
Code:
******************************************
PACKAGE BUILDING/INSTALLATION SUMMARY LOG
Using SlackBuilds.org 12.2 repository
Using the queuefile

pulseaudio:
Error occurred with build.  Please check the log.
What now?
 
Old 04-01-2009, 04:29 PM   #14
linus72
LQ Guru
 
Registered: Jan 2009
Location: Gordonsville-AKA Mayberry-Virginia
Distribution: PocketWriter/MinimalX
Posts: 5,087

Original Poster
Rep: Reputation: 337Reputation: 337Reputation: 337Reputation: 337
OK-got pulseaudio installed-downloading Vbox "VirtualBox-2.1.4-42893-Linux_x86.run" now. But can you elaborate on this-
"Make and install the modules (of course you need the kernel source and headers):"
What do you mean by that Didier??
 
Old 04-01-2009, 04:55 PM   #15
Didier Spaier
LQ Addict
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slint64-14.2 on Lenovo Thinkpad W520
Posts: 7,094

Rep: Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239Reputation: 2239
Do this as root:
Code:
chmod +x VirtualBox-2.1.4-42893-Linux_x86.run # make this file executable
./VirtualBox-2.1.4-42893-Linux_x86.run # run the installer
cd /opt/VirtualBox-2.1.4/src
make # make the kernel modules
make install # install it
modprobe vboxnetflt # load the first module
modprobe vboxdrv # load the second module
Note that the "modprobe" commands are only needed once, at next reboot these modules will be automatically loaded.

Please don't mix instructions. IMHO following this link was not needed. For instance I do not have pulseaudio installed and still VirtualBox works here. But don't worry, this won't hurt anyway, so you can keep it

One thing I forgot to tell you: you need to set-up a vboxusers group and make yourself member of it before you run VirtualBox. Do this as root:
Code:
groupadd vboxusers
gpasswd -a  your_user_name vboxusers
Then as a regular user type:
Code:
groups
to check. As hopefully you will see vboxusers in the output, to launch the application type:
Code:
VirtualBox

Last edited by Didier Spaier; 04-01-2009 at 07:22 PM. Reason: Misspelled command
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Qemu vs. VirtualBox Woodsman Slackware 23 08-24-2008 04:46 PM
LXer: Look out VirtualPC and VMWare... VirtualBox is in the house LXer Syndicated Linux News 0 04-09-2008 01:20 AM
From VirtualBox to VMware Server Neo-Leper Linux - Software 2 07-23-2007 01:10 PM
Use Qemu to boot VMWare 'image' ? lefty.crupps Linux - Software 2 05-24-2007 04:02 PM
Qemu or VMWare depam Linux - Software 11 05-06-2006 09:53 PM


All times are GMT -5. The time now is 04:23 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration