can't mount XFS from a read-only device
Hello all,
I'm using a RAID enclosure that provides read-only snapshots. It works perfectly fine using JFS.
But with XFS, I keep trying and it keeps failing :
XFS mounting filesystem sdb
Ending clean XFS mount for filesystem: sdb
sd 11:0:0:1: [sdc] Result: hostbyte=DID_OK
driverbyte=DRIVER_SENSE,SUGGEST_OK
sd 11:0:0:1: [sdc] Sense Key : Data Protect [current]
sd 11:0:0:1: [sdc] Add. Sense: Write protectedend_request: I/O error, dev sdc, sector 0
Filesystem "sdc": Disabling barriers, trial barrier write failed XFS mounting filesystem sdc
sd 11:0:0:1: [sdc] Result: hostbyte=DID_OK
driverbyte=DRIVER_SENSE,SUGGEST_OK
sd 11:0:0:1: [sdc] Sense Key : Data Protect [current]
sd 11:0:0:1: [sdc] Add. Sense: Write protectedend_request: I/O error, dev sdc, sector 1953792056 xfs_force_shutdown(sdc,0x1) called from line 420 of file fs/xfs/xfs_rw.c. Return address = 0xffffffff80381f89
Filesystem "sdc": I/O Error Detected. Shutting down filesystem: sdc
Please umount the filesystem, and rectify the problem(s)
I/O error in filesystem ("sdc") meta-data dev sdc block0x74748038 ("xlog_bwrite") error 5 buf count 262144
XFS: failed to locate log tail
XFS: log mount/recovery failed: error 5
XFS: log mount failed
I don't really grasp what's wrong...
Signature · 8 lines
------------------------------------------------------------------------ Emmanuel Florac | Intellique ------------------------------------------------------------------------ _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Quoted 34 lines · Emmanuel Florac
Hello all,
I'm using a RAID enclosure that provides read-only snapshots. It works perfectly fine using JFS.
But with XFS, I keep trying and it keeps failing :XFS mounting filesystem sdb
Ending clean XFS mount for filesystem: sdb
sd 11:0:0:1: [sdc] Result: hostbyte=DID_OK
driverbyte=DRIVER_SENSE,SUGGEST_OKsd 11:0:0:1: [sdc] Sense Key : Data Protect [current]
sd 11:0:0:1: [sdc] Add. Sense: Write protected
end_request: I/O error, dev sdc, sector 0
Filesystem "sdc": Disabling barriers, trial barrier write failed XFS mounting filesystem sdcsd 11:0:0:1: [sdc] Result: hostbyte=DID_OK
driverbyte=DRIVER_SENSE,SUGGEST_OKsd 11:0:0:1: [sdc] Sense Key : Data Protect [current]
sd 11:0:0:1: [sdc] Add. Sense: Write protected
end_request: I/O error, dev sdc, sector 1953792056xfs_force_shutdown(sdc,0x1)called from line 420 of filefs/xfs/xfs_rw.c. Return address =0xffffffff80381f89Filesystem "sdc": I/O Error Detected. Shutting down filesystem: sdc
Please umount the filesystem, and rectify the problem(s)
Quoted 9 lines
I/O error in filesystem ("sdc") meta-data dev sdc block
0x74748038("xlog_bwrite") error 5 buf count 262144XFS: failed to locate log tail
XFS: log mount/recovery failed: error 5
XFS: log mount failedI don't really grasp what's wrong...
try mount -o norecovery (and maybe -o nobarrier)
-Eric
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
Le Fri, 09 Oct 2009 13:59:13 -0500 vous écriviez:
Quoted 1 line
try mount -o norecovery (and maybe -o nobarrier)
Thank you, that worked.
I can't help but think that when given the "ro" option, XFS shouldn't try to write a single bit to the underlying device, or else what's the point?
Signature · 8 lines
-------------------------------------------------- Emmanuel Florac www.intellique.com -------------------------------------------------- _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Quoted 9 lines · Emmanuel Florac
Le Fri, 09 Oct 2009 13:59:13 -0500 vous écriviez:
Quoted 1 line
try mount -o norecovery (and maybe -o nobarrier)
Thank you, that worked.
I can't help but think that when given the "ro" option, XFS shouldn't try to write a single bit to the underlying device, or else what's the point?
For a dirty log, we do still recover -unless- the underlying device is RO. Otherwise you get a corrupt fs mounted ro.... other filesystems do the same thing, FWIW.
For a clean log I agree; what kernel was this? I vaguely remember a fix in this area.
Which option solved it? (norecovery I'm guessing)
-Eric
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
Le Fri, 09 Oct 2009 14:28:47 -0500 vous écriviez:
Quoted 2 lines
For a clean log I agree; what kernel was this? I vaguely remember a fix in this area.
It's a 2.6.24.7. I did a quick try with 2.6.27.25 and got exactly the same error.
Quoted 1 line
Which option solved it? (norecovery I'm guessing)
Yes, norecovery was the missing part.
Signature · 8 lines
-------------------------------------------------- Emmanuel Florac www.intellique.com -------------------------------------------------- _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
A message that is not in the archive (sent off-list or not yet received): [email protected]
Le Fri, 9 Oct 2009 19:43:51 +0200 vous écriviez:
Quoted 7 lines
Log recovery is failing on a read-only device. Try mounting with the "ro,norecovery" options. However, this will give you a potentially inconsistent view of the filesystem.
Are you snapshotting a live filesystem? If yes, then I'd suggest using
xfs_freeze-f/snapshot/xfs_freeze -u to get consistent snapshots.
Yes, norecovery did it. I did snapshots previously using LVM, but these are writable, so only "nouuid" is necessary (to mount the original FS and snapshot side by side).
I thought that xfs_freeze was broken recently?
Signature · 8 lines
-------------------------------------------------- Emmanuel Florac www.intellique.com -------------------------------------------------- _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs