1

I have an external drive (WD My Book World) mounted on my Ubuntu system which I've used for backups over the last few years. Some of the backups included SVN repositories which now include files which I can't appear to delete. I can mv them and view their contents, but that seems to be it. My question is: how can I remove these files from this external drive?

Here's a sample of what I'm dealing with:

root@zodiac:/mnt/mybook# mount | grep mybook
//192.168.1.4/PUBLIC on /mnt/mybook type cifs (rw,mand)

root@zodiac:/mnt/mybook# ls -lh entries 
-r-xr--r-- 1 www-data www-data 1.2K 2008-03-26 21:29 entries

root@zodiac:/mnt/mybook# file entries 
entries: ASCII text

root@zodiac:/mnt/mybook# head -n5 entries 
8

dir
1
file:///home/svn/gt_data

root@zodiac:/mnt/mybook# stat entries 
  File: `entries'
  Size: 1201        Blocks: 8          IO Block: 16384  regular file
Device: 18h/24d Inode: 2149510     Links: 1
Access: (0544/-r-xr--r--)  Uid: (   33/www-data)   Gid: (   33/www-data)
Access: 2008-03-26 21:29:34.000000000 -0700
Modify: 2008-03-26 21:29:34.000000000 -0700
Change: 2010-01-09 08:59:06.000000000 -0800

root@zodiac:/mnt/mybook# rm entries 
rm: cannot remove `entries': No such file or directory

root@zodiac:/mnt/mybook# cat > entries 
-su: entries: No such file or directory

root@zodiac:/mnt/mybook# lsattr entries
lsattr: Inappropriate ioctl for device While reading flags on entries

@Tobu,

root@zodiac:/mnt/mybook# grep mybook /proc/self/mountinfo
33 18 0:24 / /mnt/mybook rw - cifs //192.168.1.4/PUBLIC rw,mand,unc=\\192.168.1.4\PUBLIC,username=root,posixpaths,acl,rsize=16384,wsize=57344
5
  • 1
    What does grep mybook /proc/self/mountinfo say?
    – Tobu
    Jan 9, 2010 at 18:02
  • @Tobu, Thanks and see my reply above. Cheers.
    – bsterne
    Jan 9, 2010 at 22:37
  • CIFS is Samba or the windows file server, right? A remote filesystem is acting up.
    – Tobu
    Jan 9, 2010 at 23:02
  • tail -F /var/log/syslog /var/log/kern.log while you do the rm entries could tell you more.
    – Tobu
    Jan 9, 2010 at 23:07
  • I appreciate the replies. Neither of those logs showed any activity when I tried to rm entries. Any other thoughts? I'm not aware of another fs that this device will mount with which might behave better.
    – bsterne
    Jan 10, 2010 at 1:12

2 Answers 2

2

The errors indicate that the file system is corrupted. This might be from not unpluggingn the disk correctly, or it might be defective. You need to run a file system checker (fsck) on the partition or reformat it and see if it is reliable after that.

-1

Looks like a server configuration error. The fact that the share name is PUBLIC is a red flag. I wouldn't necessarily expect a PUBLIC share to be writable.

1
  • There are tons of other files on the share that I can modify and remove. I can also create new files there. Some of the files, though, just won't cooperate. PUBLIC is just the name of the partition that comes on the drive when it comes from the factory.
    – bsterne
    Jan 10, 2010 at 2:37

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .