Created
March 3, 2014 19:13
-
-
Save leahcim/9332432 to your computer and use it in GitHub Desktop.
In Ubuntu, /etc/grub.d/30_os-prober overrides grub menu style and timeout defined by the user in /etc/default/grub. Here is a workaround to save the menu style and timeout values before os-prober changes them, and to restore them afterwards. The two files need to be placed under /etc/grub.d and made executable. Finally, "sudo update-grub" should…
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
set -e | |
# Save the $timeout and $timeout_style values set by /etc/grub.d/00_header | |
# before /etc/grub.d/30_os-prober messes them up. | |
cat << EOF | |
set timeout_bak=\${timeout} | |
set timeout_style_bak=\${timeout_style} | |
EOF |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/sh | |
set -e | |
# Reset $timeout and $timeout_style to their original values | |
# set by /etc/grub.d/00_header before /etc/grub.d/30_os-prober messed them up. | |
cat << EOF | |
set timeout=\${timeout_bak} | |
set timeout_style=\${timeout_style_bak} | |
EOF |
@pepa65 it's a known bug https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1273764
Why isn't it fixed yet though? Its been 8 years!
10 years now...
I have moved on from Grub...
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Thanks for this. What a PITA... For more context, I found this Gist via this StackOverflow answer.