Dual Boot=Mg5 (sda) and Void Linux (sdb!)

This forum is dedicated to basic help and support :

Ask here your questions about basic installation and usage of Mageia. For example you may post here all your questions about getting Mageia isos and installing it, configuring your printer, using your word processor etc.

Try to ask your questions in the right sub-forum with as much details as you can gather. the more precise the question will be, the more likely you are to get a useful answer

Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby aldQueiroz » Jul 19th, '16, 18:19

Hi, it's been a long time far from forum.
I have two HDs in my desktop: the first one (sda), with 500GB, is holding my current 'production' Mageia 5 (KDE 4) installation, and a second (sdb), old 80GB HD, which until recently was holding another Mageia 5 installation (with XFC), for evaluation and/or backup purposes. Prior installation boots with GRUB 1.5, and I successfully made a entry to boot at second HD, 'calling' also GRUB installed at second HD to choose boot options. That configuration was working fine.
Then, I decided to install Void Linux (LXQt 'flavour') in the second HD of my desktop replacing the installation of Mageia 5/XFCE; I didn't change anything of GRUB configuration at sda, having in mind that the entry for that second system would appoint to sdb and call its all GRUB. However, it didn't work; Void Linux boot process is missing start mouse drive and, maybe, something else... Void's GRUB 2 screen is bypassed, further DM screen rises, but I cannot select user neither type password...
If I restart the desktop and press F8 button during memory check I still can select the second HD, and boot normally.
I'm away from my Mageia desktop, so I cannot provide right now details of GRUB configuration. I'll get it as soon as possible.
Meantime, any suggestion of what to do? I read other topics related to GRUB configuration for dual boot, including this one, but couldn't find tips useful to my own situation so far.
I look forward to have your attention and help.
Regards!
aldQueiroz
 
Posts: 51
Joined: Oct 18th, '11, 18:44
Location: Brazill, Rio de Janeiro

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby gohlip » Jul 20th, '16, 12:01

This is what I understand

o Your Mageia 5 is in 500 GB and that is the 'default boot' when you start up the computer.
o That 'default boot' is from Mageia 5 in 500 GB OS and is using grub-legacy (you mentioned GRUB1.5, I think you mean stage 1.5)
o You have installed Void linux in 80 GB which will not boot from Mageia grub
o That Void is using grub 2 and is 'set' to that 80 GB drive.
o If bios is selected to boot from 80GB, Void boots okay (but you want Mageia's boot from 500GB to boot it)
o Not stated but assumed - both drives are msdos partitioned and boot is bios-legacy.

Need a few things for you to check.
o Confirm that in Void, there is a core.img in /boot/grub/i386-pc/
(Need the path to be correct)

My problem here - I am now not good in grub-legacy (was very good last time), have not used it for at least 5 years.
But if you can get to Mageia's grub-legacy prompt (press 'e' I think), type in the following and see if Void boots up.

grub> root (hdx,y)
grub> kernel /boot/grub/i386pc/core.img
grub> boot


If it does, then write a new entry for Mageia's menu.lst and use that.
Let us know. (I cannot write the syntax of grub-legacy anymore).

Good luck

ps: if Mageia (default boot) is grub 2. it's simpler.
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby aldQueiroz » Jul 20th, '16, 15:19

Thank you, gohlip!
You're right with all(most) these statements:
o Your Mageia 5 is in 500 GB and that is the 'default boot' when you start up the computer.
o That 'default boot' is from Mageia 5 in 500 GB OS and is using grub-legacy (you mentioned GRUB1.5, I think you mean stage 1.5)
o You have installed Void linux in 80 GB which will not boot from Mageia grub
o That Void is using grub 2 and is 'set' to that 80 GB drive.
o If bios is selected to boot from 80GB, Void boots okay (but you want Mageia's boot from 500GB to boot it)
o Not stated but assumed - both drives are msdos partitioned and boot is bios-legacy.

The only thing that I'm not sure is about my drives are 'msdos partitioned' (?); I've been using Linux for a while, familiar with partitioning process using 'ext' format. My motherboard is relative new, UEFI enabled, but I'm indeed using bios-legacy -- that's the way I found to install Mageia when I updated my desktop (should I change to UEFI? That's a question to another topic! ;) )

I tried GRUB 2 when I was (re)installing Mageia 5 in my desktop, after motherboard & CPU update, but I found it difficult to configure (too much time using GRUB-legacy, and too few time to study and learn about GRUB 2 details!) -- Should I tryt o update my 'default' system to GRUB 2 as well?...

Need a few things for you to check.
o Confirm that in Void, there is a core.img in /boot/grub/i386-pc/
(Need the path to be correct)

grub> root (hdx,y)
grub> kernel /boot/grub/i386pc/core.img
grub> boot

I'll check out these later (again, away from my Mageia desktop...).

Thank you again!
Regards!
aldQueiroz
 
Posts: 51
Joined: Oct 18th, '11, 18:44
Location: Brazill, Rio de Janeiro

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby gohlip » Jul 20th, '16, 17:09

The only thing that I'm not sure is about my drives are 'msdos partitioned

You can check with "parted -l" in any terminal and best be sure. It will show both drives.

UEFI enabled, but I'm indeed using bios-legacy -

If drives are msdos, it must be bios-legacy. UEFI cannot use msdos partitioning.

Oh....also, grub-legacy cannot handle uefi boots.
But if drives are GPT, it can be uefi (usually) OR bios-legacy.
The way to check this is at an OS terminal
Code: Select all
[ -d /sys/firmware/efi ] && echo UEFI || echo BIOS
at each OS
It is a very bad thing to mix uefi and bios-legacy boots (and for that matter, different disk partitions - msdos + gpt) for a system and will lead to failures.

Should I change to grub 2? And uefi?
That's entirely up to you. As in most things, people can be pretty "vociferous" whether it's systemd, religion or politics :D
I strenuously avoid discussing preferences, much less recommending any. But I'll state the facts.
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby aldQueiroz » Jul 20th, '16, 17:20

Well, I've been using grub-legacy just because grub2 seemed to be not 'ready', and I haven't found any particular advantage on using grub2. For UEFI, the same: if it doesn't bring me any advantage against bios-legacy; better not, I thought...
But, about systemd... To be honest I'm experiencing with Void Linux just because of it!! I understand that Mageia developers cannot support more than one init system by now, but I wish I could replace systemd for anything else less intrusive in my system without trouble. I really wish that, instead of consider change distro...
Last edited by aldQueiroz on Jul 22nd, '16, 14:53, edited 1 time in total.
aldQueiroz
 
Posts: 51
Joined: Oct 18th, '11, 18:44
Location: Brazill, Rio de Janeiro

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby aldQueiroz » Jul 21st, '16, 21:39

Hi,
I've got the kernel options I was using to boot the second HD (sdb) when still with Mageia in it (as available at MCC / Boot Configuration):
ro splash quiet noiswmd nokmsboot root=/dev/sdb1 ro splash quiet noiswmd root=/dev/sda1 resume=UUID=527376f4-13ff-4687-b9cb-0dc4852e31a6


In order to use Void Linux, and booting with grub-legacy from 1st HD (sda) I understand it should be enough to add a 'stanza' directly at /boot/grub/menu.lst , as follows:
#Configuração boot Void
title Void-Linux_LXQt
root (hd1,0)
chainloader +1

Is that correct? If so, the system will 'call' Grub2 at sdb?... I'm not confident about if this is the correct way...
aldQueiroz
 
Posts: 51
Joined: Oct 18th, '11, 18:44
Location: Brazill, Rio de Janeiro

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby gohlip » Jul 22nd, '16, 02:57

Chainloading is one way
Code: Select all
title Void Chainload
root (hdx,y)
chainload (hdx,y)+1


Another way is to 'multiboot'
Code: Select all
title Void Multiboot
root (hdx,y)
kernel /boot/grub/i386-pc/core.img
boot


Another way is to chainload to other drive
Code: Select all
title Sdb
rootnoverify (hd1)
chainloader +1


Yet another way is to boot directly kernels and initrd
Code: Select all
title Void Kernel
root (hdx,y)
kernel /boot/vmlinuz-xxxxx root=UUID=xxxxxxxxx (or root=/dev/sdxz or ....)  vga=xxx splash quiet ro
initrd /boot/initrd-xxxxx.img


It is best that you provide the following (at Mageia terminal)
o grub.cfg of Void entry (in Void partition)
o menu.lst of Mageia (one entry)
o # blkid
o # parted -l
o # fdisk -l
o pathe to Void core.img
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby aldQueiroz » Jul 25th, '16, 01:08

As you requested:
Attachments
dump-fdisk.txt
(4.39 KiB) Downloaded 336 times
dump-blkid.txt
(450 Bytes) Downloaded 358 times
aldQueiroz
 
Posts: 51
Joined: Oct 18th, '11, 18:44
Location: Brazill, Rio de Janeiro

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby aldQueiroz » Jul 25th, '16, 01:13

Nevertheless, I made a bold move and changed boot manager from grub-legacy to grub 2 (through install DVD -- to me, a simpler way...)
Well, I've got a more 'stylish' boot screen, and it realise a stanza to the 'unknown system' at sdb (it didn't recognize Void Linux).

Regards!
aldQueiroz
 
Posts: 51
Joined: Oct 18th, '11, 18:44
Location: Brazill, Rio de Janeiro

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby gohlip » Jul 25th, '16, 04:29

and it realise a stanza to the 'unknown system' at sdb (it didn't recognize Void Linux).
stanza? what's that?
Did you do "# update-grub2" or better "# grub2-mkconfig -o /boot/grub2/grub.cfg" ?
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby aldQueiroz » Jul 25th, '16, 16:41

I mean, an entry in boot menu (I heard somewhere that each entry or 'stance' of grub is nicknamed a "stanza"...)
Did you do "# update-grub2" or better "# grub2-mkconfig -o /boot/grub2/grub.cfg" ?

No... As as good 'newbie", I used the installer DVD! Not elegant, but, in my circunstances, a more direct way to change the boot manager than searching for which commands I should use in terminal...
aldQueiroz
 
Posts: 51
Joined: Oct 18th, '11, 18:44
Location: Brazill, Rio de Janeiro

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby Bequimao » Jul 26th, '16, 20:29

The stanza appears in the menu of grub. And does it boot Void Linux?

Best regards,
Bequimão
Bequimao
 
Posts: 111
Joined: Jun 3rd, '11, 21:51
Location: Minas Gerais, Brazil

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby aldQueiroz » Jul 26th, '16, 22:35

Yes, it works!
I might mark this topic as solved. However, changing grub-legacy to grub2 through installing DVD doesn't allow to know what exactly changed...
I'll try to get the grub2's menu (by the way, where?, and how to set it manually ?...) and post here too, as reference to others. And then, I'll mark this as SOLVED!
Regards!
aldQueiroz
 
Posts: 51
Joined: Oct 18th, '11, 18:44
Location: Brazill, Rio de Janeiro

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby Bequimao » Jul 27th, '16, 10:25

see
Code: Select all
# cat /boot/grub2/grub.cfg


and from Void Linux
Code: Select all
cat /etc/default/grub
Bequimao
 
Posts: 111
Joined: Jun 3rd, '11, 21:51
Location: Minas Gerais, Brazil

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby boombaby » Sep 4th, '16, 08:04

Hello, aldQueiroz...

[Sorry this is a late post. Haven't been here for a while. Might still help you or others.]


Despite you saying "dual-boot" it seems you have enough details (and skill) to make it "multi-boot".

Here is a link to my post in Mageia Forum from some months ago...

viewtopic.php?f=7&t=10805&p=62807#p62807

(see boombaby feb 26th)

That post describes my setup.

However, in this thread (ie the one you're reading now) Member "gohlip" described 4 ways to manage multiboot. [I didn't know "that" (ie that there were "4" ways to look at it). Brilliant!]

On my PC system I use chainloading ["gohlip's" 3rd method] on the first disk for DOS and WIN (only), and on the second disk (used "exclusively" for Linux) I directly boot kernels/initrd [which is "gohlip's" 4th method]. [Note that I mean boot from the same GRUB on disk-1.]

On the first disk I use Grub 0.97, and a dummy Grub-whatever on the second disk. (I call it "dummy" because I let every Linux install overwrite it - ie the MBR - with anything they like.) Grub 0.97 on disk-1 always boots everything.


The/My setup allows me to easily add/remove distros at will without problems.

HOWEVER, there are some provisos:-

1. The SWAP partition should always be kept near the start of disk-2. [On my setup I have only FreeDOS/Puppy before it.]

2. I give each partition a LABEL name to avoid UUID "confusion" (ie between bunches of stupid numbers), but some distros can still alter/botch-up things (so stay on your toes for that). Unfortunately, even after that, some distros will still only work with UUID in "fstab" (it seems). [Amazingly, at install, and despite pre-existing partition labels, one or two distros will still actually re-label things, or refuse to work otherwise. Then I don't use them at all.]

3. If you delete any partitions (to resize things, or to gather space, or any other reason) you'll change all UUIDs above the alteration - and that can "bork" your system (although it can all be recovered with a little difficulty). [So the trick is to lay out your partitioning once and for all at the start. Afterwards you are free to add or remove distros in "set" partitions as you like - then just modify the Grub "menu.lst" file on disk-1. It's sweet like that!]

4. Some distros you might want to try-out can "see" partitions wierdly at install (ie completely false readings). Once you come across such a distro - just walk away from it. (I never trust them after that.)

5. Partitioning is not all the "same". I have found 3 tools among my distros - drake-based (Mageia/PCLinuxOS); gparted (Debs-&-most others); rpm (gnewsense and ?old redhat?). And these might each see things a little differently. You need to make sure that when you partition it is done the same way each time - or else use only one tool (ie ever).

Just thought you might like to know.

Regards,
aka boombaby
boombaby
 
Posts: 40
Joined: Dec 15th, '15, 11:18

Re: Dual Boot=Mg5 (sda) and Void Linux (sdb!)

Postby gohlip » Sep 4th, '16, 09:53

Hi, boombaby, thanks for sharing. Yes, I too label all my partitions so that I can multiboot/configfile easily if done manually.
However if grub.cfg is 'embedded', I'll use uuid (partuuid if gpt) as this is the most reliable. That goes for fstab too.
And I avoid distro's that change uuid (usually swap); not that I cannot fix it later - but that shows arrogance on the part of the distros - thinking, like windows, they are/should be the only OS in the system.

Yes, what I wanted to say is that I have a 'dedicated' grub and a boot partition for it.
And it is cannot be changed by any OS even if any/all OS gets destroyed.
I do not need to 'update-grub' anywhere in any kernel change in any OS including this 'standalone grub' (sym-links helps).
I started to use this with grub-legacy and have moved to using this in grub 2 when grub 2 was introduced.
Much easier to do this in grub 2 and grub 2 is far more.... never mind, don't want to get into this (in Mageia forum :roll: ).
And I have not used grub-legacy for at least 5 years, maybe 7? My above post was a result of old memories rushing back, rare, but it happens. I still have a grub-legacy grub-mkrescue cd that I made myself - still works.
Oh, for my uefi set up, I have my own $esp too (not that it is necessary).
In bios-legacy/msdos set-up, all OS's grub is 'set' to own partition (not relevant in uefi).

Thought I'd share this with you.
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50


Return to Basic support

Who is online

Users browsing this forum: No registered users and 1 guest