LinuxQuestions.org
Help answer threads with 0 replies.
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 04-11-2009, 05:15 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
Possible to have a VM inside a VM, inside a VM? Into eternity?


Is that possible-like holding a mirror in front of a mirror-a thousand windows into infinity-guess it would take a high-RAM machine?
Could I make it fit into 150MB's? A 150MB or less distro?
 
Old 04-12-2009, 03:56 AM   #2
reptiler
Member
 
Registered: Mar 2009
Location: Hong Kong
Distribution: Fedora
Posts: 184

Rep: Reputation: 41
Well, if you want a true infinite loop you'll need a way to access images which are deposited outside the VM. This could be solved with NFS.

Of course you can have multiple layers of virtualization, but as every VM comes with a bit of overhead it'll get slower the further you descend into your VMs. Even on a high-powered PC. It'll just take a bit longer.

The only thing similar to this I have done so far was running multiple OpenVZ-VMs inside a KVM-VM.
But nothing recursive as you seem to think about.

If you could explain what's behind your idea maybe we could think about it some more and find a better solution than cascading VMs.
 
Old 04-12-2009, 04:53 AM   #3
nrballard
LQ Newbie
 
Registered: Apr 2009
Posts: 2

Rep: Reputation: 0
I've entertained the idea, but there really doesn't seem to be any practical purpose. Have you come up with one?
 
Old 04-12-2009, 06:12 AM   #4
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
I have come up with one-problem for me is my 1GB RAM ain't enough after the 4th-5th window opens.
That is, I am running on live cd-using only the qemu from dsl-embedded, while running live I invoke the first window(1)-then inside that one I invoke another(2), then inside that one I invoke another(3)-then inside that one -another(4), etc.
So, I am running off a small MB livecd.
I am still trying now-will post screenshot next post.
Wanna know how I did it?
 
Old 04-12-2009, 06:32 AM   #5
reptiler
Member
 
Registered: Mar 2009
Location: Hong Kong
Distribution: Fedora
Posts: 184

Rep: Reputation: 41
But why do you think this cascading is necessary?
It would be a lot better for performance, and probably also a lot easier, if you'd just use the host-system to run multiple VMs instead of VMs inside other VMs.
 
Old 04-13-2009, 02:56 AM   #6
nrballard
LQ Newbie
 
Registered: Apr 2009
Posts: 2

Rep: Reputation: 0
Maybe as a security thing? Would this be served by a thick layer of NAT devices?
 
Old 04-14-2009, 02:13 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
So, reptiler-are there other ways to do it?
My VM-inside VM-inside Vm-on and on-all can save whatever on livecd-not many distro's(any) can do that.
 
Old 04-16-2009, 10:44 AM   #8
reptiler
Member
 
Registered: Mar 2009
Location: Hong Kong
Distribution: Fedora
Posts: 184

Rep: Reputation: 41
One of the main problems I see here is that running VMs in VMs builds up a considerable amount of overhead. Of course you also build up overhead when running several VMs side-by-side, but I'd say that this should be quite a bit less and thus have a smaller impact on the host-system.

Anyway, the "enjoyment" of running VMs heavily depends on the host-system and its capabilities.
As you say, you tested on a 1GB machine, which in my opinion isn't very suitable for desktop-virtualization in the first place. Especially when you consider that recent OSs already like 1GB or more for themselves in order to run nicely, outside a virtual environment.

The way I handle my VMs is this: Each VM gets 1GB of memory assigned to it. With a total of 8GB I could probably run 6 VMs without getting in trouble memory-wise. On the other hand I only have a dual-core-CPU, which will cause a slow-down on the host and the guests.
Effectively I usually run a maximum of 4 VMs at the same time, and usually 2 or 3 of those mostly idle around.

So, getting back to the topic what I would suggest, if I understand your project correctly (which I guess might be a LiveCD with different distros you can easily fire up in a VM and try them out) is having the host-system and then have several images with the guest-systems, pretty much the same way I have it on my PC. One host, multiple guests.

Also you may want to think about having a little shell-script which would detect if the CPU supports virtualization, how many CPUs/cores and how much RAM are available.
That way you can automatically decide if you have to use QEmu or if you can use KVM. You can adjust how much memory is assigned to a VM and maybe even impose some sort of limit on the number of VMs you let the user start, based on the number of CPUs/cores and amount of RAM available.
 
Old 05-15-2009, 08:20 AM   #9
archtoad6
Senior Member
 
Registered: Oct 2004
Location: Houston, TX (usa)
Distribution: MEPIS, Debian, Knoppix,
Posts: 4,727
Blog Entries: 15

Rep: Reputation: 233Reputation: 233Reputation: 233
Yo, linus72 --

You've been asked politely WHY? several times, & I don't see an explicit answer.

In my case, I want to know if you have a practical application, or if it's one of those because-it's-there or wouldn't-it-be-cool things?
 
  


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
iptables inside client to inside host with outside DNS or IP - Help! linuxhelp2 Linux - Networking 1 10-15-2005 07:19 AM
Linux Inside fieldyweb Linux - General 10 07-14-2005 11:28 AM
What's inside RPMs? bongski55 Red Hat 2 05-11-2004 11:35 PM
Attacks : 80% from the inside? iainr Linux - Security 2 04-25-2004 05:02 PM
Kernel Inside Out unixbrain Linux - Newbie 6 09-23-2003 07:18 AM


All times are GMT -5. The time now is 09:34 AM.

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