forced fsck (again?)
Eric Sandeen
sandeen at redhat.com
Tue Jan 29 02:42:11 UTC 2008
Some hints for xfs, which does not enforce check intervals, so:
- no mechanism or need to delay next check
- no mechanism to enforce check on next boot; just notify w/ email
- no mechanism to read last-checked; just check on acceptable cron
interval
Also, you really want to use xfs_repair -n instead of xfs_check;
it's much faster and more memory-efficient.
So most of the xfs) cases are just documenting that xfs can't
and/or doesn't need to do anything, they don't really need to
be there - up to you. :)
-Eric
--- lvcheck.orig 2008-01-28 20:23:16.000000000 -0600
+++ lvcheck 2008-01-28 20:40:25.000000000 -0600
@@ -111,6 +111,9 @@
ext2|ext3)
tune2fs -C 16000 "$dev"
;;
+ xfs)
+ # XFS does not enforce check intervals; let email suffice.
+ ;;
*)
log "warning" "Don't know how to force a check on $fstype..."
;;
@@ -126,6 +129,9 @@
ext2|ext3)
tune2fs -C 0 -T now "$dev"
;;
+ xfs)
+ # XFS does not enforce check intervals; nothing to delay
+ ;;
*)
log "warning" "Don't know how to delay checks on $fstype..."
;;
@@ -143,6 +149,10 @@
dumpe2fs -h "$dev" 2>/dev/null | grep 'Last checked:' | \
sed -e 's/Last checked:[[:space:]]*//'
;;
+ xfs)
+ # XFS does not save last-checked; just check on cron interval
+ echo "Unknown"
+ ;;
*)
# TODO: add support for various FSes here
echo "Unknown"
@@ -167,7 +177,7 @@
return 0
;;
xfs)
- nice logsave -as "${tmpfile}" xfs_check "$dev"
+ nice logsave -as "${tmpfile}" xfs_repair -n "$dev"
return $?
;;
jfs)
More information about the Ext3-users
mailing list