!oNSIfazDqEcwhcOjSL:matrix.org

disko

354 Members
disko - declarative disk partitioning - https://github.com/nix-community/disko89 Servers

Load older messages


SenderMessageTime
12 Jul 2024
@nevrv:matrix.orgnrvSo, sgdisk commands succeed, but then there is no cryptsetup in the log. It is in the script though, but refers to hardcoded random partlabels(?), dunno how that works, are they static and calculated at build time?10:01:27
@nevrv:matrix.orgnrv * So, sgdisk commands succeed, but then there is no cryptsetup in the log. It is in the script though, but refers to hardcoded random partlabels(?), dunno how that works, are they static and calculated at build time? They seem to exist10:02:30
@nevrv:matrix.orgnrv /tmp/secret.key is also created10:03:08
@nevrv:matrix.orgnrvi did actually forget that before and the error was different and intelligible of the issue10:03:33
@nevrv:matrix.orgnrv..so it's failed to open keyfile10:16:55
@nevrv:matrix.orgnrvbut cat /tmp/secret.key works10:17:08
@nevrv:matrix.orgnrv (and of course it's not in the logs, disabled explicitly for the cat but not for the cryptsetup so hmm) 10:19:32
@nevrv:matrix.orgnrv * (and of course it's not in the logs, disabled with +x explicitly for the cat but not for the cryptsetup so hmm) 10:19:44
@nevrv:matrix.orgnrvalso, disko completely misses this error and proceeds with the zfs stuff10:20:44
@nevrv:matrix.orgnrv * ..so it's failed to open keyfile (the pipe substitution or whatever it's called in bash)10:22:28
@nevrv:matrix.orgnrv * ..so it's failed to open keyfile (the pipe substitution of cat or whatever it's called in bash) 10:22:40
@nevrv:matrix.orgnrv * ..so it's failed to open keyfile (the process substitution of cat) 10:23:34
@nevrv:matrix.orgnrv * ..so it's failed to open keyfile (the process substitution of cat /tmp/secret.key) 10:23:44
@nevrv:matrix.orgnrv * (and of course it's not in the logs, disabled with +x explicitly for the cat but not for the cryptsetup so hmm, maybe the big ( ) subshell captures it?) 10:24:56
@lassulus:lassul.uslassulushmm, weird, I don't see any code that ignores the cryptsetup error. like it should fail if cryptsetup fails. The partlabels are calculated inside the gpt type and are used onwards from there10:26:11
@nevrv:matrix.orgnrv * At first i think i miscalculated the sizes. sgdisk would say cannot make partition and refuse going further. That is ok.
But then this, and also partprobe broke and said to reboot, and also sgdisk were spitting random numbers instead of ones that i give to it
10:26:13
@lassulus:lassul.uslassulusbut you can also overwrite the labels there, if they are too long, they are changed to a hash10:33:30
@nevrv:matrix.orgnrvcould it be that sgdisk --clear doesn't work properly and there's still partitions on the disk when i run disko multiple times?10:38:05
@nevrv:matrix.orgnrveven though it runs --clear and partprobe and everything10:38:17
@nevrv:matrix.orgnrvbecause now i see sgdisk failing again (though i tweaked the sizes)10:38:56
@nevrv:matrix.orgnrv
In reply to @nevrv:matrix.org
could it be that sgdisk --clear doesn't work properly and there's still partitions on the disk when i run disko multiple times?
sure it could. blkdiscard fixes that.
10:42:08
@nevrv:matrix.orgnrvbug?10:42:31
@nevrv:matrix.orgnrv * bug on the disko part?10:42:43
@nevrv:matrix.orgnrv
In reply to @nevrv:matrix.org
could it be that sgdisk --clear doesn't work properly and there's still partitions on the disk when i run disko multiple times?
* sure it could. blkdiscard fixes that. success after blkdiscard, no changes to disko config
10:43:26
@lassulus:lassul.uslassuluswhat command are you running?10:43:51
@nevrv:matrix.orgnrv
In reply to @nevrv:matrix.org
sure it could. blkdiscard fixes that. success after blkdiscard, no changes to disko config
wait, abort
10:44:47
@nevrv:matrix.orgnrvi got excited on one success message which was not the right one10:45:12
@nevrv:matrix.orgnrv
In reply to @lassulus:lassul.us
what command are you running?
give me a sec
10:45:16
@nevrv:matrix.orgnrv
In reply to @lassulus:lassul.us
what command are you running?

this is dicko.nix https://0x0.st/XMUo.txt
this is it's output https://0x0.st/XMUT.txt built by nix run .#disko -- --dry-run --mode format --arg disks '[ "/dev/disk/by-id/nvme-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" ]' ./disko.nix

the command that i'm running is sudo --preserve-env=NIX_PATH nix run .#disko -- --mode format --arg disks '[ "/dev/disk/by-id/nvme-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX ]' ./disko.nix
disko rev is 786965e1b1ed3fd2018d78399984f461e2a44689

what i'm getting:

  • command log https://0x0.st/XMUQ.txt
  • the disk state after it is this:
Device                                                            Start     End Sectors Size Type
/dev/disk/by-id/nvme-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX-part1 4194304 4196351    2048   1M BIOS boot

...for some reason

11:37:03
@nevrv:matrix.orgnrv This is btw when it now decided to switch back to not liking my sgdisk. I don't know if it is sgdisk, linux, disko or i'm stupid and blind and there's wrong numbers again.
The cryptsetup issue had another log
11:39:21

Show newer messages


Back to Room ListRoom Version: 10