nixos/modules/system/boot/loader/grub/grub.nix: fails to honor boot.kernelParams
Nobody has claimed this yet.
- Dominant language
- Nix
- Stars
- 26.2k
- Forks
- 20.1k
- PR merge metrics
- PR metrics pending
Description
Nixpkgs version
- Unstable (25.11)
Describe the bug
When using the GRUB bootloader, boot.kernelParams is ignored. This makes it very difficult to use a serial console.
Steps to reproduce
Set boot.kernelParams = [ "console=ttyS0" ] and boot.loader.grub.enable = true.
Expected behaviour
console=ttyS0 added to kernel command line.
Screenshots
No response
Relevant log output
Additional context
This makes it very hard to use serial consoles provided by recovery environments, such as serial-over-LAN.
System metadata
system: "x86_64-linux", multi-user?: yes, version: nix-env (Nix) 2.31.2, channels(root): "nixos, nixpkgs", nixpkgs: /nix/store/nwkl6qniwivgslnp5mg4mj1m0aagpm25-nixos/nixos
Notify maintainers
Not sure if there are any.
Note for maintainers: Please tag this issue in your pull request description. (i.e. Resolves #ISSUE.)
I assert that this issue is relevant for Nixpkgs
- I assert that this is a bug and not a support request.
- I assert that this is not a duplicate of an existing issue.
- I assert that I have read the NixOS Code of Conduct and agree to abide by it.
Is this issue important to you?
Add a 👍 reaction to issues you find important.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in nixos/modules/system/boot/loader/grub/grub.nix and inspect how boot.loader.grub.enable handles boot.kernelParams. Reproduce with boot.kernelParams = [ "console=ttyS0" ] and GRUB enabled, then verify that console=ttyS0 appears on the kernel command line.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- linux
- Domain
- operating-systems
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100