More distro's on one harddrive

Posts: 28
nyshiro
Joined: 28 Apr 2014
#1
Good Evening,

I like to install several distro's one HDD (i must tell you i do not have a lot experience with linux )

I've formatted my HDD in one extended partion and a swap partition (found this information on the internet)
The extended partition i divided in several smaller partitions and formatted them as ext4
- In sda5 i installed linux mint maya and it worked as expected (1 distro) .
- Then in sda6 i installed Antix M14 and registered it as to be the (/) bootable partition of the system. That worked . The system showed me
after reboot the Antix menu with linux mint a little lower in the menu. After clicking on Linux Mint , it started.
- Then i try to install Puppy Linux in sda10 ; just for practicing.
I got during the install the advise to insert the following information in de boot record.
-------------------------------------------------------------------------
If you have GRUB installed, find the 'menu.lst' file (usually in /boot
in the partition in which GRUB is installed) and insert the text,
or, if you have GRUB4DOS installed, find the 'menu.lst' file (usually
in / in the partition in which GRUB4DOS is installed) and insert this:

title Puppy Linux 5.7.1 full install in sda10
root (hd0,9)
kernel /boot/vmlinuz root=/dev/sda10 pmedia=atahd
---------------------------------------------------------------------
I looked for the above file in Antix but couldn't find it, and i don't know how and were to insert the above information.

Can anybody help me or advise how to do this.
What is the best order to install the next distro's .
I like to install Antix M14 / Antix 14R / Linux Mint / Pclinux / Puppy Linux / Ubuntu etc
Last edited by nyshiro on 21 May 2014, 20:17, edited 1 time in total.
Posts: 2,238
dolphin_oracle
Joined: 16 Dec 2007
#2
MX 14 uses grub 2, which uses a different configuration file. You should be able to add a new entry with grub-customizer in the MX-14 menu.
Posts: 667
jdmeaux1952
Joined: 01 Nov 2013
#3
Oh yea! GRUB2 threw me for a loop at first. And caused some confusion. Quite a few of the newer distros (and their updates) are starting to use GRUB2. WHY? Because of UUID (Universaly Unique Identifier) standards.
========= SCRAPER REMOVED AN EMBEDDED LINK HERE ===========
url was:"https://en.wikipedia.org/wiki/UUID"
linktext was:"https://en.wikipedia.org/wiki/UUID"
====================================


Well, once you have installed a distro (in your and my case MX-14) which uses GRUB2 and UUID, do not make the mistake I did and start trying to install the Grub (or grub2 for that matter) to the /MBR. WHY? Because a distro that uses Grub2 will overwrite the Grub2 configuration files with its own distinct UUID numbers for each partition. And trust me, a Grub2 written by MX-14 will not have the same UUID numbers for a distro like Neptune. (And since Neptune was added to the HD after MX-14, AND I made the mistake of not loading the Grub2 file to /root, Neptune over-wrote the work the Grub2 file that MX-14 had installed. It didn't go into MX-14 and overwite the file. Neptine wrote its own and had the /MBR only recognize the Neptune Grub2 file.) Then when you try to correct a faulty Grub file, you won't know which one it is you need to edit. I totally buggered my laptop that way, and was forced to RELOAD EVERYTHING. And that's not fun.

Since you now have MX-14 loaded, any future distros you load should have its Grub file written to /root,and not /MBR. That way all you need to remember is to go to MX-14, update-grub, and then edit that file (in / etc/boot/grub/grub.cfg). And if you do load a distro that uses Grub2, and it does overwite what you want, you can always go back , reload MX-14, go to the Terminal,"sudo update-grub", and then edit the grub-cfg file in MX-14. That makes it so much easier.

Or do as dolphin said, and use the grub-cusomizer in MX-14.
Posts: 604
thriftee
Joined: 27 Feb 2009
#4
Mine are similar. I have Vista, antiX, Manjaro, Debian and Puppy Precise 5.71 on one, and had the same problem. the best practice I could come up with was to choose the one that I liked enough to keep and with a good grub, and do the grub setup work with that one. So, in the case of puppy, I did not let it try to install grub, and instead took the text in the file, like the stuff you put in above, and crafted it into the 40_custom section of the grub setup. I'm booted under vista at the moment, so can't access it, but will come back and edit the text. Be aware that the syntax they have given (like yours above), was designed for the earlier grub version (like antiX 13.2 was), and in my case was incorrect, and so I had to make a bunch of changes to it to get it right.

I went and looked at grub-customizer, and it looks like it will help you set it up, instead of manually editing the text into the 40_custom file and running grub-update like I did. Unfortunately, the machine that I did that on is doing an o/s install at present, so I can't get in to copy the files, but its not that hard to change them if you look at the lines for the o/s you already have, match the syntax and change the names and partitions to match your added o/s.

Ok, I looked and I'm sorry, but it looks like I lost that / etc/grub.d/40_custom text that I had added for puppy, but I will try to translate what you have above:

Code: Select all

title Puppy Linux 5.7.1 full install in sda10
root (hd0,9)
kernel /boot/vmlinuz root=/dev/sda10 pmedia=atahd
On my system that uses grub 2 (with an msdos partition, not sure if that's why the msdos10), this would be entered in the 40_custom as:

Code: Select all

menuentry 'Puppy Linux 5.7.1 full install in sda10' {
set root='hd0,msdos10'
linux /boot/vmlinuz root=/dev/sda10 pmedia=atahd
}
You should be able to use your antiX to mount the sda10 volume and look to make sure that the /boot folder contains vmlinuz. I needed a 2nd line:

Code: Select all

initrd /boot/initrd.gz
But puppy has different ways of loading, so perhaps yours doesn't need a 2nd line. I want to say I had to manually create the /boot folder and copy the files from my puppy USB to it to get it to work.
Last edited by thriftee on 23 May 2014, 06:23, edited 1 time in total.
Posts: 604
thriftee
Joined: 27 Feb 2009
#5
Aha! I did find that drive! Too many machines around here!

menuentry"Puppy Linux Precise 5.7 on /dev/sda6" {
set root='(hd0,msdos6)'
linux /boot/vmlinuz
initrd /boot/initrd.gz
}

Please note the braces. I forgot themn in the post above, but will go add them now...
Posts: 28
nyshiro
Joined: 28 Apr 2014
#6
Thanks for the explanation.
At this moment my experience is to less to understand what to do.
I have to study some more of linux to understand how and what i have to update. The difference between grub and grub2.
is it oke to format (ext4) my disk in one big extended partition , divided in several partitions, and one swap partition.
Or do i have to format the disk in a different way.
Posts: 4,164
rokytnji
Joined: 20 Feb 2009
#7
is it oke to format (ext4) my disk in one big extended partition , divided in several partitions, and one swap partition.
Yes. It is OK. I used to multi boot like you plan to do.

Now. Instead of recommending on what I prefer to do.
I would install MX-14 first to MBR. Use it;s grub 2 to pick up other Windows or Linux installs.

Install any other later linux install grub. When it asks. I tell it to install to root folder.
It will not matter if it is grub legacy or grub 2.

Then use os-prober in MX-14 to load my other linux distros into the menu for grub 2 in MX-14 bootloader.

Me, I have my own ways but to new users they are too confusing because I am used to using grub legacy or grub4dos as my mbr boot
loader so I am leaving that out of this.
Posts: 604
thriftee
Joined: 27 Feb 2009
#8
If you have a big drive and want to have many operating systems on it, you will be well advised to use an extended partition and logical volumes for the different operating systems. I have windows in a primary partition (it used to have the entire drive, and I reduced its size), and then the rest I used to create an extended partition with 5 to 50 gb logical volumes for each linux version, and a swap volume which I sized at double the size of memory. I only allocate the logical volume space, format and label it as I add new operating system versions because resizing is very slow and I think its risky, too.

Grub and grub 2 basically do the same thing, but the syntax is somewhat different, and how its maintained is quite different. I think the smart way to play it is to load whatever you are going to load, and then go back and let your most used one control the boot if possible. I think grub is simpler, and might be easier to maintain by hand, but grub 2 seems good at generating the right startup code if its fed the right configuration. I like Roky's idea of letting the MX14's Grub 2 control the booting.

I want to get to where I am using BTRFS for my linux volumes, but it seems many especially older versions can't handle it, even if they allow it. Ext2 seems to be the one all can handle, but many now default to Ext4, so I would think whatever they default to is probably a good bet and will keep you out of trouble.

I am no authority on this at all. I've just done it a bunch of times lately.