You are not logged in.

#1 2019-07-23 19:30:08

greatest_username
Member
Registered: 2018-12-27
Posts: 35

Is there a drop-in configuration directory for /etc/default/grub?

Hi,

I'm using GRUB and I need to add a boot parameter without editing /etc/default/grub directly. Is there any form of drop-in configuration directory for /etc/default/grub?

Debian has /etc/default/grub.d/ but that doesn't work on Arch so I don't know what else I could do.

I would prefer to be able to put a file somewhere that has something along the lines of:

GRUB_CMDLINE_LINUX="$GRUB_CMDLINE_LINUX boot_parameter=1"

without needing to edit the main config file. Similar to Debian.

Thanks in advance.

Offline

#2 2019-07-23 20:02:42

loqs
Member
Registered: 2014-03-06
Posts: 17,368

Re: Is there a drop-in configuration directory for /etc/default/grub?

Offline

#3 2019-07-23 21:24:23

greatest_username
Member
Registered: 2018-12-27
Posts: 35

Re: Is there a drop-in configuration directory for /etc/default/grub?

Thanks!

Would adding

. /etc/default/grub.d/*

at the end of /etc/default/grub work?

I could probably make this one edit and put the rest in /etc/default/grub.d/.

Offline

#4 2019-07-23 21:40:43

loqs
Member
Registered: 2014-03-06
Posts: 17,368

Re: Is there a drop-in configuration directory for /etc/default/grub?

You could test it?
Alternately the patch debian uses to add the behavior is https://sources.debian.org/src/grub2/2. … b-d.patch/

Offline

#5 2019-07-23 22:02:07

greatest_username
Member
Registered: 2018-12-27
Posts: 35

Re: Is there a drop-in configuration directory for /etc/default/grub?

I tested it and it works fine. Thanks.

Offline

Board footer

Powered by FluxBB