Am Montag, dem 18.03.2024 um 16:13 +0000 schrieb Michael Tremer:
Hello,
On 15 Mar 2024, at 19:14, Stefan Schantl stefan.schantl@ipfire.org wrote:
As default we are using zstd for compression with level 1
Signed-off-by: Stefan Schantl stefan.schantl@ipfire.org
src/installer/hw.h | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/src/installer/hw.h b/src/installer/hw.h index 2de73a3be..402e5cd0d 100644 --- a/src/installer/hw.h +++ b/src/installer/hw.h @@ -54,6 +54,8 @@
#define SERIAL_BAUDRATE 115200
+#define BTRFS_MOUNT_OPTIONS "compress=zstd:1"
Is there no way to configure this in the filesystem when it is being created to be used as default?
SBTRFS provides the freedom to the user to tell which kind of compression, the used algorithm and the compression ration should be used by specifying this at mount time.
It also would be possible to change this at any later time by just change the mount option. (This only would affect newly created files.)
So yes, it is possible to start with zstd, switch over to xz, gz and finally uncompressed data on the same volume.
Reading through the BTRFS documentation, there is no option to persistant set the compression details.
https://btrfs.readthedocs.io/en/latest/Compression.html
I think it would be nicer to have a less busy /etc/fstab.
If I did not miss anything while reading the docs, we have to live with this or disable compression.
#define BYTES2MB(x) ((x) / 1024 / 1024) #define MB2BYTES(x) ((unsigned long long)(x) * 1024 * 1024)
-- 2.39.2