Whamcloud - gitweb
e2fsck: fix mysterious "FILE SYSTEM WAS MODIFIED" with no changes
authorTheodore Ts'o <tytso@mit.edu>
Thu, 16 Jun 2011 05:13:42 +0000 (01:13 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 16 Jun 2011 05:22:02 +0000 (01:22 -0400)
commita3efe4842054175d01b465fbe0b29b9be8b800a1
treee00375edf712715a27328af15306accf366efc2a
parent96367ad3bc849220651b20f41340b48e07e82b04
e2fsck: fix mysterious "FILE SYSTEM WAS MODIFIED" with no changes

Commit 2a77a784a3 (firest released in e2fsprogs 1.33) compared
superblock summary free blocks and inode counts with the allocation
bitmap counts before starting the file system check proper, and if
they differed, set the superblock and marked it as dirty.  If no other
file systme changes were required, this would cause a "*** FILE SYSTEM
WAS MODIFIED ***" message without any explanation of what e2fsck had
changed.

We fix this by only setting the superblock summary free block/inodes
counts if we are skipping a full check, and in non-preen mode, e2fsck
will now print an explicit message stating how the superblock had been
updated.

In a full check, any updates to the superblock free blocks/inodes
fields will be noted in pass5.

This change requires changing a few test results (essentially
reversing the changes made in commit 2a77a784a3).

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
12 files changed:
e2fsck/e2fsck.h
e2fsck/problem.c
e2fsck/problem.h
e2fsck/super.c
e2fsck/unix.c
tests/f_baddir/expect.1
tests/f_dup/expect.1
tests/f_dup2/expect.1
tests/f_end-bitmap/expect.1
tests/f_lpf/expect.1
tests/f_summary_counts/expect.1
tests/f_unused_itable/expect.1