!PSmBFWNKoXmlQBzUQf:helsinki-systems.de

Stage 1 systemd

83 Members
systemd in NixOs's stage 1, replacing the current bash tooling https://github.com/NixOS/nixpkgs/projects/5127 Servers

Load older messages


SenderMessageTime
19 Mar 2022
@elvishjerricco:matrix.org@elvishjerricco:matrix.orglike nix-daemon.service11:17:13
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgthat's gonna be a problem...11:17:17
@elvishjerricco:matrix.org@elvishjerricco:matrix.org I was so excited "I'm just gonna call generateUnits, then either do my Exec* parsing or cherry-pick bobvanderlinden's change, and then it should boot!" 11:17:56
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgOf course it's not that simple...11:18:01
@bobvanderlinden_:matrix.orgbobvanderlinden is that because of it referring to config.systemd.packages? 11:18:10
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgOh if it's doing that all on its own then I'm going to have to parameterize this thing...11:18:40
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgYea... yea it's doing that11:18:59
@bobvanderlinden_:matrix.orgbobvanderlinden make cfg part of the arguments of generateUnits' I'd say 11:19:01
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgThis thing is getting way too many positional arguments. I'm gonna make it an attrset argument11:20:46
@bobvanderlinden_:matrix.orgbobvanderlindenhaha, exactly what I was thinking 😄 it's a messy function atm11:21:17
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgHell yea, that worked11:26:56
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgSweet, the regular old systemd options are generating a proper unit directory. Awesom12:46:57
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgSweet. Looks like I just have to fix the slightly wrong file system code for the qemu-vm module and then I'll have a VM that boots.13:52:03
@elvishjerricco:matrix.org@elvishjerricco:matrix.org bobvanderlinden: Btw the reason you had to force it to load ext4 was because /proc/sys/kernel/modprobe wasn't set to a real modprobe program. I solved this by putting kernel.modprobe = /bin/modprobe in /etc/sysctl.d/nixos.conf 13:52:53
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgIt's honestly remarkable how much simpler this branch is than all my previous attempts, and it's easily the most useful version of it anyway13:53:39
@arianvp:matrix.orgArianThat's a good sign14:13:06
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgCurrently it's 26M, which is way too big.14:25:57
@elvishjerricco:matrix.org@elvishjerricco:matrix.org But, I'm forcing it to include all of ${glibc}/lib because there's some dynamically loaded library that is required to start the recovery shell (not to boot though), and I'm not using systemdMinimal because that wouldn't include cryptsetup. 14:25:59
@elvishjerricco:matrix.org@elvishjerricco:matrix.org If I don't do the glibc thing and I use systemdMinimal, then it's just 13M, which is actually really good 14:26:26
@elvishjerricco:matrix.org@elvishjerricco:matrix.org Using systemdMinimal.override { withCryptsetup = true; } brings it to 15M, which isn't so bad 14:26:51
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgOh, hah, nevermind. If you actually try to run the thing with systemdMinimal then it just doesn't work at all14:29:25
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgAh no I'm wrong, it boots just fine. I just screwed it up14:48:21
@bobvanderlinden_:matrix.orgbobvanderlindenThat sounds quite promising. I was wondering whether booting with minimal would work when the root runs on non-minimal. Probably fine, but hadn't tried that yet.15:15:15
@bobvanderlinden_:matrix.orgbobvanderlinden

bobvanderlinden: Btw the reason you had to force it to load ext4 was because /proc/sys/kernel/modprobe wasn't set to a real modprobe program. I solved this by putting kernel.modprobe = /bin/modprobe in /etc/sysctl.d/nixos.conf

Ah haha that makes sense. I didn't know about this option and what trying to figure out why udevd wasn't calling modprobe. Good to hear that workaround is ironed out 👍👍

17:04:15
@armeen:matrix.orgarmeen joined the room.17:59:47
@rhys:memes.nzRhys joined the room.21:41:44
@elvishjerricco:matrix.org@elvishjerricco:matrix.org Going to have to start caching systemdMinimal.override { withCryptsetup = true; } though. 23:21:36
@flokli:matrix.orgflokli bobvanderlinden: I'm curious about all the systemd cryptsetup stuff in initrd. Asking for passwords from multiple consoles, and reusing passwords for multiple to-be-unlocked volumes should be much much nicer 23:38:19
@flokli:matrix.orgflokliAs well as all the yubikey/u2f/tpm stuff, which should now just work out of the box if we provide it in crypttab23:38:57
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgflokli: systemd in initramfs will make the password part at least much nicer, since it uses systemd-ask-password23:57:34

Show newer messages


Back to Room ListRoom Version: 6