Re: Installing linux inside linux?
On Sat, 2003-06-21 at 11:23, Joel Konkle-Parker wrote:
> I've heard of several methods of installing Debian within an already
> running Debian install on the same partition.
>
> - Bochs: an emulator, does this recreate a system worthy of a debian
> install? or will emulator-specific problems arise?
Can't say I've tried it, so I'll leave that one for someone else ..
> - chroot: what's a chroot?
chroot changes a process' view of the filesystem .. specifically, where
the root of the filesystem is (hence ch(ange)root). Here's an example
transcript:
/root # cd /mnt/redhat
/mnt/redhat # ls
bin boot dev etc halt home initrd lib lost+found misc mnt
opt proc root sbin tmp usr var
/mnt/redhat # chroot . /bin/sh
/ # ls
bin boot dev etc halt home initrd lib lost+found misc mnt
opt proc root sbin tmp usr var
There I've started /bin/sh but chroot'd so that /mnt/redhat appears as /
(but only to /bin/sh and it's children - the rest of the system is
untouched).
See http://www.debian.org/doc/manuals/reference/ch-tips.en.html#s-chroot
for more details
> - UML: patch for kernel? I don't want to recompile my kernel
While User-Mode Linux can benefit from a kernel patch (the skas patch),
it's just a normal process - it doesn't require any modifications to
your running kernel.
Simply apt-get install user-mode-linux (and optionally
user-mode-linux-docs), then grab a pre-made filesystem for it from
either
http://people.debian.org/~mdz/uml/
or
http://user-mode-linux.sourceforge.net/dl-fs-sf.html
See the howto on user-mode-linux.sourceforge.net for more details.
> Are there any other ways of doing this I'm not aware of?
Not that I'm aware of - bochs and similar will run linux within an
emulated PC, user-mode-linux will let you run linux within it's own
kernel, and chroot will let you run a process within it's own corner of
the filesystem. Which is better simply depends on how isolated from the
host machine you want the "linux within linux" to be.
> I have 1 hard drive with a windows partition, and one each of /, /boot,
> and scratch partitions, running Woody on the linux side.
chroot uses an existing directory, uml uses files containing filesystems
- neither will require new partitions.
> Thanks in advance.
>
> --
> Joel Konkle-Parker
> Webmaster [Ballsome.com]
>
> Phone [662-518-1636]
> E-mail [jjk3@msstate.edu]
>
Hope this helps / makes sense
Shaun
Reply to: