!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/5125 Servers

Load older messages


SenderMessageTime
28 Jan 2023
@lily:lily.flowers@lily:lily.flowersYes19:34:59
@lily:lily.flowers@lily:lily.flowersSwap lv in luks19:35:14
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgswap file or device? And I'm assuming systemd initrd?19:35:14
@lily:lily.flowers@lily:lily.flowersDevice and yes19:35:25
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgah, LV, not file19:35:26
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgcool19:35:32
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgso then maybe a swap file thing...19:35:44
@lily:lily.flowers@lily:lily.flowersI'll also take a look at the issue later. I'm busy atm but I thought I would confirm that it does work for me19:38:22
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgthanks19:38:34
@elvishjerricco:matrix.org@elvishjerricco:matrix.org Hm, this is actually going to be kind of hard to write a nixos test for, because we probably can't realistically know the resume_offset= value at eval time 21:24:46
@lily:lily.flowers@lily:lily.flowers
In reply to @elvishjerricco:matrix.org
Hm, this is actually going to be kind of hard to write a nixos test for, because we probably can't realistically know the resume_offset= value at eval time
Could you make it so the initrd put the value in /sys/power/resume_offset before systemd does the resume handling? That way it's not on kernel cmdline and so not needed at eval time but you'd have to generate the initrd from within the VM then. Unless someone knows a clever trick to make it easier
22:19:36
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgIt'd have to be a little different than that22:20:47
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgbecause the file system containing the swap file isn't actually mounted22:20:59
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgso we can't ask btrfs where its offset is in initrd22:21:07
@elvishjerricco:matrix.org@elvishjerricco:matrix.org we'd have to save it somewhere that initrd can read it from 22:21:23
@lily:lily.flowers@lily:lily.flowersI did not mean auto-magicking the value from initrd. I mean in a VM figure out the offset and build a new initrd with the number baked in22:22:16
@lily:lily.flowers@lily:lily.flowers
In reply to @elvishjerricco:matrix.org
we'd have to save it somewhere that initrd can read it from
But doing this could work too
22:22:25
@elvishjerricco:matrix.org@elvishjerricco:matrix.org
In reply to @lily:lily.flowers
I did not mean auto-magicking the value from initrd. I mean in a VM figure out the offset and build a new initrd with the number baked in
Oh, well that would require IFD to read the output of the VM into a Nix expression
22:23:01
@lily:lily.flowers@lily:lily.flowers
In reply to @lily:lily.flowers
I did not mean auto-magicking the value from initrd. I mean in a VM figure out the offset and build a new initrd with the number baked in
(A multi-stage test I suppose? Like the installer tests but less extreme)
22:23:26
@lily:lily.flowers@lily:lily.flowers
In reply to @elvishjerricco:matrix.org
Oh, well that would require IFD to read the output of the VM into a Nix expression
Why?
22:23:31
@elvishjerricco:matrix.org@elvishjerricco:matrix.org builtins.readFile (runCommand "foo" {} "echo hi > $out") is technically IFD. Or, rather, the same basic internal mechanism 22:24:06
@lily:lily.flowers@lily:lily.flowersNix doesn't need it. But your idea of saving it on another disk is better22:24:14
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgoh wait22:24:23
@lily:lily.flowers@lily:lily.flowers
In reply to @elvishjerricco:matrix.org
builtins.readFile (runCommand "foo" {} "echo hi > $out") is technically IFD. Or, rather, the same basic internal mechanism
Nix doesn't need the number in what I was offering
22:24:28
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgoh, you mean like build a whole new initrd in the vm22:24:39
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgnot build it as a nix expression22:24:46
@lily:lily.flowers@lily:lily.flowersYes22:24:48
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgneat22:24:48
@elvishjerricco:matrix.org@elvishjerricco:matrix.orgI think saving it somewhere the initrd can read it would be easier though22:24:58
@lily:lily.flowers@lily:lily.flowersI'm sorry for being a tad unclear 😅22:25:00

Show newer messages


Back to Room ListRoom Version: 6