[systemd-devel] [PATCH 2/2] Add +C attrib to the journal files directories
kreijack at libero.it
Sat Mar 21 04:56:53 PDT 2015
From: Goffredo Baroncelli <kreijack at inwind.it>
Add +C attrib to the journal files directories. The journal file format
behaves bad on a BTRFS filesystem: the performances decrease during the
To avoid this issue, this tmpfile.d snippet sets the NOCOW attribute to the
journal files directories, so newly created journal files inherit the NCOOW
Be aware that the NOCOW attribute disables the BTRFS checksums, prevent BTRFS
to rebuild a corrupted file in a RAIDx filesystem. However the perfomances
In a single disk filesystem (or a filesystem without redundancy) it is safe
to use the NOCOW flags.
tmpfiles.d/journal-nocow.conf | 19 +++++++++++++++++++
1 file changed, 19 insertions(+)
create mode 100644 tmpfiles.d/journal-nocow.conf
diff --git a/tmpfiles.d/journal-nocow.conf b/tmpfiles.d/journal-nocow.conf
new file mode 100644
@@ -0,0 +1,19 @@
+# This file is part of systemd.
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+# See tmpfiles.d(5) for details
+# set the journal file as NOCOW; make sense only for BTRFS filesystem
+# WARNING: the NOCOW attribute disables the BTRFS checksums, prevent BTRFS
+# to rebuild a corrupted file in a RAIDx filesystem. It is suggested
+# to disables these setting in this kind of filesystem.
+# However in a single disk filesystem (or a filesystem without
+# redundancy) it is safe to use the NOCOW flag.
+# Setting the NOCOW flag the perfomances increase.
+h /var/log/journal/%m - - - - +C
+h /var/log/journal/remote - - - - +C
More information about the systemd-devel