| 11 Dec 2022 |
@janne.hess:helsinki-systems.de | Because that switches root rather than chrooting | 22:00:10 |
@mlyx:matrix.org | I test that change chroot to systemctl --no-block switch-root /sysroot $closure/prepare-root can still boot. I really don't understand the difference. Could you please elaborate more details? | 22:43:35 |
@mlyx:matrix.org |  Download Snipaste_2022-12-11.png | 22:43:35 |
| 12 Dec 2022 |
@elvishjerricco:matrix.org | mlyx: We do use systemctl switch-root in initrd-switch-root.service. Whereas initrd-nixos-activation.service is just meant to prepare the file system to be used as the nixos root | 03:29:26 |
@elvishjerricco:matrix.org | https://github.com/systemd/systemd/pull/25710 | 08:52:49 |
@elvishjerricco:matrix.org | I'm still not sure what the correct design for NixOS is; root= on the cmdline, or /etc/fstab embedded in initrd or added as a companion file or generated file. But just in case the answer is the cmdline, this PR is definitely necessary | 08:53:57 |
Arian | They're all equivalent no? | 09:14:34 |
Arian | I think it's the same generator | 09:14:47 |
@elvishjerricco:matrix.org | not exactly | 09:14:57 |
@elvishjerricco:matrix.org | systemd-fstab-generator is the one behind either, but it has different code paths for root= vs /etc/fstab vs /sysroot/etc/fstab | 09:15:27 |
Arian | The systemd way is gpt-auto-generator probably :p | 09:15:28 |
Arian | In reply to @elvishjerricco:matrix.org
systemd-fstab-generator is the one behind either, but it has different code paths for root= vs /etc/fstab vs /sysroot/etc/fstab Ah | 09:15:37 |
@elvishjerricco:matrix.org | and yea that gpt generator is a whole other one I haven't dug into yet | 09:15:50 |
@elvishjerricco:matrix.org | (and if you imagine the GPT as no different than a file on the ESP in terms of its ability to provide metadata, the GPT generator could be replaced by a generator that utilizes a file provided in the ESP and loaded via systemd-stub's "companion file" mechanism) | 09:18:23 |
@elvishjerricco:matrix.org | (but that's neither here nor there) | 09:19:01 |
| 14 Dec 2022 |
| Yinfeng joined the room. | 05:32:08 |
| 15 Dec 2022 |
@elvishjerricco:matrix.org | Ok, so I think I know what we ought to do. We should mount /sysroot in some normal fashion, like root= or by fixing systemd#3551. Then we should populate /sysroot/etc/fstab without nixos activation before initrd-parse-etc.service. From there everything will be normal. The one little problem is if the user has /etc on a different file system. Then we probably need to undo the prepopulation of /sysroot/etc/fstab somehow just to cleanup after ourselves. So it may be that the best thing is to have a mount unit that bind mounts our preferred /sysroot/etc/fstab, and give that mount unit Conflicts=initrd-fs.target or something to that effect (probably need better ordering than that). | 23:15:23 |
| 16 Dec 2022 |
@elvishjerricco:matrix.org | I think this is loosely what I want to do: https://github.com/NixOS/nixpkgs/compare/master...ElvishJerricco:systemd-stage-1-bind-fstab | 05:33:15 |
@mlyx:matrix.org | https://github.com/NixOS/nixpkgs/pull/169116
Hope this PR can be merged into master as soon as possible.
Networkd and openssh are extremely useful. However, it seems that openvpn is on the to-do list. Could the openvpn part be another PR? | 07:49:43 |
@elvishjerricco:matrix.org | I think it could. I've still got one or two tiny fixups to do first though, and I don't actually think the openvpn stuff will be very hard (I just haven't bothered trying yet) | 07:53:31 |
| 18 Dec 2022 |
@me:linj.tech |  Download IMG_20221218_224932.jpg | 15:41:44 |
@me:linj.tech | it hangs here if I use linux_latest (6.1) | 15:42:19 |
@me:linj.tech | * it hangs here if I use linux_latest (6.1) and works well using the lts kernel | 15:43:21 |
@me:linj.tech | any ideas about how to debug this? | 15:43:35 |
@elvishjerricco:matrix.org | That's... strange | 15:44:04 |
@elvishjerricco:matrix.org | Can you describe the hang? Is it possible the graphics driver is scraping up? | 15:44:38 |
@elvishjerricco:matrix.org | * Can you describe the hang? Is it possible the graphics driver is screwing up? | 15:44:59 |
@me:linj.tech | wait a minute | 15:45:35 |
@me:linj.tech | In reply to @elvishjerricco:matrix.org Can you describe the hang? Is it possible the graphics driver is screwing up? even though the screen does not change, I can type the password for luks and then the system can boots into gdm. I guess it is has something to do with my config for passing through a nvidia gpu. | 17:06:54 |
@me:linj.tech | In reply to @elvishjerricco:matrix.org Can you describe the hang? Is it possible the graphics driver is screwing up? * even though the screen does not change, I can type the password for luks and then the system can boot into gdm. I guess it is has something to do with my config for passing through a nvidia gpu. | 17:07:13 |