Help - Search - Members - Calendar
Full Version: Cannot remove directory...
Neowin Forums > *nix Customization & Support > Linux Server/BSD/Unix
Fish
I added another hard disk to my Freenas PC, and moved a load of music over onto the new drive. At the end of the move Nautilus complained about something (and I know I should have paid more attention to this) and although the music has been copied correctly, I now have a whole bunch of empty folders in my Bin.

Thing is, I can't get rid of them. If I try in Nautilus it says that the device or resource is busy, and I have to "Skip" hundreds (it seems) dialog boxes. Further investigation reveals that the folders are actually still on my Freenas box in a directory called .Trash-fish. So in a terminal I did:
CODE
sudo rm -rf /mnt/freenas/.Trash-fish

But I get
CODE
rm: cannot remove directory `/mnt/freenas/.Trash-fish/Velvet Revolver/Contraband': Device or resource busy

....
for every directory.

They are all empty directories (I've looked in them) so they're not taking much space up, but I like to keep things tidy, and I really don't like seeing them in my Bin. How can I get rid of them?
Fish
OK, not exactly sure what happened here, but today I switched my PC on and I noticed that one of the Freenas drives hadn't been mounted, and it was the one with these undeletable files. I checked my fstab and I had made an error. I was accidentally trying to mount the two drives to the same mount point. So I quickly put that right, and remounted everything. I was finally able to completely empty my bin.

Still not sure whether it was a mounting problem, or just one of those things when all you need to do is restart the PC... But I suspect the former whistle.gif
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.