Hi list,

[I sent this a few days ago but it doesn't seem to have come through; apologies if you're reading it for a second time.]

I'd like to (ab)use LVM snapshots for a periodic online fsck in the background. The essence of the script is something like this:

lvcreate -s -L $snapsize vg0/srv
e2fsck -p /dev/vg0/lvol0 # discard orphaned inodes
e2fsck -fy /dev/vg0/lvol0
lvremove -f vg0/lvol0

On Lucid, this seems to work well. On Precise, I get some false positives almost every time I run it: wrong free blocks/inodes count, and/or bitmap differences. The filesystem is actually OK; none of these minor inconsistencies show up during a boot-time fsck.

My understanding is that ext4 is wired up with LVM to do a sync and clean up these inconsistencies at the time a snapshot is made, and certainly on Lucid it seems OK. Can anyone tell me if the behaviour has changed, or if I'm doing something wrong?

So far I've reproduced this on my workstation and laptop (one SATA drive each) and on one scratch server (Dell CERC RAID, five SATA drives). All of this is on bare metal and local storage.

I searched around a bit but the only thread I found is [1] which doesn't seem relevant -- I can't reproduce his error.

[1] https://lkml.org/lkml/2012/1/5/76

--
Ryan Tandy - Programmer/Analyst           [email protected]
School District 63 (Saanich)                +1 250 652 7385

--
ubuntu-server mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server
More info: https://wiki.ubuntu.com/ServerTeam

Reply via email to