public inbox for linux-ext4@vger.kernel.org
 help / color / mirror / Atom feed
* [Bug 218626] New: fstest ext4/014 fails when using filesystem quotas
@ 2024-03-22 11:54 bugzilla-daemon
  2024-03-26 15:38 ` [Bug 218626] " bugzilla-daemon
  0 siblings, 1 reply; 2+ messages in thread
From: bugzilla-daemon @ 2024-03-22 11:54 UTC (permalink / raw)
  To: linux-ext4

https://bugzilla.kernel.org/show_bug.cgi?id=218626

            Bug ID: 218626
           Summary: fstest ext4/014 fails when using filesystem quotas
           Product: File System
           Version: 2.5
          Hardware: All
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P3
         Component: ext4
          Assignee: fs_ext4@kernel-bugs.osdl.org
          Reporter: luis.henriques@linux.dev
        Regression: No

Created attachment 306024
  --> https://bugzilla.kernel.org/attachment.cgi?id=306024&action=edit
full test log

I've started looking into a failure in fstest ext4/014.  It's very easy to
reproduce, it simply has to be executed with quotas (without enabling quotas
the test passes).

Here's the fstests options I'm using:

export MOUNT_OPTIONS="-o quota"
export MKFS_OPTIONS="-O quota"

And here's the output (the last line is where the test fails):

QA output created by 014
+ create scratch fs
+ mount fs image
+ make some files
+ check fs
+ corrupt image
+ mount image
+ modify files
broken: 1
+ repair fs
+ mount image (2)
+ chattr -R -i
+ modify files (2)
broken: 0
+ check fs (2)
fsck should not fail

Basically, the test corrupts the first block of the root directory by doing the
following

- create and mount the filesystem
- create a few files
- unmount filesystem
- debugfs -w -R "zap -f / 0" <dev>
- mount, and attempt to modify some of the files created before, and unmount

After this last unmount, e2fsck attempts to fix the filesystem, including the
quota info.  It exits with exit code '1' ('File system errors corrected'),
which is what the test expects.

However, after yet another filesystem mount/unmount cycle, another e2fsck run
will still complain about quota info being inconsistent.

The test will pass if another e2fsck is run immediately after the first one,
which seems to indicate there's some fix missing in the first pass, but I
couldn't figure out what (the code isn't particularly easy to grasp...).

On the other end, I'd also expect that the kernel would notice that something
was wrong when the filesystem is mounted after e2fsck is run, but dmesg doesn't
show anything.

For reference, I'm attaching the full test log that includes the output of
e2fsck.

-- 
You may reply to this email to add a comment.

You are receiving this mail because:
You are watching the assignee of the bug.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-03-26 15:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-03-22 11:54 [Bug 218626] New: fstest ext4/014 fails when using filesystem quotas bugzilla-daemon
2024-03-26 15:38 ` [Bug 218626] " bugzilla-daemon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox