Logs constantly show

systemd-journald[395]: Failed to set file attributes: Inappropriate
ioctl for device

This is because ext4 does not support FS_NOCOW_FL.
---
 src/journal/journal-file.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/journal/journal-file.c b/src/journal/journal-file.c
index 9c9a548..ecabfd3 100644
--- a/src/journal/journal-file.c
+++ b/src/journal/journal-file.c
@@ -2610,7 +2610,8 @@ int journal_file_open(
                  * checksumming). */
                 r = chattr_fd(f->fd, true, FS_NOCOW_FL);
                 if (r < 0)
-                        log_warning_errno(errno, "Failed to set file 
attributes: %m");
+                        if(r != -ENOTTY)
+                                log_warning_errno(errno, "Failed to set file 
attributes: %m");
 
                 /* Let's attach the creation time to the journal file,
                  * so that the vacuuming code knows the age of this
-- 
2.3.0

_______________________________________________
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/systemd-devel

Reply via email to