LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Multiboot from the same partition - is it possible and worthy? (https://www.linuxquestions.org/questions/linux-newbie-8/multiboot-from-the-same-partition-is-it-possible-and-worthy-445833/)

WhyNot? 05-17-2006 06:12 PM

Multiboot from the same partition - is it possible and worthy?
 
I have a system with a 80 GB HD, in wich, after the first windows partition, I started to install distro one after the other, as I had no no knowledge in Linux, no internet and a sole Knoppix LiveCd to exemine for understand. So, I get distros from magazines and go on installing them on about 7 Gb partitions each, as far as i begin to understand something. Now I have Suse, Mandrake, Slackware and Fedora installed beyond Windows, and this means that if I want to run a program, I must remember if is in a particular distro, or install it four times if i want always have it. Much more, I waste space along the partitions, and get however many programs doubled.
So, I wonder if there is a way to put more than a distro in the same partition, putting each in a directory, , such this:

/---- |suse/--------- |bin/
| |usr/
| |.....
|
|mandrake/- |bin
| |usr/
| |.....
|
|slackware/- |bin
| |usr/
| |.....
|
|fedora/----- |bin
| |usr/
| |.....
|
|.....


and chrooting at startup, so to get visible the sole wanted directory.
And another important question: should be possible, on such a sistem, to install once a program, and make it work for all the distro using links? I'm not thinking to KDE or Gnome, that I found be tailor-made in some distro, I mean something like install OpenOffice2.0.
And an overall question: do you think all this could be worty, or there are simpler ways to obtain the same advantages?

I hope the matter can be interesting.

Brian1 05-17-2006 07:07 PM

The distros you mention differ a bit like FC is a Redhat distro and Slackware is a debian type distro. Each vary little on names of config files and structure. I myself don't see a good way to do it. Only Idea is use source code files and install them. Modify the makefile or adding things prefix= during the make command to define something like /opt instead of using /usr/bin. Difficult to say the least. I think you would be better off trying to like one really well and use that one most of the time. Then use the others to learn the differences.

Just my 2 cents.
Brian1

saikee 05-17-2006 07:21 PM

Don't think that is possible.

The boot loader booting a Linux must be giver the address of its "root" and that is usually the starting point of a partition.

During installation the installer wants to install the boot loader and regardless if it is in the MBR or the root partition the residing area is always in the boot sector of a partition. Never known one boot sector housing more than two boot loaders myself.

Although many programs may be repeated between distros but each one may be supported by different kernels using different features and parameters. It is safer to leave each system untouched as Linux has not been written to mixed with each other, as far as I am aware.

I keep my Linux in 5Gb partitions generally and the average installed sized is about 3.5Gb. Each one in its own partition can guarantee its intgrity being intact. You probably get into serious trouble if the work you do becomes unreliable or unpredictable when mxing between different distros within the same partition, if that can be done at all.

A simple example is chrooting from Linux A to Linux B. You are effectively using the Kernel of Linux A but working with the Bash shell of Linux B. That in itself creates many misunderstnading and puzzling behaviours.

Emmanuel_uk 05-18-2006 03:40 AM

Quote:

installing them on about 7 Gb partitions each
Prefer grub to lilo as boot loader if you can
(which version of Zindows?)

Then decide of one distro being your main one for admin
(especially editing /boot/grub/menu.lst)
You can have as many distro as you want being booted from that grub on distro 1

Alternatively, if you install the bootloader of each subsequent distro,
not in the MBR but in the new linux partition where the installation is taking
place you can tell grub in distro1 to chainload grub in partition of distro 2

Grub of distro1 can have up to ~240 (?!) line of chainloading to each
of the partitions

You need only 1 swap for all the distro

some newbie reading see lq bookmark search fpr newbie, also rute

WhyNot? 05-19-2006 06:06 PM

Thanks a lot for your answer, saikee.

Quote:

Originally Posted by saikee
A simple example is chrooting from Linux A to Linux B. You are effectively using the Kernel of Linux A but working with the Bash shell of Linux B. That in itself creates many misunderstnading and puzzling behaviours.

I actually made some try using the "init=" option of Grub, using it to execute a batch and then launch init, but init said "timeout reading/writing in /dev/initctl" and then remove itself. I think it's one of the "misunderstanding".

Perhaps I will try LVM to solve the "fragmenting" between partitions, and/or to make a separate partition for the "home" directory, also if I havent' many file to manage in it.

WhyNot? 05-19-2006 06:25 PM

Quote:

Originally Posted by Emmanuel_uk
Prefer grub to lilo as boot loader if you can
(which version of Zindows?)

Then decide of one distro being your main one for admin
(especially editing /boot/grub/menu.lst)
You can have as many distro as you want being booted from that grub on distro 1

Alternatively, if you install the bootloader of each subsequent distro,
not in the MBR but in the new linux partition where the installation is taking
place you can tell grub in distro1 to chainload grub in partition of distro 2

Grub of distro1 can have up to ~240 (?!) line of chainloading to each
of the partitions

You need only 1 swap for all the distro

some newbie reading see lq bookmark search fpr newbie, also rute

Thanks, Emmanuel_uk; this is almost the configuration I have now in my system (distro1 is Suse). The problems are substantially two: four 2.5-3 GB free spaces instead of one of 11 GB, and to use one distro to work with a program, another to use another, and so on.

I think I'll use LVM for the first problem. For the second, perhaps I'll rearrange programs between distributions, to group similar programs in each distro.

Best regards.

Emmanuel_uk 05-20-2006 10:31 AM

Quote:

four 2.5-3 GB free spaces instead of one of 11 GB
LVM to crack a nut?
If these distro are continuous you may delete them, shrink them, enalarge them.
Most distro can leave in 5 Gb, quite a few in 3 if you do not install everything
Deleting partition may end up renumbering them, so get ready to edit grub bootline
if this happens and keep a live cd at hand. It can happen, not a big problem.

Quote:

and to use one distro to work with a program, another to use anothe
You will quickly find out that you test and delete distros,
but keep the same one or two.
You will find repositories with most of the software, so even if it is not
on the cd/dvd, it is out there on the net
I cannot see why you want to use a spec distro for each software unless
you had such specific distro as knopMyth or cinerela


All times are GMT -5. The time now is 11:09 PM.