From: Grant Edwards <grant.b.edwards@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: [gentoo-user] Re: Exact setting in grub to default to a kernel by name?
Date: Mon, 14 Jun 2021 01:00:38 -0000 (UTC) [thread overview]
Message-ID: <sa69nm$sip$1@ciao.gmane.io> (raw)
In-Reply-To: YMaNbYRWf5+BlYOV@waltdnes.org
On 2021-06-13, Walter Dnes <waltdnes@waltdnes.org> wrote:
> On Sun, Jun 13, 2021 at 05:38:53PM -0000, Grant Edwards wrote
>> On 2021-06-13, Walter Dnes <waltdnes@waltdnes.org> wrote:
>>
>> > I'd be tempted to do a manual gub.cfg if I had documentation.
>>
>> I gave up on the grub2 auto-magical config system many years ago. My
>> grub.cfg is typically 10-20 lines long. The documentation is at
>>
>> https://www.gnu.org/software/grub/manual/grub/grub.html
>>
>> For manual confiuration: see section 6:
>>
>> https://www.gnu.org/software/grub/manual/grub/html_node/Configuration.html#Configuration
>
> When experimenting with this, I'll backup grub.cfg. If things go
> awry, boot with the USB key I used for the install, and copy back the
> old known working grub.cfg. I've done a first crack at this. I assume
> that nothing in /etc/default/grub will have any effect. Questions...
>
> 1) Is "insmod extfs3" necessary? I've built extfs3 into the kernels.
I've never used it it, and my boot partitions are always ext3/4
> 2) I assume that the the first "menuentry" will be the default boot?
Unless you set the `default` variable to something other than 0
> 3) Is the default timeout still 5 seconds?
Dunny, I always set 'timeout=10'
> 3) I assume that 640x480 is supported on just about every monitor
> out there. I want as large text as possible. My eyes are
> getting old... just like me. Any obvious errors in the following
> grub.cfg?
>
>=====================================================================
> menuentry 'Linux Experimental' --class gnu-linux {
> set gfxpayload=640x480
> insmod ext3fs
> set root='hd0,gpt1'
> linux /vmlinuz-experimental root=/dev/sda2 ro noexec=on net.ifnames=0 intel_pstate=disable ipv6.disable=1
> }
I don't know if you really need the gfxpayload or the insmod lines, I don't
recall ever needing those to boot kernels from ext3/4 partitions.
All my grub.cfg files looks like this:
========================================================================
timeout=10
root=hd0,1
default=0
menuentry 'vmlinuz-5.10.27-gentoo' {
linux /boot/vmlinuz-5.10.27-gentoo root=/dev/sda1
}
menuentry 'vmlinuz-5.4.97-gentoo' {
linux /boot/vmlinuz-5.4.97-gentoo root=/dev/sda1
}
========================================================================
> Something that occured to me. Can I move the duplicated lines to the
> top of the file and take them out of the menuentries? E.g.
Yes.
next prev parent reply other threads:[~2021-06-14 1:00 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-06-13 4:07 [gentoo-user] Exact setting in grub to default to a kernel by name? Walter Dnes
2021-06-13 4:46 ` Hund
2021-06-13 13:33 ` Walter Dnes
2021-06-13 17:38 ` [gentoo-user] " Grant Edwards
2021-06-13 22:57 ` Walter Dnes
2021-06-13 23:20 ` Neil Bothwick
2021-06-14 2:34 ` Walter Dnes
2021-06-14 11:47 ` Neil Bothwick
2021-06-14 1:00 ` Grant Edwards [this message]
2021-06-14 6:44 ` Walter Dnes
2021-06-14 8:38 ` Grant Edwards
2021-06-14 20:25 ` Walter Dnes
2021-06-15 13:56 ` Neil Bothwick
2021-06-16 0:51 ` [gentoo-user] [SOLVED} " Walter Dnes
2021-06-13 18:05 ` [gentoo-user] " Neil Bothwick
2021-06-13 18:45 ` Michael
2021-06-13 20:09 ` Philip Webb
2021-06-13 20:58 ` Walter Dnes
2021-06-14 8:25 ` Peter Humphrey
2021-06-13 8:21 ` Neil Bothwick
2021-06-13 8:26 ` Neil Bothwick
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='sa69nm$sip$1@ciao.gmane.io' \
--to=grant.b.edwards@gmail.com \
--cc=gentoo-user@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox