Recovering data on Ubuntu from a XFS filesystem

The Spyder

2[H]4U
Joined
Jun 18, 2002
Messages
2,628
Hey guys,
I am trying to rescue some data from a failed buffalo NAS. I loaded up Ubuntu 8.10, mounted the disk, and moved 300~gb of data over. My issue is, there is a folder /share that shows as empty, even though I know there is 30~gb of data in there! When I run a chown cmd to attempt and take permission, it spits out

chown: cannot access `/storage/share/- CLIENTS': No such file or directory
chown: cannot access `/storage/share/- MISC': No such file or directory
chown: cannot access `/storage/share/- TEMP 30 Days': No such file or directory
chown: cannot access `/storage/share/Temporary Items': No such file or directory
chown: cannot access `/storage/share/trashbox/- COMPANY NAME': No such file or directory
chown: cannot access `/storage/share/- COMPANY NAME': No such file or directory

So its seeing it at some level, but not one I can access.

Advice?
 

longblock454

2[H]4U
Joined
Nov 28, 2004
Messages
2,056
There is a nifty cmd program called testdisk, probably already on your Ubuntu install. Don't recall the exact syntax but point it to your /share directory and let hammer away on it. It has worked for me on several occasions.
 

Scotch77

Gawd
Joined
Jul 27, 2005
Messages
769
sudo chown -R root * [I see you tried this, did you try it with sudo]
sudo chmod -R 777 *

from a ubuntu live cd should work. If that doesn't work let me know.

also try

sudo cp -R source dest

cp doesnt keep permission info
 

keenan

2[H]4U
Joined
Aug 5, 2009
Messages
2,695
You should probably ask this question on the XFS mailing list if you can't resolve it with normal OS-level tools. I'd recommend you don't run xfs_check, xfs_repair or any other filesystem-level tools until you get advice from them as these can hamper recovery efforts.

Also IME XFS is a fairly touchy filesystem and loses data fairly easily. You really need a good UPS and proper shutdown procedures every time if you want to avoid losing data with it.
 

The Spyder

2[H]4U
Joined
Jun 18, 2002
Messages
2,628
Thanks for the tips guys, this is in a full install enviroment.

Why Buffalo uses a mix of Ext3 and XFS I will never understand. There was a power outage, corrupted both discs, screwed the onboard flash. Basically trashed the device.

I will do some more research as I can NOT loose this data.
 

The Spyder

2[H]4U
Joined
Jun 18, 2002
Messages
2,628
Ended up doing this:

xfs_repair -L /dev/sdc6 (Force log zero)

Data was then unreadable in Ubuntu, but readable through UFSexplorer in windows.
So the data was saved, the NAS and drives are scrap though.
 
Top