Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

fedora boot order

Posted on 2013-11-25
13
Medium Priority
?
760 Views
Last Modified: 2013-12-03
I installed fedora ( I think it's version 19 ) on two partitions of my laptop. I will use one to get emails and stuff, and the other for banking.
the problem is the install of fedora i want to be the default if not the default. /etc/default/grub looks like this.

GRUB_TIMEOUT=5
GRUB_DISTRIBUTOR="$(sed 's, release .*$,,g' /etc/system-release)"
GRUB_DEFAULT=saved
GRUB_DISABLE_SUBMENU=true
GRUB_TERMINAL_OUTPUT="console"
GRUB_CMDLINE_LINUX="rd.lvm.lv=fedora/swap rd.md=0 rd.dm=0 vconsole.keymap=us $([ -x /usr/sbin/rhcrashkernel-param ] && /usr/sbin/rhcrashkernel-param || :) rd.luks=0 vconsole.font=latarcyrheb-sun16 rd.lvm.lv=fedora/root rhgb quiet"
GRUB_DISABLE_RECOVERY="true"

I have been googleing but can't find how to change the boot order. Or I should say, I have found a lot of "fixes" that aren't working.
anyone have a good step by step that changes the boot order for fedora 19?
0
Comment
Question by:JeffBeall
  • 6
  • 6
13 Comments
 
LVL 14

Assisted Solution

by:jb1dev
jb1dev earned 1000 total points
ID: 39676558
You are saying you want to change the default highlighted selection?
If so, you should probably not be using
GRUB_DEFAULT=saved

http://members.iinet.net/~herman546/p20/GRUB2%20Configuration%20File%20Commands.html

Specify an index  e.g. 0 or 1 or 2, etc.

GRUB_DEFAULT=0
The number at the end of this line can be changed to make the highlight bar or selection bar in the GRUB Menu appear automatically on any GRUB Menu entry we like.
0 (zero) tells GRUB we want the first or top GRUB entry automatically selected unless we over ride that selection with our up or down arrow key during boot-up.
Any number greater than 0 (zero) will mean boot entries further down the GRUB Menu will be selected instead.

Also don't forget:

# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
0
 
LVL 62

Expert Comment

by:gheist
ID: 39676581
The problem is in the fact that fedora 19 started using grub2 and did not include the update-grub2
So you have to run
grub2-mkconfig > /boot/grub2/grub.cfg
0
 
LVL 1

Author Comment

by:JeffBeall
ID: 39677385
Ok, so at a terminal I did this
su
vi /etc/default/grub

changed

GRUB_DEFAULT=saved

to

GRUB_DEFAULT=2
( I actually want to 3rd line to be the default )

then ran

grub2-mkconfig > /boot/grub2/grub.cfg

but it's like it ignored the changes and the default is still the 1st line of
/etc/default/grub
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 62

Expert Comment

by:gheist
ID: 39677511
is it in 3rd line when you run grub2-mkconfig ?
0
 
LVL 1

Author Comment

by:JeffBeall
ID: 39677697
"is it in 3rd line when you run grub2-mkconfig ? "

sorry, I'm not sure what you mean. when i edit
/etc/default/grub
once I'm done I save the changes and exit. Then I run
grub2-mkconfig> /boot/grub2/grub.conf
0
 
LVL 62

Expert Comment

by:gheist
ID: 39678267
the destination file is grub.cfg not grub.conf (you know they save one byte)
while grub2-mkconfig > /boot/grub2/grub.cfg is running it displays couple of lines with all kernels you have installed. so number them from 0 and choose the right one you want to boot for the next try.
(to remove old kernels use yum upgrade as opposed to yum update)
0
 
LVL 1

Author Comment

by:JeffBeall
ID: 39679603
I don't know if I'm counting the lines wrong in grub.cfg, but no matter what number I put in
GRUB_DEFAULT=
after I run
grub2_mkconfig>/boot/grub2/grub.cfg
and reboot, the default doesn't change. This is what grub2_mkconfig looks like when it runs
# grub2-mkconfig>/boot/grub2/grub.cfg
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-3.11.9-200.fc19.x86_64
Found initrd image: /boot/initramfs-3.11.9-200.fc19.x86_64.img
Found linux image: /boot/vmlinuz-3.11.8-200.fc19.x86_64
Found initrd image: /boot/initramfs-3.11.8-200.fc19.x86_64.img
Found linux image: /boot/vmlinuz-3.9.5-301.fc19.x86_64
Found initrd image: /boot/initramfs-3.9.5-301.fc19.x86_64.img
Found linux image: /boot/vmlinuz-0-rescue-7725dfc225d14958a625ddaaaea5962b
Found initrd image: /boot/initramfs-0-rescue-7725dfc225d14958a625ddaaaea5962b.img
Found Fedora release 19 (Schrödinger’s Cat) on /dev/mapper/fedora00-root
done
any idea what number goes in
GRUB_DEFAULT?
or would it be
GRUB_DEFAULT= /dev/mapper/fedora00-root
0
 
LVL 62

Accepted Solution

by:
gheist earned 1000 total points
ID: 39679911
If you want to boot kernel 3.9,5 by default you must
Set GRUB_DEFAULT=2 in /etc/default/grub
Run grub2-mkcoonfig > /boot/grub2/grub.cfg
0
 
LVL 1

Author Comment

by:JeffBeall
ID: 39680892
oh, I'll try that. Up to this point I would put

GRUB_DEFAULT=2

without all the other stuff.
0
 
LVL 62

Expert Comment

by:gheist
ID: 39681545
I can confirm that it works on Ubuntu like you typed.
0
 
LVL 1

Author Comment

by:JeffBeall
ID: 39682787
"Set GRUB_DEFAULT=2 in /etc/default/grub"

I thought you meant literally to put

2 in /etc/default/grub

but I realized to put

GRUB_DEFAULT=2

in the file called grub at /etc/default

the thing is I already tried that and it didn't work. In fact I've tried several things at

GRUB_DEFAULT=

and it seems like it just ignores whatever I put there, even though I run

 grub2-mkcoonfig > /boot/grub2/grub.cfg

after each change, then I reboot
0
 
LVL 62

Expert Comment

by:gheist
ID: 39682995
Weird. It mus have some other place it reads real settings...
0
 
LVL 1

Author Closing Comment

by:JeffBeall
ID: 39694403
thank you
0

Featured Post

Get your Disaster Recovery as a Service basics

Disaster Recovery as a Service is one go-to solution that revolutionizes DR planning. Implementing DRaaS could be an efficient process, easily accessible to non-DR experts. Learn about monitoring, testing, executing failovers and failbacks to ensure a "healthy" DR environment.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my business, I use the LTS (Long Term Support) versions of Linux. My workstations do real work, and so I rarely have the patience to deal with silly problems caused by an upgraded kernel that had experimental software on it to begin with from a r…
The purpose of this article is to show how we can create Linux Mint virtual machine using Oracle Virtual Box. To install Linux Mint we have to download the ISO file from its website i.e. http://www.linuxmint.com. Once you open the link you will see …
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.
Suggested Courses
Course of the Month11 days, 10 hours left to enroll

916 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question