grub problem

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

Re: grub problem

Postby wobo » May 9th, '12, 14:57

Nice to know.

I doubt that I will ever need it but thx for your efforts!
wobo
---
And a new day will dawn for those who stand long
And the forests will echo with laughter
(Stairway to Heaven, Led Zeppelin)
User avatar
wobo
 
Posts: 1649
Joined: Mar 22nd, '11, 17:13

Re: grub problem

Postby doktor5000 » May 9th, '12, 21:50

barjac wrote:I finally decided to dig into os-prober code myself - and found the problem. :D
I sent a patch upstream (Debian) which is now included in os-prober-1.53 (just released).


Awesome, keep up the good work Barry :)
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18061
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: grub problem

Postby MagikGimp » Jun 27th, '12, 17:39

Hi, can someone please tell me what's wrong with my grub.cfg? I've taken the advice to change the initrd line after a sudo update-grub but I still get a kernel panic for Mageia 2. The entry for Mageia after updating grub follows:

Code: Select all
menuentry "Linux (Mageia 2) (on /dev/sdb6)" --class gnu-linux --class gnu --class os {
   savedefault
   insmod part_msdos
   insmod ext2
   set root='(hd1,msdos6)'
   search --no-floppy --fs-uuid --set=root 48707fcd-effe-4c9a-83ba-139382d77ebc
   linux /boot/vmlinuz BOOT_IMAGE=Linux_(Mageia_2) root=UUID=48707fcd-effe-4c9a-83ba-139382d77ebc nokmsboot splash quiet resume=UUID=81768dbf-7e86-4826-a37e-a84c6f28acb0 vga=791
   initrd (hd0,5)/boot/initrd.img

Changing the last line as per the set root line does not help.
Thank you.
MagikGimp
 
Posts: 7
Joined: Jun 27th, '12, 17:35

Re: grub problem

Postby barjac » Jun 28th, '12, 00:01

Try changing the last line to :-
Code: Select all
initrd /boot/initrd.img
Add this icon to your KDE desktop - save as "About.desktop" http://pastebin.com/raw.php?i=X10X1Ype
User avatar
barjac
 
Posts: 193
Joined: Apr 4th, '11, 10:26
Location: Rossendale UK

Re: grub problem

Postby Creto » Jun 30th, '12, 23:42

Hi,

Well my dear, and have the kubuntu mageia in dual boot and there was a kernel update in kubuntu and there was a kernel panic and wonder Mageia is using version 1.53 os-prober

T+
Creto
 
Posts: 119
Joined: Mar 9th, '12, 19:11
Location: Pará - Brasil

Re: grub problem

Postby barjac » Jul 1st, '12, 12:37

Creto wrote:Hi,
Well my dear, and have the kubuntu mageia in dual boot and there was a kernel update in kubuntu and there was a kernel panic and wonder Mageia is using version 1.53 os-prober

Sorry - I don't understand.
Are you asking a question?
Mageia does not use os-prober at all, as it uses grub legacy.
You may find this useful:-
http://docteam.mageia.nl/installer/cont ... Bootloader
HTH
Last edited by barjac on Jul 1st, '12, 13:55, edited 1 time in total.
Add this icon to your KDE desktop - save as "About.desktop" http://pastebin.com/raw.php?i=X10X1Ype
User avatar
barjac
 
Posts: 193
Joined: Apr 4th, '11, 10:26
Location: Rossendale UK

Re: grub problem

Postby MagikGimp » Jul 1st, '12, 12:55

barjac wrote:Try changing the last line to :-
Code: Select all
initrd /boot/initrd.img

That worked, thank you. Now, what is the reason for this or rather how should I phrase my bug report on OS-Prober when I submit one?
Cheers, I'm still very much a n00bie at Linux.
MagikGimp
 
Posts: 7
Joined: Jun 27th, '12, 17:35

Re: grub problem

Postby barjac » Jul 1st, '12, 13:27

Now, what is the reason for this or rather how should I phrase my bug report on OS-Prober when I submit one?

This is known and already fixed bug in os-prober.
You don't say what your grub2 based distro is, however you need to check whether there is a package available for os-prober >= 1.53 available for your distro. You may need to enable a backport or testing repo.
If not, then file a bug on their tracking system requesting an update of os-prober to a version equal to or greater than 1.53 as the current version breaks dual booting with Mageia/PCLOS/Mandriva etc.
Best of luck ;)
Add this icon to your KDE desktop - save as "About.desktop" http://pastebin.com/raw.php?i=X10X1Ype
User avatar
barjac
 
Posts: 193
Joined: Apr 4th, '11, 10:26
Location: Rossendale UK

Re: grub problem

Postby doktor5000 » Jul 1st, '12, 15:46

For the general issue at hand, also documented: https://wiki.mageia.org/en/Mageia_2_Err ... stallation
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18061
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: grub problem

Postby Creto » Jul 1st, '12, 16:20

Ok, thanks for your comments I decided my doubts with them, were very kind.

T+
Creto
 
Posts: 119
Joined: Mar 9th, '12, 19:11
Location: Pará - Brasil

Re: grub problem

Postby MagikGimp » Jul 5th, '12, 11:42

barjac wrote:
Now, what is the reason for this or rather how should I phrase my bug report on OS-Prober when I submit one?

This is known and already fixed bug in os-prober.
You don't say what your grub2 based distro is, however you need to check whether there is a package available for os-prober >= 1.53 available for your distro. You may need to enable a backport or testing repo.
If not, then file a bug on their tracking system requesting an update of os-prober to a version equal to or greater than 1.53 as the current version breaks dual booting with Mageia/PCLOS/Mandriva etc.
Best of luck ;)

I'm running Ubuntu as my 'GRUB distro' and v1.51ubuntu3 is the version included in its main repository so does anyone happen to know off hand how to add os-prober's repository or if it even has one at all? I had a quick look myself and I know the command to add new ones (I think), I just couldn't find an URL to use although links to download the files themselves are very easy to find of course. I prefer to use repositories over manual installation for obvious reasons and I'd rather try this avenue before filing a bug as we all know how slow Canonical are with keeping the software of their main repository up to date.
MagikGimp
 
Posts: 7
Joined: Jun 27th, '12, 17:35

Re: grub problem

Postby barjac » Jul 5th, '12, 18:22

Add this icon to your KDE desktop - save as "About.desktop" http://pastebin.com/raw.php?i=X10X1Ype
User avatar
barjac
 
Posts: 193
Joined: Apr 4th, '11, 10:26
Location: Rossendale UK

Re: grub problem

Postby ohmysql » Nov 8th, '12, 17:11

I'm able to download the os-prober 1.54 package, but I'm not sure how to install it. I've compiled things before, and understand to use make and make install, but I'm stumped on this one.

Meanwhile, I'm trying to chainload using a grub2 custom entry (I'm using Mint as main OS) and haven't gotten that to work yet. Help would be appreciated.
ohmysql
 
Posts: 39
Joined: Nov 8th, '12, 16:59

Re: grub problem

Postby barjac » Nov 9th, '12, 01:53

I have no idea about Mint - you will need to ask on a Mint forum how to install their packages.

To boot Mageia from grub2, I would suggest labelling the root partiton to maybe "mageia2" (you can do this in mcc), then in your /etc/grub.d/40_custom use something like:-

Code: Select all
menuentry 'Mageia 2' {
search --no-floppy --label --set=root mageia2
chainloader +1
}


Now in mint run sudo grub-mkconfig (or maybe update-grub script if mint uses it) - Check mint documentation. Your grub.cfg will not be updated with what's in 40_custom until you run grub-mkconfig either directly or via a script.

You will also need to put a copy of your Mageia bootloader in the root partition boot sector - in Mageia do :-
Code: Select all
su
grub
grub> find /etc/mageia-release
(hdX, Y)
grub> root (hdX, Y)
grub> setup (hdX, Y)
grub> quit


The 'find' command will return your Mageia root partition, use the values of X and Y in the next commands.
You should then be able to boot from your grub2 menu in mint.
Add this icon to your KDE desktop - save as "About.desktop" http://pastebin.com/raw.php?i=X10X1Ype
User avatar
barjac
 
Posts: 193
Joined: Apr 4th, '11, 10:26
Location: Rossendale UK

Re: grub problem

Postby ohmysql » Nov 9th, '12, 05:51

Thanks for the post - I've now got the chainloader working, I actually got it earlier today. So that is great. I hope your post helps someone else (or me later) and your effort isn't lost on a fixed problem.

I'd still like to fix os-prober, though, if anyone has ideas on how to update it within grub (PS I'm not working on that, I swear :)).

OMS!
ohmysql
 
Posts: 39
Joined: Nov 8th, '12, 16:59

Re: grub problem

Postby filip » Nov 9th, '12, 10:45

barjac wrote:You will also need to put a copy of your Mageia bootloader in the root partition boot sector - in Mageia do :-
Code: Select all
su
grub
grub> find /etc/mageia-release
(hdX, Y)
grub> root (hdX, Y)
grub> setup (hdX, Y)
grub> quit


The 'find' command will return your Mageia root partition, use the values of X and Y in the next commands.
You should then be able to boot from your grub2 menu in mint.
Nice procedure. But find will give you wrong root Y and possibly X too if user has separate boot partition. I suggest adding a note about that. Unfortunately BIOS can see X differently than the kernel. In my case it sure does as I boot from SATA and I have also one IDE hd.
filip
 
Posts: 478
Joined: May 4th, '11, 22:10
Location: Kranj, Slovenia

Re: grub problem

Postby barjac » Nov 9th, '12, 12:53

filip wrote:Nice procedure. But find will give you wrong root Y and possibly X too if user has separate boot partition. I suggest adding a note about that. Unfortunately BIOS can see X differently than the kernel. In my case it sure does as I boot from SATA and I have also one IDE hd.

True, however I was working on the assumption that anyone who had a non-standard setup with a separate /boot would not be needing this information. I was trying to keep it easy.
This would be safer I agree, notes in [ ] :-
Code: Select all
su
grub
grub> find /etc/mageia-release
(hdX, Y)
grub> find /boot/grub/menu.lst
[check that (hdX,Y) is also returned here, if it's not then do the next line]
grub> find /grub/menu.lst
[if that returns just one output, then use it below]
grub> root (hdX, Y)
grub> setup (hdX, Y)
grub> quit

Regarding the BIOS vs kernel view of drive assignments - yes exactly, this is why I used grub to detect them. It is grub's view of the hardware that we are interested in (normally provided by BIOS), since it's grub that will be using it.
Add this icon to your KDE desktop - save as "About.desktop" http://pastebin.com/raw.php?i=X10X1Ype
User avatar
barjac
 
Posts: 193
Joined: Apr 4th, '11, 10:26
Location: Rossendale UK

Re: grub problem

Postby gohlip » Nov 9th, '12, 14:54

To find the right /boot partition, whether or not it is in a separate partition from /, the right find command should be
Code: Select all
grub> find /boot/grub/stage1


Use that output and it should be fine.
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: grub problem

Postby barjac » Nov 9th, '12, 17:19

That is fine unless you have two or ten grub legacy installations on the system - hence my use of /etc/mageia-release.
The best solution would be to use :-
Code: Select all
su
# touch /boot/grub/hey-there
grub
grub> find /boot/grub/hey-there
(hdX, Y)
grub> root (hdX, Y)
grub> setup (hdX, Y)
grub> quit
# rm /boot/grub/hey-there -f
exit

I should have thought of that sooner :D
Add this icon to your KDE desktop - save as "About.desktop" http://pastebin.com/raw.php?i=X10X1Ype
User avatar
barjac
 
Posts: 193
Joined: Apr 4th, '11, 10:26
Location: Rossendale UK

Re: grub problem

Postby gohlip » Nov 10th, '12, 05:02

Hey-there :)
That is fine unless you have two or ten grub legacy installations on the system -

2 installations? No big deal; 10? :) I'd rather have dedicated boot partition and labelled them well. Can't imagine doing 'update-grub' on 10 OS bootloaders on a single OS kernel change. And there's no need to chainload either as well. And it better be grub2.

But to each his own, as they say.
Cheers, take care.

ps: to do "# touch /boot/grub/hey-there", you need to be in that OS, won't you?
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: grub problem

Postby barjac » Nov 10th, '12, 12:34

I agree - I use a dedicated grub2 partition and multiboot or chainload into - a mix of legacy and grub2 systems, using labels. I did propose a patch for grub2 a few years ago to optionally have grub-mkconfig produce grub.cfg for linux using labels, but phcoder threw it out so I eventually I gave up.

Anyhow this is going beyond the scope of the original question.
Cheers.
(I think we spoke some years back in grub ML :)

re: ps. Yes true, in fact the whole procedure assumes that the Mageia system is running, as it requires grub legacy to be installed, but I have posted many times in the past on how to manually boot into a grub OS so not a big deal ;)
Add this icon to your KDE desktop - save as "About.desktop" http://pastebin.com/raw.php?i=X10X1Ype
User avatar
barjac
 
Posts: 193
Joined: Apr 4th, '11, 10:26
Location: Rossendale UK

Re: grub problem

Postby gohlip » Nov 10th, '12, 15:37

Aha! You're Barry Jackson! Good to hear from you again. Hope you've got those direct booting iso's cleared up. Some distros really make it hard to boot iso's - (Mageia too? - never tried booting its iso though) - Using Mageia for old memories' sake - (Mandrake made me fell for linux -and trying hard not to touch command line instructions in it - to make that nostalgia more genuine, so maybe I should install LILO in it, heh heh).

Good cheers.

ps: to use labels....(in grub2)
Code: Select all
search --no-floppy --label --set=root xxx

but I guess you already knew that, ahem. :)
Why do we live? To prove not everything in nature has a purpose.
gohlip
 
Posts: 573
Joined: Jul 9th, '12, 10:50

Re: grub problem

Postby ohmysql » Nov 11th, '14, 01:59

Can either of you tell me how to update os-prober within GRUB on mint?

I've downloaded the latest version, but when I go to that folder, I do make and make install and nothing happens. It says "make: *** No rule to make target `install'. Stop."

Yet according to Mageia this is the preferred solution. So how is it done?

Also, any updates to the instructions here for Mageia 4?

Also also, I can't access mageia (again), so I'm not sure how to complete the steps you mentioned that needed to be done in mage.

Thanks!

OH MY SQL!!!
ohmysql
 
Posts: 39
Joined: Nov 8th, '12, 16:59

Re: grub problem

Postby doktor5000 » Nov 11th, '14, 18:25

ohmysql wrote:I've downloaded the latest version, but when I go to that folder, I do make and make install and nothing happens. It says "make: *** No rule to make target `install'. Stop."

Yet according to Mageia this is the preferred solution. So how is it done?

Where does it say that "make install" is the preferred solution to update or run os-prober?
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18061
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: grub problem

Postby ohmysql » Nov 11th, '14, 20:51

Oh, it doesn't say that anywhere. That is just what I used to compile usb_modeswitch when I needed to manually update that a few years ago. But I'm all ears, how can I compile the newest os-prober? I've been googling with no luck.
ohmysql
 
Posts: 39
Joined: Nov 8th, '12, 16:59

PreviousNext

Return to Basic support

Who is online

Users browsing this forum: No registered users and 1 guest