!PSmBFWNKoXmlQBzUQf:helsinki-systems.de

Stage 1 systemd

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

You have reached the beginning of time (for this room).


SenderMessageTime
27 Nov 2022
@me:linj.tech@me:linj.tech I think what the manual says is that cryptsetup-pre.target should be stopped when the system is shutdown 23:29:44
@me:linj.tech@me:linj.techbut now, it is stopped after stage 223:29:54
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgThat's not quite accurate23:30:22
@elvishjerricco:matrix.org@elvishjerricco:matrix.org Stage 1 has two big systemd transactions. First is initrd.target, and after that there's a service called initrd-cleanup.service that does systemctl isolate initrd-switch-root.target, which is the second transaction. This causes everything else to be stopped 23:31:49
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgSo that second transaction is in some ways very similar to system shutdown23:32:08
@elvishjerricco:matrix.org@elvishjerricco:matrix.org Any services in initrd that aren't supposed to be stopped by this (e.g. plymouth) need to either be wanted by initrd-switch-root.target, or have IgnoreOnIsolate=true 23:33:37
@arianvp:matrix.org@arianvp:matrix.org
In reply to @me:linj.tech
my keyfile has a pre-defined key in it
Then don't use /dev/urandom
23:34:18
@arianvp:matrix.org@arianvp:matrix.orgBut the keyfile :)23:35:03
@me:linj.tech@me:linj.techinteresting, will try that later23:35:07
@elvishjerricco:matrix.org@elvishjerricco:matrix.org
In reply to @me:linj.tech
emm, what I want is somewhat weird: generate a keyfile on the fly for luks without storing that keyfile in initrd
I am curious what exactly you mean by this. If it's not randomly generated, then where is this key file you're actually trying to use?
23:36:07
@me:linj.tech@me:linj.tech
In reply to @elvishjerricco:matrix.org
I am curious what exactly you mean by this. If it's not randomly generated, then where is this key file you're actually trying to use?
mkdir -p ${luksKeyFileDir}
mount -t ramfs none ${luksKeyFileDir}
echo -n password > ${luksKeyFile}
chown 0:0 ${luksKeyFile}
chmod 0400 ${luksKeyFile}
23:37:14

Show newer messages


Back to Room ListRoom Version: 6