<julm>
damned, using a /nix/store over a ZFS dataset using normalization=formD breaks the libsass unpacking, which contains two directories whose names have the same normalization :(
<julm>
there is already an extraPostFetch=''rm -r $out/test/e2e/unicode-pwd'' to fix the build on HFS+, but on ZFS it fails before that, when moving from the tmpfs to the ZFS
<julm>
mv: inter-device move failed: '/build/unpack/libsass-3.6.3/test/e2e/unicode-pwd/S'$'\303\241''ss-U'$'\305\242''F8' to '/nix/store/bqfq4db6nwycmkdrql9igsbrayqsw3g2-source/test/e2e/unicode-pwd/S'$'\303\241''ss-U'$'\305\242''F8'; unable to remove target: Directory not empty
<gchristensen>
honestly don't know what to say or do :
<manveru>
ah, for some reason that also needs root
<clever>
manveru: it might be trying to auto-repair the db, and it needs write access to do so
prusnak has quit [Changing host]
prusnak has joined #nixos-dev
prusnak has joined #nixos-dev
<manveru>
well, i did a .backup now
<manveru>
backup also doesn't work, neither does recover
<manveru>
i think there must be some invalid value in the db, not a corruption
<manveru>
interestingly that error seems to come from the rust part of nix
<clever>
manveru: if not even sqlite3 can .dump, then its definitely corruption
<clever>
manveru: when things are that far gone, the simplest thing you can do is just blow away the entire /nix and re-run nixos-install to recreate it
<manveru>
i can dump a copy of the db
<manveru>
just that making a new db from that dump gives the same failure
<clever>
manveru: ah, can you pastebin the full dump?
<manveru>
it's like 300MB... so no
<clever>
yikes
<manveru>
i looked through the db, there are no empty paths
<manveru>
but ok, will just recreate from scratch if that's no issue :)
<manveru>
this only happened after upgrading to nixFlakes and trying a GC, given that the registration date is 2019-11-26
__Sander__ has joined #nixos-dev
<julm>
emily: unfortunately normalization is readonly, it can only be set when creating the pool. I was new to ZFS when creating that pool, and only followed the recommendation on https://nixos.wiki/wiki/NixOS_on_ZFS which is normalization=formD
<qyliss>
It's not really a recommendation
<qyliss>
It just says you can
<gchristensen>
guh, deleting that, it doesn't make sense to recommend things just because
<gchristensen>
s/recommend/mention/
<gchristensen>
julm: I was tempted by that one too
<emily>
julm: ah, I see. yeah that's a terrible recommendation
<emily>
could probably use someone going over and updating it (e.g. I guess zstd might be better than lz4 for new pools now?)
<gchristensen>
emily: really it shouldn't recommend any specific algo, just "on" which picks the best available
<emily>
on macos/windows it makes some sense to mangle filenames because the APIs are based around unicode, but linux is pretty firmly in the bag of "filenames are raw byte sequences"
<gchristensen>
emily: I've tried cleaning it up a few times, but kept getting bogged down infeeling like there was so much to do and not feeling good about where to start. ... so I just wrote this: https://grahamc.com/blog/nixos-on-zfs
<emily>
gchristensen: sure, as long as on picks good values (zstd has adjustable compression level I guess?)
<emily>
I just have some huge zpool/zfs commands commented out in my config for reference
<emily>
of course as luck would have it those are out of date now too
<gchristensen>
yea
<julm>
qyliss: yes, mention, but this appears with only a warning for the adventuruous for a whole list of options which are not adventuruous at all to me like compression or even required like acltype=posixacl, so I used it :|
<gchristensen>
(zstd isn't in 20.03, so not sure it sohuld be recommended)
<gchristensen>
julm: yeah, the others really are recommendations
<gchristensen>
julm: I'm sorry :(
<emily>
gchristensen: fwiw just replacing the article with a better one would be welcome, I think, as long as it contains all the info you need to set up the basic setups people want
<julm>
gchristensen: don't be, it's not a big deal :]
<emily>
I did that for https://nixos.wiki/wiki/Encrypted_DNS (the dnscrypt page was stuck on dnscrypt-proxy1, the DNS over TLS one recommended dnsmasq)
<emily>
of course i guess ideally this stuff would go in the manual
<emily>
once it's not docbook I guess :p
<qyliss>
Yeah, ZFS in the manual would be great
<gchristensen>
+1
<julm>
there is a departure from docbook on the way for the manual?
<emily>
that really has no reason to be in the grub module
<adisbladis>
I think not?
<adisbladis>
Is it even possible to have mirrored ESPs?
<adisbladis>
Oh right, I misunderstood how mirroredBoots work
<emily>
yes, that's what the option does :)
<emily>
you just make two /boots
<emily>
and ensure they're both in the UEFI variables
<emily>
if the boot of the first one fails, it falls back to the second
<emily>
(same as how USB drive boot falls back to disk or whatever)
<adisbladis>
emily: Then mirroredBoots should totally be moved out of grub :)
<emily>
gchristensen: dang, "this is not exactly how my set up mine due to my usage of tmpfs as root, but that's a topic for another post" is a real tease there
<emily>
adisbladis: it does look like the other bootloaders would need some adaptation of it, since it just installs grub twice rather than copying the files
<adisbladis>
emily: Me and etu use a very similar setup with tmpfs /
<emily>
(which um, confuses me, since I'm not sure how that would copy the kernels/initrds)
<qyliss>
I've been thinking about a tmpfs / on the new computer
<adisbladis>
The gist is: /nix on persistent storage (zfs), stuff that you want persistent are symlinked to persistent storage
<emily>
I admit that this penguin beanie is probably better than any /-on-tmpfs explanation could possibly be.
* adisbladis
<- proud owner of that beanie
teto has joined #nixos-dev
<etu>
emily, adisbladis: Mirrored boots is amazing though :)
<etu>
Super useful feature
<aanderse>
qyliss: i just built a new computer and did / on tmpfs... but then failed and gave up halfway through, so /etc is also mounted to persistent storage :\
<aanderse>
if i get some energy i might try and troubleshoot that at some point
obadz- has joined #nixos-dev
obadz has quit [Ping timeout: 264 seconds]
obadz- is now known as obadz
<emily>
is there a nice way to see what stuff in /etc isn't tracked by nixos?
<emily>
I guess looking for non-symlinks is a first approximation
<adisbladis>
emily: Approximation being the operative word
<adisbladis>
Some files are created by systemd units
<emily>
yeah. I guess you could diff /etc against /etc/static?