LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-04-2017, 08:47 AM   #61
bsth123
Member
 
Registered: Feb 2017
Distribution: Kubuntu, Debian, FreeBSD
Posts: 195

Original Poster
Rep: Reputation: Disabled

It didn't work. I did update-grub /dev/sda and it seemed to work but I still get the boot options that don't work. What if I copied the grub.cfg file to /dev/sda after editing the boot options? I know there has to be a way to do this.
 
Old 05-04-2017, 09:15 PM   #62
Shadow_7
Senior Member
 
Registered: Feb 2003
Distribution: debian
Posts: 4,137
Blog Entries: 1

Rep: Reputation: 874Reputation: 874Reputation: 874Reputation: 874Reputation: 874Reputation: 874Reputation: 874
If you put custom grub menu items into /etc/grub.d/40_custom it will get included when you run update-grub. Depending on your grub version or distro grub.cfg might default to /dev/ names that are not always reliable. Using LABELS or UUIDs tends to be more reliable IMO, since /dev/ names shift when you start adding more devices on more types of buses.

$ sudo blkid

file: /etc/fstab
Code:
/dev/sda1                                 / ext4 defaults,noatime 0 1
Code:
LABEL=11111111                            / ext4 defaults,noatime 0 1
Code:
UUID=11111111-1111-1111-1111-111111111111 / ext4 defaults,noatime 0 1
Just different ways to say the same thing.

file: /etc/grub.d/40_custom
Code:
#!/bin/sh
exec tail -n +3 $0
# previous two lines from debian's default / original version of the file.
        menuentry '40_custom, Linux 3.16.0-4-amd64' {
                insmod part_msdos
                insmod ext2
                linux /boot/vmlinuz-3.16.0-4-amd64 root=UUID=11111111-1111-1111-1111-111111111111
                initrd /boot/initrd.img-3.16.0-4-amd64
        }
Although I haven't tested that entry. It's basically cut and past and simplified from what update-grub creates. All the things you would enter from grubs command line mode to boot the kernel.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Kubuntu Won't Boot on USB Hard Drive Tyro65 Linux - Newbie 3 05-15-2011 08:31 AM
Kubuntu 10.10 Dual Boot W/ Win 7 Pro: No Option To Boot Kubuntu FrostBot Ubuntu 2 01-26-2011 08:17 PM
Dual Boot drive share with kubuntu/win2000 nardz Linux - Newbie 10 02-27-2007 08:18 PM
Drive Sharing on a dual boot (kubuntu/win2000) nardz Ubuntu 2 02-27-2007 09:50 AM
when fedora machine is connected to the internet via network windiws machines cannot purbeck Linux - Networking 1 01-24-2004 07:50 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:03 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration