[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Undeletable files on UDF formatted HD



Hi,

I have an external (USB, bus powered) hard drive formatted as UDF
(using "mkudffs --media-type=hd"). There is no partitioning on the
device, and I zeroed the whole thing before initialising the UDF FS.

I was writing data to it from Mac OS X when the machine ran out of
batteries, leaving some apparently undeletable files. I can mount it
as user-writeable with devkit (or manually), and I can delete most of
the directories created by OS X. However there are some files that I
cannot remove, even as root. Looking at it under my Debian Squeeze/Sid
system, I see:

user@comp:User's Photos$ ls -lha
ls: cannot access 2894352707_a0c8d64f03_s.jpg: Permission denied
ls: cannot access 2895194764_974c6bd332.jpg: Permission denied
ls: cannot access 3104930600_67e87858fb_s.jpg: Permission denied
ls: cannot access 3104964654_bbdc00cdb7_s.jpg: Permission denied
ls: cannot access 3104967336_eb2ee44c68_s.jpg: Permission denied
ls: cannot access 3104977456_4608aa8bc3_s.jpg: Permission denied
ls: cannot access 3105012298_4fa5ce6579_s.jpg: Permission denied
ls: cannot access 3105365429_c03acdedd9_s.jpg: Permission denied
ls: cannot access 3106207378_c9703fbdf3_s.jpg: Permission denied
total 0
drwx------  2 user user  696 2008-12-16 10:16 .
drwx------ 17 user user 1.4K 2010-02-16 07:29 ..
??????????  ? ?     ?        ?                ? 2894352707_a0c8d64f03_s.jpg
??????????  ? ?     ?        ?                ? 2895194764_974c6bd332.jpg
??????????  ? ?     ?        ?                ? 3104930600_67e87858fb_s.jpg
??????????  ? ?     ?        ?                ? 3104964654_bbdc00cdb7_s.jpg
??????????  ? ?     ?        ?                ? 3104967336_eb2ee44c68_s.jpg
??????????  ? ?     ?        ?                ? 3104977456_4608aa8bc3_s.jpg
??????????  ? ?     ?        ?                ? 3105012298_4fa5ce6579_s.jpg
??????????  ? ?     ?        ?                ? 3105365429_c03acdedd9_s.jpg
??????????  ? ?     ?        ?                ? 3106207378_c9703fbdf3_s.jpg

That's a new one for me. Attempting to delete these files as root does nothing:

user@comp:User's Photos$ sudo rm *
[sudo] password for user:
rm: cannot remove `2894352707_a0c8d64f03_s.jpg': Permission denied
rm: cannot remove `2895194764_974c6bd332.jpg': Permission denied
rm: cannot remove `3104930600_67e87858fb_s.jpg': Permission denied
rm: cannot remove `3104964654_bbdc00cdb7_s.jpg': Permission denied
rm: cannot remove `3104967336_eb2ee44c68_s.jpg': Permission denied
rm: cannot remove `3104977456_4608aa8bc3_s.jpg': Permission denied
rm: cannot remove `3105012298_4fa5ce6579_s.jpg': Permission denied
rm: cannot remove `3105365429_c03acdedd9_s.jpg': Permission denied
rm: cannot remove `3106207378_c9703fbdf3_s.jpg': Permission denied

And if it helps, this is what dmesg says:

[   15.867979] usb 2-3: new high speed USB device using ehci_hcd and address 8
[   16.000730] usb 2-3: New USB device found, idVendor=1058, idProduct=0704
[   16.000734] usb 2-3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[   16.000737] usb 2-3: Product: External HDD
[   16.000739] usb 2-3: Manufacturer: Western Digital
[   16.000741] usb 2-3: SerialNumber: 57442D575852304134394D43383135
[   16.000824] usb 2-3: configuration #1 chosen from 1 choice
[   16.001046] scsi9 : SCSI emulation for USB Mass Storage devices
[   16.001809] usb-storage: device found at 8
[   16.001811] usb-storage: waiting for device to settle before scanning
[   20.987898] usb-storage: device scan complete
[   20.988464] scsi 9:0:0:0: Direct-Access     WD       5000BEV
External 1.75 PQ: 0 ANSI: 4
[   20.988721] sd 9:0:0:0: Attached scsi generic sg3 type 0
[   20.989764] sd 9:0:0:0: [sdc] 976773168 512-byte hardware sectors:
(500 GB/465 GiB)
[   20.990257] sd 9:0:0:0: [sdc] Write Protect is off
[   20.990260] sd 9:0:0:0: [sdc] Mode Sense: 23 00 00 00
[   20.990261] sd 9:0:0:0: [sdc] Assuming drive cache: write through
[   20.991502] sd 9:0:0:0: [sdc] Assuming drive cache: write through
[   20.991505]  sdc: unknown partition table
[   21.027550] sd 9:0:0:0: [sdc] Attached SCSI disk
[   22.352871] UDF-fs: No anchor found
[   22.352874] UDF-fs: Rescanning with blocksize 2048
[   22.383720] UDF-fs INFO UDF: Mounting volume 'Data Portable',
timestamp 2009/12/19 08:25 (1000)
[   24.701229] wlan0: no IPv6 routers present
[  300.934609] udf: udf_read_inode(ino 2809427) failed !bh
[  300.948583] udf: udf_read_inode(ino 2754576) failed !bh
...
[  419.093327] udf: udf_read_inode(ino 2813607) failed !bh

Are there any tools to repair the filesystem? I couldn't find any UDF
fsck, but maybe someone here knows of something? The data itself is
safe somewhere else, but all the same I'd rather not wipe and
re-format the entire drive, and if this is prone to happen it'd be
good to know a better way to fix it. (Currently I'm using udftools
1.0.0b3-14 on linux 2.6.30-2-amd64.)

Please CC me on any replies :)

Cheers,
Jason


Reply to: