Grub2-editenv: error: environment block too small

I issued a sudo dnf update --refresh and among I very long output I spotted this error.

  Running scriptlet: libvirt-daemon-5.6.0-5.fc31.x86_64              1391/1391 
  Running scriptlet: libwbclient-2:4.11.6-0.fc31.x86_64              1391/1391 
  Running scriptlet: kernel-core-5.5.7-200.fc31.x86_64               1391/1391 
grub2-editenv: error: environment block too small.

  Running scriptlet: grub2-tools-1:2.02-105.fc31.x86_64              1391/1391 
  Running scriptlet: libvirt-daemon-config-network-5.6.0-5.fc31.x8   1391/1391 
  Running scriptlet: authselect-libs-1.1-4.fc31.x86_64               1391/1391 
  Running scriptlet: abrt-dbus-2.14.0-1.fc31.x86_64                  1391/1391 

Is there anything I need to urgently do before next reboot?
Thank you for a prompt reply

3 Likes

This is reported in RedHat Bugzilla, for Fedora and REDHAT against KERNEL:

https://bugzilla.redhat.com/show_bug.cgi?id=1625124
https://bugzilla.redhat.com/show_bug.cgi?id=1683128

Conclusion

sudo grub2-editenv create

Then for EFI

sudo grub2-mkconfig -o /boot/efi/EFI/fedora/grub.cfg

or for BIOS

sudo grub2-mkconfig -o /boot/grub2/grub.cfg

And then attempt again to install your kernel or your update.

Regards.,

4 Likes

My output
[giuliohome@localhost ~]$ sudo grub2-editenv create
[giuliohome@localhost ~]$ sudo grub2-mkconfig -o /boot/grub2/grub.cfg
Generating grub configuration file …
Found Windows Recovery Environment on /dev/sda1
Found Windows 7 on /dev/sda2
done
Now again sudo dnf update --refresh ? I proceed

Fedora 31 openh264 (From Cisco) - x86_64       406  B/s | 543  B     00:01    
Fedora Modular 31 - x86_64                      46 kB/s |  24 kB     00:00    
Fedora Modular 31 - x86_64 - Updates            28 kB/s |  21 kB     00:00    
Fedora 31 - x86_64 - Updates                    68 kB/s |  23 kB     00:00    
Fedora 31 - x86_64                              16 kB/s |  24 kB     00:01    
RPM Fusion for Fedora 31 - Free - Updates       24 kB/s | 9.1 kB     00:00    
RPM Fusion for Fedora 31 - Free                 29 kB/s | 9.9 kB     00:00    
Dependencies resolved.
Nothing to do.
Complete!

(this is not important but I guess I have to redo the changes suggested here in my closed question about setting the default boot to windows, maybe related)

1 Like

Now I’m going to reboot and mark this as solved if no issues arise… hope so :innocent: :wink:

Edit
Rebooted, all fine but I have to do again this activity.
I’ll mark as closed after that in a few minutes…

Sorry, I don’t understand what to do now…
this is what I see

[giuliohome@localhost ~]$ sudo cat /boot/grub2/grubenv
[sudo] password for giuliohome: 
# GRUB Environment Block
kernelopts=root=UUID=169f454d-3ccf-4ed3-a633-9452941d6b44 ro resume=UUID=1222fd0f-2c38-4634-b9e8-df5f70a5617d rhgb quiet 
boot_success=1
boot_indeterminate=0
#########################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################################

Looks strange to me…

Edit
I try with the following
sudo grub2-set-default 'Windows 7 (on /dev/sda2)'

  I'm sorry, didn't knew about this bug.  At least it's a bug :D

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.