I have 2 "data" drives. One is ntfs, the other is ext4.
The Trash works for both drives when I allow Nautilus to handle the mount.
I've opted to auto-mount them via entries in /etc/fstab, but when I do this, only the ext4 gives me a functioning Trash directory.
Trash on the ntfs drive simply does not work.
When I press "delete" or use the context menu item "Move to Trash", I get this error dialog message.
Cannot move file to trash, do you want to delete immediately?
. . . . The file "test" cannot be moved to the trash . . . .
Here are my /etc/fstab lines.
/dev/sdb1 /media/D_0931_data ntfs defaults 0 0
/dev/sdc1 /media/E_0298_back ext4 defaults 0 0
… and here is how I created the mountpoint directories.
sudo mkdir /media/D_0931_data
sudo mkdir /media/E_0298_back
Everything seems to be working fine, except for the Trash on the ntfs drive…
The Trash on the ext4 drive works normally.
UPDATE: more info about ownership change after sudo mount -a
sudo mkdir /media/D_0931_data
sudo mkdir /media/E_0298_back
#
ls -la /media
drwxr-xr-x 2 root root 4096 2010-11-28 10:27 D_0931_data
drwxr-xr-x 2 root root 4096 2010-11-28 10:27 E_0298_back
#
gksu gedit /etc/fstab
/dev/sdb1 /media/D_0931_data ntfs defaults 0 0
/dev/sdc1 /media/E_0298_back ext4 defaults 0 0
#
sudo mount -a
#
ls -la /media
drwxrwxrwx 1 root root 12288 2010-11-28 10:22 D_0931_data
drwxrwxr-x 5 root axiom 4096 2010-11-28 09:51 E_0298_back
Best Answer
I believe Nautilus needs a
.Trash-1000
folder in the root of the filesystem (e.g./media/D_0931_data/.Trash-1000
) to exist and be user-writeable.NOTE: the
1000
in the.Trash-1000
is your user ID. You can get yours byid -u USERNAME
. Change it accordingly if needed.Try running this:
sudo mkdir /media/D_0931_data/.Trash-1000; sudo chmod 777 /media/D_0931_data/.Trash-1000
.If that didn't work, can you try the same but with
.Trash
instead ofTrash-1000
, and if that didn't work, post the output ofls -la /media/D_0931_data
?Try adding this to fstab (on the ntfs line):
defaults,uid=1000
instead of justdefaults
.