Bcachefs: Difference between revisions
imported>Onny Add note on snapshots |
imported>Onny Add section installation media support |
||
Line 30: | Line 30: | ||
<syntaxhighlight lang="console"> | <syntaxhighlight lang="console"> | ||
# bcachefs subvolume snapshot /mnt /mnt/snap1 | # bcachefs subvolume snapshot /mnt /mnt/snap1 | ||
</syntaxhighlight> | |||
== Tips and tricks == | |||
=== Generate bcachefs enabled installation media === | |||
Use following Nix expression to generate a ISO installation image with a bcachefs enabled kernel | |||
{{file|iso.nix|nix|<nowiki> | |||
# This module defines a small NixOS installation CD. It does not | |||
# contain any graphical stuff. | |||
{ config, pkgs, ... }: | |||
{ | |||
imports = [ | |||
<nixpkgs/nixos/modules/installer/cd-dvd/installation-cd-minimal.nix> | |||
]; | |||
boot.supportedFilesystems = [ "bcachefs" ]; | |||
isoImage.squashfsCompression = "gzip -Xcompression-level 1"; | |||
} | |||
</nowiki>}} | |||
<syntaxhighlight lang="console"> | |||
nix-build '<nixpkgs/nixos>' -A config.system.build.isoImage -I nixos-config=iso.nix | |||
</syntaxhighlight> | </syntaxhighlight> |