All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Marcin Mirosław" <marcin@mejor.pl>
To: xfs@oss.sgi.com
Subject: Enabling lazy counters damages filesystem
Date: Wed, 28 Apr 2010 16:34:25 +0200	[thread overview]
Message-ID: <4BD84771.4030804@mejor.pl> (raw)

Hello,
Please look at this:
# mkfs.xfs -f /dev/malowazne/test
meta-data=/dev/malowazne/test    isize=256    agcount=4, agsize=524288 blks
         =                       sectsz=512   attr=2
data     =                       bsize=4096   blocks=2097152, imaxpct=25
         =                       sunit=0      swidth=0 blks
naming   =version 2              bsize=4096   ascii-ci=0
log      =internal log           bsize=4096   blocks=2560, version=2
         =                       sectsz=512   sunit=0 blks, lazy-count=0
realtime =none                   extsz=4096   blocks=0, rtextents=0

# xfs_check /dev/malowazne/test
# xfs_check /dev/malowazne/test

It's still clean.

# xfs_admin -c 1 /dev/malowazne/test
Enabling lazy-counters
# xfs_check /dev/malowazne/test
sb_features2 (0xa) not same as sb_bad_features2 (0x8)

Not good, let's repair fs:

# xfs_repair /dev/malowazne/test
Phase 1 - find and verify superblock...
superblock has a features2 mismatch, correcting
writing modified primary superblock
Phase 2 - using internal log
        - zero log...
        - scan filesystem freespace and inode maps...
        - found root inode chunk
Phase 3 - for each AG...
        - scan and clear agi unlinked lists...
        - process known inodes and perform inode discovery...
        - agno = 0
        - agno = 1
        - agno = 2
        - agno = 3
        - process newly discovered inodes...
Phase 4 - check for duplicate blocks...
        - setting up duplicate extent list...
        - check for inodes claiming duplicate blocks...
        - agno = 0
        - agno = 1
        - agno = 2
        - agno = 3
Phase 5 - rebuild AG headers and trees...
        - reset superblock...
Phase 6 - check inode connectivity...
        - resetting contents of realtime bitmap and summary inodes
        - traversing filesystem ...
        - traversal finished ...
        - moving disconnected inodes to lost+found ...
Phase 7 - verify and correct link counts...
done

Now i'm trying to turn off lazy counters:

# xfs_admin -c 0 /dev/malowazne/test
Disabling lazy-counters
# xfs_check /dev/malowazne/test
sb_features2 (0x8) not same as sb_bad_features2 (0xa)
# xfs_repair /dev/malowazne/test
Phase 1 - find and verify superblock...
superblock has a features2 mismatch, correcting
writing modified primary superblock
Phase 2 - using internal log
        - zero log...
        - scan filesystem freespace and inode maps...
        - found root inode chunk
Phase 3 - for each AG...
        - scan and clear agi unlinked lists...
        - process known inodes and perform inode discovery...
        - agno = 0
        - agno = 1
        - agno = 2
        - agno = 3
        - process newly discovered inodes...
Phase 4 - check for duplicate blocks...
        - setting up duplicate extent list...
        - check for inodes claiming duplicate blocks...
        - agno = 0
        - agno = 1
        - agno = 2
        - agno = 3
Phase 5 - rebuild AG headers and trees...
        - reset superblock...
Phase 6 - check inode connectivity...
        - resetting contents of realtime bitmap and summary inodes
        - traversing filesystem ...
        - traversal finished ...
        - moving disconnected inodes to lost+found ...
Phase 7 - verify and correct link counts...
done

# mount /dev/malowazne/test /mnt/test
# xfs_info /dev/malowazne/test
meta-data=/dev/mapper/malowazne-test isize=256    agcount=4,
agsize=524288 blks
         =                       sectsz=512   attr=2
data     =                       bsize=4096   blocks=2097152, imaxpct=25
         =                       sunit=0      swidth=0 blks
naming   =version 2              bsize=4096   ascii-ci=0
log      =internal               bsize=4096   blocks=2560, version=2
         =                       sectsz=512   sunit=0 blks, lazy-count=1
realtime =none                   extsz=4096   blocks=0, rtextents=0

So as you can see lazy conters are still turn on.
I'm using:
# mkfs.xfs -V
mkfs.xfs version 3.0.3
# uname -r
2.6.33-zen2

The same problem noticed with kernel-2.6.28-r9 with grsecurity, and with
xfsprogs-3.0.0 .
Is this behaviour bug or i don't know about something that i should?:)

Regards!
Marcin









_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

             reply	other threads:[~2010-04-28 14:32 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-28 14:34 Marcin Mirosław [this message]
2010-04-28 21:40 ` Enabling lazy counters damages filesystem Eric Sandeen
2010-04-28 23:04 ` Dave Chinner
2010-04-29  1:43   ` Dave Chinner
2010-04-29  1:51     ` Eric Sandeen
2010-04-29  2:05       ` Dave Chinner
2010-04-29  8:03         ` Marcin Mirosław

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4BD84771.4030804@mejor.pl \
    --to=marcin@mejor.pl \
    --cc=xfs@oss.sgi.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.