Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
grub-mkconfig takes forever to complete
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
Ivar
n00b
n00b


Joined: 21 May 2003
Posts: 25
Location: Mullsjö, Jönköping, Sweden

PostPosted: Mon Sep 11, 2017 6:28 am    Post subject: grub-mkconfig takes forever to complete Reply with quote

When doing a
Code:
grub-mkconfig -o /boot/grub/grub.cfg
it populate the log with things like:
Quote:
Sep 10 13:02:35 linux kernel: blk_update_request: I/O error, dev fd0, sector 0
Sep 10 13:02:35 linux kernel: floppy: error -5 while reading block 0
and takes forever to complete (even if the result is correct).

There is no way to tell 'grub-mkconfig' to ignore the floppy, but there is a way to tell 'grub-probe' used by 'grub-mkconfig' to not to use the 'fd0'.

By removing the 'fd0' line from /boot/grub/device.map
Quote:
(fd0) /dev/fd0
(hd0) /dev/hda
(hd1) /dev/hde
(hd2) /dev/hdf
it will not be used during the probing, and the process is quick and smooth.

I have not yet found how to regenerate that file (and then expel 'fd0'), but this does the magic until then.
_________________
/Ivar
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Guru
Guru


Joined: 13 Feb 2016
Posts: 385

PostPosted: Tue Sep 12, 2017 5:06 am    Post subject: Reply with quote

Just a guess, but have you tried or attempted /etc/grub.d the configuration directory for grub? One of the files in there is probably causing it to probe the entirety of the connected devices on your machine. Another good option, if you haven't done it before (assuming you are booting a maximum of just a few entries) is to write your own grub.cfg
Back to top
View user's profile Send private message
Ivar
n00b
n00b


Joined: 21 May 2003
Posts: 25
Location: Mullsjö, Jönköping, Sweden

PostPosted: Tue Sep 12, 2017 12:55 pm    Post subject: Reply with quote

In my case it looked like it toke a couple of turn on fd0 for each of the entries in /etc/grub.d/ and one for each of the different kernel to choose from. Total time for this was about one hour.

And i needed to run grub-mkconfig a couple of time to figure out how to set a better resolution on the console. Writing your own grub.cfg feels to complicated when you look what grub-mkconfig put in there. In the good old days of Lilo it was the first option, but not anymore.

Tips:vga= doesn't do the magic anymore, nowdays it's video= that do the thing!

But then again, since I don't have the same files my other gentoo computers the device.map can be a residue from a older grub:1 installation.

Either way, I never found a answer to why it took so long by searching, but found a couple of questions from people who had the same problem. So a note on Tips and Tricks might help other newbies who stumble on that in the future.
_________________
/Ivar
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Guru
Guru


Joined: 13 Feb 2016
Posts: 385

PostPosted: Tue Sep 12, 2017 9:07 pm    Post subject: Reply with quote

That seems like a preference or choice to be using the utility over your own instructions to grub. I think the problem is in fact with the utility itself, though for grub-mkconfig.

Can you try reinstalling it to see if that helps. What might also help is to compare your USE flags etc. to the ones of other systems. Mine is an EFI boot, which therefore this is settings for emerge -pv grub on my machine...

Calculating dependencies... done!
[ebuild R ] sys-boot/grub-2.02:2/2.02::gentoo USE="fonts nls sdl themes truetype -debug -device-mapper -doc -efiemu (-libzfs) -mount -multislot -static {-test}" GRUB_PLATFORMS="efi-64 -coreboot -efi-32 -emu -ieee1275 -loongson -multiboot -pc -qemu -qemu-mips -uboot -xen -xen-32" 0 KiB


Also, if it helps the topic is on another forum which requires reinstalling the packages for grub to test if that solves the issue
Here's the link to it. https://bbs.archlinux.org/viewtopic.php?id=185212&p=2
Back to top
View user's profile Send private message
Ivar
n00b
n00b


Joined: 21 May 2003
Posts: 25
Location: Mullsjö, Jönköping, Sweden

PostPosted: Tue Sep 12, 2017 9:46 pm    Post subject: Reply with quote

Will take a reinstallation under consideration, if I can't manage to get the darn machine to stabilize and behave it will end in a newer machine... (have troubles with softlocks and NMI-failures, and outputs fails to land in the logfile, increase the resolution at console was my solution to be able to see what failed, and that was not easy since grub failed to understand me).

This is what my grub is built with:

Quote:
Calculating dependencies... done!
[ebuild R ] sys-boot/grub-2.02:2/2.02::gentoo USE="device-mapper fonts nls themes -debug -doc -efiemu (-libzfs) -mount -multislot -sdl -static {-test} -truetype" GRUB_PLATFORMS="-coreboot -efi-32 -efi-64 -emu -ieee1275 -loongson -multiboot -pc -qemu -qemu-mips -uboot -xen (-xen-32)" 0 KiB


But as I said before, now grub-mkconfig does it's job, so that part I'm happy with :-)
_________________
/Ivar
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Guru
Guru


Joined: 13 Feb 2016
Posts: 385

PostPosted: Tue Sep 12, 2017 9:55 pm    Post subject: Reply with quote

Hey I'm glad you got that far, seems like if there was progress made it was with some slight changes to the output of grub-mkconfig, that is nice.
Back to top
View user's profile Send private message
pjp
Administrator
Administrator


Joined: 16 Apr 2002
Posts: 16713

PostPosted: Fri Sep 15, 2017 5:45 am    Post subject: Reply with quote

Seems more of a help topic than for DT&T. Installing Gentoo seems the most beneficial place.

Moved from Documentation, Tips & Tricks to Installing Gentoo.
_________________
Ladies and gentlemen, allow me to present, Man Not Caring. -- Perry Cox
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum