Ubuntu: “Move to Trash” doesn't appear, but only “Delete” on context menu



Question:

I could not see "Move to Trash" option on context menu, but only seeing "Delete" option that make the file completely removed (Are you sure you want to permanently delete “file.txt”?). I also tried chown/chmod on the files and folders that I am trying to move to trash. So, I can NOT remove files via Sublime Text 3 too.

If I do sudo nautilus and opening the file explorer then I can see "Move to Trash" option, but then can not see the file that I moved to trash using this option in "Trash".

E.g;

# kerem is superuser  sudo chown kerem:kerem /var/www/file.txt  sudo chmod 0777 /var/www/file.txt  

Trash perms;

kerem@kerem:~/.local/share$ ls -la | grep Trash  drwx------  5 kerem kerem  4096 Ara 11 04:09 Trash  

ubuntu-context-menu

Using 14.04 64bit, desktop version and /home and /var/www are on different partitions like sda1 and sda7 (both ext4 / -> /dev/sda6 and /home -> /dev/sda7). But no dual system alongside Ubuntu like Windows.

Thank you.


Solution:1

After wasting a few hours, here is the solution;

$ sudo -s  $ cd /    # Work out your user account's id - it's usually 1000  $ cat /etc/passwd | grep "username"    # Make a new trash director with the id we found above  $ mkdir .Trash-1000    # Change the permissions of new directory to allow us to access it  $ chmod 777 .Trash-1000 && chown username:username .Trash-1000  

Additionally, I can make a sym link into ~/.local/share/Trash to remember there is a trash more, so need to be emptied sometimes. :)

$ ln -s /.Trash-1000 ~/.local/share/Trash  

Credits: https://askubuntu.com/a/516825/179045


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »