With Nixos 25.11, and until Nixos 26.05, it was possible to compile a custom x86_64 kernel on the Debian platform from RC source downloaded from kernel.org, and then deploy it to a variety of distributions including NIxos without boot failure.
Beginning with a custom compiled kernel update after upgrading to Nixos 26.05 the boot failed after the lightDM login. Switching to tty and attempting to login only repeated the login and password requests and did not progress to a shell.
The verbose boot with the default Nixos kernel indicates a reference to “graphical interface” before progressing to the login screen, but the custom kernel does not progress past the login manager reference.
Also absent in the verbose boot were the references to stage 1 and stage 2 of the boot process.
A previous attempt to inquire as to what changed in the boot process relative to the kernel between Nixos 25.11 and Nixos 26.05 did not yield any helpful specific information that would enable the process of continuing to compile a kernel once on the Debian platform that would function across a variety of different distributions including Niixos.
A merge of the Debian kernel flag .config file and the Nixos 26.05 kernel flags, and recompile, did not produce a boot to graphical interface/mate desktop when booting Nixos 26.05.
It appears that both development and release issues are involved, hence the post in this forum for specific information relative to boot/kernel changes made between 25.11 and 26.05.
Nixpkgs does not make any guarantees about custom kernels or package overrides in general. If your custom choice of flags is broken, though, I would question what flags you are in fact using and whether they are compatible with a coherent desktop.
If you need help, you’ll have to post specifics.
What specifics do you require? Attempting to post a diff between the booting custom-kernel and the default Nixos kernel failed due to .txt file format exclusion and the diff file exceeds the 32000 character limit.
If you’re diverging that much from the base kernel you’re probably on your own.
But you can post it on github or a pastebin or something and link to it.
uhhh that was possible? I mean I guess it was obviously “possible” in the sense that you could always just manually replace some binaries and stuff, but NixOS does not offer any interface for doing this. So without telling us how exactly you actually configured this, we have absolutely no idea how it is you managed to boot NixOS with a non-NixOS kernel, and therefore obviously no idea how it might be going wrong. At the very least, you need to share the boot-relevant parts of your NixOS config modules.
A complete .config is over 130K and therefore am attempting to narrow down what specific changes occurred to the kernel boot process between Nixos 25.11, that booted with the custom kernel, compiled on a Debian platform, and the kernel boot process for Nixos 26.05, compiled on the same platform, but would not reach the graphical interface booting 26.05. What specific kernel flags control the boot process and if there were changes in those flags between 25.11 and 26.05. I note that the verbose boot no longer indicates stage1 nor stage 2, so what changed with this difference, for example. Need a reply from someone who deals with the Nixos kernel configuration hence a post was initiated in the development and releases section of the forum. Thank you.
uCompile once, and deploy across a number of distros. Works fine with other distros and booted Nixos 25.11, but with 26.05 booting did not reach graphical interface. Thank you.
You’re talking about the fact that systemd stage 1 is enabled by default now, which uses different boot params and shows a different boot log on the console. It still indicates a separation of stage 1 and stage 2. See the manual section about the kernel params you can use to diagnose boot problems: NixOS Manual