You are not logged in.
Pages: 1
Hello,
currently I have the following parameters in my Grub configuration:
mem_sleep_default=deep intel_iommu=on iommu=pt loglevel=3 rd.systemd.show_status=auto rd.udev.log_priority=3 apparmor=1 lsm=lockdown,yama,apparmorIs there a way to split these parameters into multiple files? e.g. like
/etc/modprobe.d/i915.confThanks in advance
Offline
Well, you can always write a shell script that parse several /etc/grub.d/*.conf files and create a /etc/default/grub for you, before generating a final /boot/grub/grub.cfg.
Last edited by solskog (2020-09-21 22:08:24)
Offline
Hello,
currently I have the following parameters in my Grub configuration:
mem_sleep_default=deep intel_iommu=on iommu=pt loglevel=3 rd.systemd.show_status=auto rd.udev.log_priority=3 apparmor=1 lsm=lockdown,yama,apparmorIs there a way to split these parameters into multiple files? e.g. like
/etc/modprobe.d/i915.confThanks in advance
"why would you ever want to do that"
...
grub.cfg supports the "source" command: https://wiki.archlinux.org/index.php/Us … _reference
So you may source files in turn, and use them to append to a $cmdline variable. Eventually you'll pass the $cmdline variable as an argument to the "linux" command (specifies a kernel specification to boot into).
Managing AUR repos The Right Way -- aurpublish (now a standalone tool)
Offline
grub.cfg supports the "source" command:
Yes, I agree. The difference is the "source" occurs at runtime, a typo could result unbootable system. A predefined /etc/default/grub will be checked by grub-mkconfig.
Offline
Hardly unbootable. The grub boot menu is interactive and lets you run arbitrary grub commands to boot manually.
You're unlikely to find real syntax errors unless you use grub-mkconfig, which is a hodgepodge of hideous complexity. The link I gave includes an example 6-line grub.cfg which is easily vetted.
You should also just be using `grub-script-check /path/to/grub.cfg` to verify for correctness.
Managing AUR repos The Right Way -- aurpublish (now a standalone tool)
Offline
e.g. like
/etc/modprobe.d/i915.conf
I think what OP means (and here I am playing the guessing game myself) is that module settings can be put in /etc/modprobe.d, instead of the kernel command line. That is certainly correct.
Whether this applies to the kernel command options in post #1, I do not know. OP probably knows best because they put them there.
edit:
I agree that there's no pressing reason to do this; probably best to not fix what is not broken.
Last edited by ondoho (2020-09-22 07:08:03)
Offline
mem_sleep_default=deep intel_iommu=on iommu=pt loglevel=3 rd.systemd.show_status=auto rd.udev.log_priority=3 apparmor=1 lsm=lockdown,yama,apparmor
I think these are builtin kernel parameters that can't be placed in /etc/modprob.d/, which is for loadable kernel modules, unless recompile the kernel.
However sysctl could be used to change builtin kernel parameters att runtime inside /etc/sysctl.d/ and /usr/lib/sysctl.d/.
https://wiki.archlinux.org/index.php/Sysctl
Last edited by solskog (2020-09-22 09:16:04)
Offline
mem_sleep_default=deepRuntime control by /sys/power/state
intel_iommu=on iommu=pt apparmor=1 lsm=lockdown,yama,apparmorI believe these options can only be set / changed at boot
rd.systemd.show_status=auto rd.udev.log_priority=3Modifies behavior of systemd and udev during early boot.
loglevel=3sysctl variable kernel.printk
Offline
The OP's goal as stated is to take parameters in grub configuration and "split these parameters into multiple files", nothing has been said about moving them out of grub.
If the OP wishes for a different answer, the goal must be redefined.
Managing AUR repos The Right Way -- aurpublish (now a standalone tool)
Offline
Let's wait for the OP to come back and tell us if any of the posted answers are what they are looking for (or define the goal more clearly) before we do any more speculation.
Offline
...and OP never even logged in anymore after that initial post.
I'm seeing this often; is it a particular form of spamming or trolling? Or are so many people so short-lived?
Offline
Pages: 1