Forum › Forums › New users › New Users and General Questions › [Solved] Change default grub option
- This topic has 2 replies, 2 voices, and was last updated Dec 21-9:08 pm by Askic.
-
AuthorPosts
-
December 21, 2020 at 4:44 pm #47894Member
Askic
Hello guys,
I have installed antix 19.3 in a dual boot with Windows. Recently I had to change default timeout option and you guys told me I should use Control Centre -> Edit Config File and to change GRUB_TIMEOUT value.
Than worked like a charm. However I’d like now to change default option for booting OS. antix is on the first (default) place, and Windows is on the second, last and fourth place.
I have looked again in the header file but there are variable and not absolute names.if [ "x${GRUB_DEFAULT}" = "x" ] ; then GRUB_DEFAULT=0 ; fi if [ "x${GRUB_DEFAULT}" = "xsaved" ] ; then GRUB_DEFAULT='${saved_entry}' ; fi if [ "x${GRUB_TIMEOUT}" = "x" ] ; then GRUB_TIMEOUT=5 ; fi if [ "x${GRUB_GFXMODE}" = "x" ] ; then GRUB_GFXMODE=auto ; fi if [ "x${GRUB_DEFAULT_BUTTON}" = "x" ] ; then GRUB_DEFAULT_BUTTON="$GRUB_DEFAULT" ; fi if [ "x${GRUB_DEFAULT_BUTTON}" = "xsaved" ] ; then GRUB_DEFAULT_BUTTON='${saved_entry}' ; fi if [ "x${GRUB_TIMEOUT_BUTTON}" = "x" ] ; then GRUB_TIMEOUT_BUTTON="$GRUB_TIMEOUT" ; fiSo, the default option is saved entry, but I don’t know where this entry was saved. How to change this option?
I guess it is in the /etc/default/grub but I don’t dare to edit this file until read something from you.
Thank you!- This topic was modified 2 years, 4 months ago by Askic.
- This topic was modified 2 years, 4 months ago by Askic.
- This topic was modified 2 years, 4 months ago by Askic.
December 21, 2020 at 8:29 pm #47907Moderator
caprea
::Yes, it’s in /etc/default/grub
It’s the number in the line
GRUB_DEFAULT=0The zero stands for the first entry.
If the second entry shall be the first, a one must be entered there.
GRUB_DEFAULT=1and so on.
Don’t miss sudo update grub afterwards.December 21, 2020 at 9:08 pm #47910MemberAskic
::Thank you caprea, that solved the problem. I thought there is some kind of a GUI tool for this, but the suggested solution worked as intended. Since 0 is te 1st element, I had to change 0 with 3 in order to boot 4th option as a default one.
Thank you very much! -
AuthorPosts
- You must be logged in to reply to this topic.