I have an external USB HDD with a b0rked XFS filesystem. When I connect it (via USB cable), XFS internal errors appear in /var/log/messages. Here are the first few (with more in the attached file): Jul 21 23:54:18 osage kernel: XFS: bad magic number Jul 21 23:54:18 osage kernel: XFS: SB validate failed Jul 21 23:54:36 osage kernel: XFS mounting filesystem sdb1 Jul 21 23:54:36 osage kernel: Starting XFS recovery on filesystem: sdb1 (logdev: internal) Jul 21 23:55:12 osage kernel: XFS internal error XFS_WANT_CORRUPTED_GOTO at line 1544 of file fs/xfs/xfs_alloc.c. Caller ... Attaching a second USB device, such as a thumb drive, produces no messages, not even any USB related messages. Perhaps the USB module has crashed ... Reproducible: Always Steps to Reproduce: 1.reboot machine to load clean kernel 2.attach USB XFS HDD 3. Actual Results: see attached file for messages Expected Results: HDD should mount as /mnt/usbhd ### uname -a ### Linux osage 2.6.34-gentoo-r1 #1 SMP Sun Jun 27 15:01:10 EDT 2010 x86_64 AMD Athlon(tm) 64 X2 Dual Core Processor 5000+ AuthenticAMD GNU/Linux
Created attachment 239887 [details] /var/log/messages output USB device is recognized; XFS system is identified as corrupt
Please post your `emerge --info' and attach the .config file for that kernel. Also tell us which version of the kernel sources that is (and whether it's vanilla-sources, gentoo-sources or something else).
Created attachment 240131 [details] emerge --info output
Created attachment 240133 [details] configuration for Linux kernel version: 2.6.34-gentoo-r1
Kernel source is gentoo-sources-2.6.34-r1
Being a clueless regarding XFS and searching the internet for XFS_WANT_CORRUPTED_GOTO, I got many results with people that used xfs_repair(8) and some of them were successful. Have you tried it? This guy here describes the backup procedure as well, to be on the safe side: http://www.opensubscriber.com/message/xfs@oss.sgi.com/8698490.html
I see that the status has been changed to "RESOLVED NEEDINFO". What additional info do you need?
See comment #6
Plugging in the USB hard drive causes the XFS internal error XFS_WANT_CORRUPTED_GOTO. After this has occurred, the USB subsystem seems to be broken. Disconnecting the USB hard drive logs a "usb 2-2: USB disconnect, address 4", but reconnecting the USB does _not_ produce any USB messages. Connecting a memory stick also does not produce any USB messages. It seems that the kernel has stopped recognizing USB devices. I have tried running xfs_repair as requested. Command "xfs_repair /dev/sdb" reports "xfs_repair: cannot open /dev/sdb: Device or resource busy" Command "xfs_repair /dev/sdb1" produces no disk activity and no output. After plugging in the USB hard drive, the kernel is sufficiently broken that I must reboot my workstation in order to do anything USB related. I hope the above information clarifies the situation. David
reopening
Greetings David, what's the situation here? Did you manage to access the filesystem? After googling again for "Corruption of in-memory data detected." and "XFS_WANT_CORRUPTED_GOTO", I decided that the best course of action would be to stop waiting for an answer here (no one of us is using XFS afaik) and file a bug upstream. I know it's a bore, but at least they are gonna give some educated answers instead of google results :) In case you decide to open a bug upstream, please leave the URL here. If you have solved the problem, please state how you solved it and close this bug :) Thank you!
Please submit upstream as requested and well follow the progress upstream