GRUB (or 'grub.cfg') is not registered as a GC root

  • Done
  • quality assurance status badge
Details
5 participants
  • Ludovic Courtès
  • Ricardo Wurmus
  • Xavier Montillet
  • Xavier Montillet
  • Jakob L. Kreuze
Owner
unassigned
Submitted by
Xavier Montillet
Severity
serious
X
X
Xavier Montillet wrote on 31 Jul 2019 00:03
Guix gc breaks grub
(address . bug-guix@gnu.org)
37594eea-2366-4135-bbd5-b6d582cb6b01@www.fastmail.com
*Symptoms*

After running guix gc, and rebooting, I got the following errors (which stay something like half a second on the screen):

error: no such device: /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2
error: file `/gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2' not found.
error: no suitable video mode found.
error: no video mode activated.

I then get to the grub menu where I can pick which version of Guix I want to boot on, but all of them lead to getting stuck on the following text (with nothing moving after that for at least several minutes):

error: no suitable video mode found.
Booting in blind mod

*Fix
*

Fortunately nckx was on IRC and saved me by telling me to press C to get the grub command line when I got to the grub menu and run setup_gfxterm.

Running guix system reconfigure config.scm removed the need for setup_gfxterm for subsequent boots.

*Cause*

guix gc thinks that grub (and a lot of other stuff that it shouldn't think is dead) is dead, as shown by the following commands (given by nckx):


$ grep unicode /boot/grub/grub.cfg
search --file --set /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2
if loadfont /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2; then

$ guix gc --list-dead | grep 0fijjh7qw8ppsks0ba3q9m873ljhj797
finding garbage collector roots...
determining live/dead paths...
/gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04

I was also able to reproduce the bug by running guix gc and rebooting again.
Attachment: file
R
R
Ricardo Wurmus wrote on 31 Jul 2019 11:21
(name . Xavier Montillet)(address . xavierm02@xavierm02.fr)(address . 36865@debbugs.gnu.org)
87a7cu5zlr.fsf@elephly.net
Hi Xavier,

Toggle quote (16 lines)
> guix gc thinks that grub (and a lot of other stuff that it shouldn't
> think is dead) is dead, as shown by the following commands (given by
> nckx):
>
>
> $ grep unicode /boot/grub/grub.cfg
> search --file --set /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2
> if loadfont /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2; then
>
> $ guix gc --list-dead | grep 0fijjh7qw8ppsks0ba3q9m873ljhj797
> finding garbage collector roots...
> determining live/dead paths...
> /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04
>
> I was also able to reproduce the bug by running guix gc and rebooting again.

Oh, that’s not good. Can you still reproduce this after running “guix
system reconfigure …”? It should create a new system generation,
register a GC root, and update GRUB.

It should not say that GRUB itself is dead and thus not free it up for
garbage collection.

Could you perhaps share something about how you installed the system (if
it’s anything out of the ordinary)?

--
Ricardo
X
X
Xavier Montillet wrote on 31 Jul 2019 23:05
(name . Ricardo Wurmus)(address . rekado@elephly.net)(address . 36865@debbugs.gnu.org)
8d1b9619-9606-48c0-967b-f4d4f2a7fda3@www.fastmail.com
Hi Rocardo,

I guix pull'ed and grub is no longer marked as dead. "guix gc --list-dead | grep 0fijjh7qw8ppsks0ba3q9m873ljhj797" now returns nothing, while "grep unicode /boot/grub/grub.cfg" till returns the same thing.

So I guess this means it's fixed?

I installed with the 1.0.1 installer I think, nothing out of the ordinary, except maybe everything being encrypted, including the /boot.

Xavier

On Wed, Jul 31, 2019, at 9:21 AM, Ricardo Wurmus wrote:
Toggle quote (33 lines)
>
> Hi Xavier,
>
> > guix gc thinks that grub (and a lot of other stuff that it shouldn't
> > think is dead) is dead, as shown by the following commands (given by
> > nckx):
> >
> >
> > $ grep unicode /boot/grub/grub.cfg
> > search --file --set /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2
> > if loadfont /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2; then
> >
> > $ guix gc --list-dead | grep 0fijjh7qw8ppsks0ba3q9m873ljhj797
> > finding garbage collector roots...
> > determining live/dead paths...
> > /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04
> >
> > I was also able to reproduce the bug by running guix gc and rebooting again.
>
> Oh, that’s not good. Can you still reproduce this after running “guix
> system reconfigure …”? It should create a new system generation,
> register a GC root, and update GRUB.
>
> It should not say that GRUB itself is dead and thus not free it up for
> garbage collection.
>
> Could you perhaps share something about how you installed the system (if
> it’s anything out of the ordinary)?
>
> --
> Ricardo
>
>
Attachment: file
X
X
Xavier Montillet wrote on 31 Jul 2019 23:25
(name . Ricardo Wurmus)(address . rekado@elephly.net)(address . 36865@debbugs.gnu.org)
e1009c86-f4b8-4aa8-a9d0-872f56c082a1@www.fastmail.com
I just tried running guix gc and restarting and can confirm that the symptoms disappeared.

On Wed, Jul 31, 2019, at 9:05 PM, Xavier Montillet wrote:
Toggle quote (45 lines)
> Hi Rocardo,
>
> I guix pull'ed and grub is no longer marked as dead. "guix gc --list-dead | grep 0fijjh7qw8ppsks0ba3q9m873ljhj797" now returns nothing, while "grep unicode /boot/grub/grub.cfg" till returns the same thing.
>
> So I guess this means it's fixed?
>
> I installed with the 1.0.1 installer I think, nothing out of the ordinary, except maybe everything being encrypted, including the /boot.
>
> Xavier
>
> On Wed, Jul 31, 2019, at 9:21 AM, Ricardo Wurmus wrote:
>>
>> Hi Xavier,
>>
>> > guix gc thinks that grub (and a lot of other stuff that it shouldn't
>> > think is dead) is dead, as shown by the following commands (given by
>> > nckx):
>> >
>> >
>> > $ grep unicode /boot/grub/grub.cfg
>> > search --file --set /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2
>> > if loadfont /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04/share/grub/unicode.pf2; then
>> >
>> > $ guix gc --list-dead | grep 0fijjh7qw8ppsks0ba3q9m873ljhj797
>> > finding garbage collector roots...
>> > determining live/dead paths...
>> > /gnu/store/0fijjh7qw8ppsks0ba3q9m873ljhj797-grub-2.04
>> >
>> > I was also able to reproduce the bug by running guix gc and rebooting again.
>>
>> Oh, that’s not good. Can you still reproduce this after running “guix
>> system reconfigure …”? It should create a new system generation,
>> register a GC root, and update GRUB.
>>
>> It should not say that GRUB itself is dead and thus not free it up for
>> garbage collection.
>>
>> Could you perhaps share something about how you installed the system (if
>> it’s anything out of the ordinary)?
>>
>> --
>> Ricardo
>>
>>
>
Attachment: file
L
L
Ludovic Courtès wrote on 23 Aug 2019 14:31
(name . Xavier Montillet)(address . xavierm02@xavierm02.fr)
87lfvk6p1w.fsf@gnu.org
Hi Xavier,

"Xavier Montillet" <xavierm02@xavierm02.fr> skribis:

Toggle quote (2 lines)
> I just tried running guix gc and restarting and can confirm that the symptoms disappeared.

So, is this bug fixed? If so, in what commit range was the fix
introduced? That sounds like a serious issue so I’d rather make sure we
understand what happened.

Jakob, does that ring a bell?

Thanks,
Ludo’.
L
L
Ludovic Courtès wrote on 23 Aug 2019 14:32
control message for bug #36865
(address . control@debbugs.gnu.org)
87k1b46p09.fsf@gnu.org
severity 36865 serious
quit
L
L
Ludovic Courtès wrote on 23 Aug 2019 14:33
(address . control@debbugs.gnu.org)
87imqo6oyz.fsf@gnu.org
retitle 36865 GRUB (or 'grub.cfg') is not registered as a GC root
quit
X
X
Xavier Montillet wrote on 24 Aug 2019 00:53
Re: bug#36865: Guix gc breaks grub
(name . Ludovic Courtès)(address . ludo@gnu.org)
3acfb6f9-86f7-4602-829a-6602a7469da3@www.fastmail.com
Hi Ludo,

All I can say for sure is that the bug was in the guix pull'ed version at some point in the week leading to July 31 (and most likely on July 30), and that the bug is no longer in the version of July 31 evening.

Xavier

On Fri, Aug 23, 2019, at 12:31 PM, Ludovic Courtès wrote:
Toggle quote (15 lines)
> Hi Xavier,
>
> "Xavier Montillet" <xavierm02@xavierm02.fr> skribis:
>
> > I just tried running guix gc and restarting and can confirm that the symptoms disappeared.
>
> So, is this bug fixed? If so, in what commit range was the fix
> introduced? That sounds like a serious issue so I’d rather make sure we
> understand what happened.
>
> Jakob, does that ring a bell?
>
> Thanks,
> Ludo’.
>
L
L
Ludovic Courtès wrote on 24 Aug 2019 16:04
(name . Xavier Montillet)(address . xavierm02@guix.xavierm02.fr)
87lfviwtfw.fsf@gnu.org
Hello,

"Xavier Montillet" <xavierm02@guix.xavierm02.fr> skribis:

Toggle quote (2 lines)
> All I can say for sure is that the bug was in the guix pull'ed version at some point in the week leading to July 31 (and most likely on July 30), and that the bug is no longer in the version of July 31 evening.

Could you run ‘guix pull -l 1m’ (for this specific ‘guix’ command) to
see exactly what the commits were for these two generations?

Thanks in advance,
Ludo’.
X
X
Xavier Montillet wrote on 24 Aug 2019 17:07
(name . Ludovic Courtès)(address . ludo@gnu.org)
053e6f04-f0ee-43d3-8ba8-af15e200b144@www.fastmail.com
Hi,

Jul 26 2019 23:55:23 d23a00b599be56694065bd274184b9289fb8b85c
Jul 29 2019 11:32:04 ab20b3ed9152c7c95d0d2c6b2d65e29983ab57ce
Jul 29 2019 23:52:32 18c4b0a27705773e423fb17310394204b7295d4a
Jul 30 2019 before 22:03 nckx saves me (last messages of http://logs.guix.gnu.org/guix/2019-07-30.log)
Jul 30 2019 22:03 I send the bug report (first message of http://logs.guix.gnu.org/guix/2019-07-31.log)
Jul 31 2019 9:21 Ricardo responds to my bug report telling me to guix reconfigure
Jul 31 2019 09:30:31 bab94ffa0e27e39c02d5ce3add5605b676b76bee
Jul 31 2019 21:05 I send the email saying that Grub is no longer marked as dead after guix pulling
Jul 31 2019 13:31:40 716908411b4d393ec82d5b7e40c9817e81c8fa95
Aug 01 2019 09:12:52 e7dfbae8a99995abc9f088452ca35371d38eb343

So I would say that the bug was in18c4b0a27705773e423fb17310394204b7295d4a and was fixed before (or in) bab94ffa0e27e39c02d5ce3add5605b676b76bee.

Xavier

On Sat, Aug 24, 2019, at 2:04 PM, Ludovic Courtès wrote:
Toggle quote (12 lines)
> Hello,
>
> "Xavier Montillet" <xavierm02@guix.xavierm02.fr> skribis:
>
> > All I can say for sure is that the bug was in the guix pull'ed version at some point in the week leading to July 31 (and most likely on July 30), and that the bug is no longer in the version of July 31 evening.
>
> Could you run ‘guix pull -l 1m’ (for this specific ‘guix’ command) to
> see exactly what the commits were for these two generations?
>
> Thanks in advance,
> Ludo’.
>
J
J
Jakob L. Kreuze wrote on 24 Aug 2019 19:42
(name . Ludovic Courtès)(address . ludo@gnu.org)
87k1b2795j.fsf@sdf.lonestar.org
Hi Ludovic,

Apologies for not participating in this thread until just now.

Ludovic Courtès <ludo@gnu.org> writes:

Toggle quote (2 lines)
> Jakob, does that ring a bell?

Yes, this was fixed by #36880.

Regards,
Jakob
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEa1VJLOiXAjQ2BGSm9Qb9Fp2P2VoFAl1hduoACgkQ9Qb9Fp2P
2VolBhAApc409LWf+0VPU/HmlUQU5pVlXlcUzHU24S9oIwBFA8nCh2xepnyqNGVO
Zlz2T4Z7SMOGTbb+DdqSCqepemSILa2BTk7MOWvkIxSDNoD1aREDOIjmo3W3azp5
APDGKDCWpE53Kgi7GovXU15q9S54LfGvPrHToGdw/j1qlVW6cul2Uo8H0Kiimr6X
J8fhn9UeMkqTHnTc1agCJ1C8mD9M85hgTDUKAHMFrc4HmcrhTlUPXDgnkO22At7S
ssZz3T1Q07pAp8jJ6Y3VFTg5nnTU5mVwB4ljLMi/Z18RDua4lMTVlfUjyZBjnG++
NHsd8JCqlaaid/bDNhjLUmSq4KTW/whdloebJT/INsVHV8u+InLLhQPwqelpu9Lp
VbNMEPTRG36Ey8xnxfsCkYHmmG35Et6VugEVm9RksczRAglupNz7UJemHzvrBDby
msJWZfjSIgW64+jc6p1khB1hEhKQmzZoy+yLNUmKSZRBI97iWftPEMDgIy1dqhlt
BXKrfugYFJhIU+LfgO3A3jQgtrAjdtVhecYispbhatM4TsZ4cp9wjfVpCgoXAK9S
Ane0trH74JkSA78uKYv1GIFYVBPiXp1hekrVez/Re0qy1VrM9Y1vZMg1Kgf9pfec
DYg2NXKVoX5R8CEqeYT17YItQHybdeFDA0nsuhiEAjXH2HnqvGg=
=scuN
-----END PGP SIGNATURE-----

L
L
Ludovic Courtès wrote on 26 Aug 2019 10:19
(name . Jakob L. Kreuze)(address . zerodaysfordays@sdf.lonestar.org)
87imqk2vbf.fsf@gnu.org
Hi Jakob,

zerodaysfordays@sdf.lonestar.org (Jakob L. Kreuze) skribis:

Toggle quote (6 lines)
> Ludovic Courtès <ludo@gnu.org> writes:
>
>> Jakob, does that ring a bell?
>
> Yes, this was fixed by #36880.

Looking more closely, it seems to be

Anyway, closing. Thanks for your feedback!

Ludo’.
Closed
?