Dealing with the Trash

Today I decided to empty my trash and ran into the following error:



It turns out that there are some files with only root permissions in my trash:

bleonard@opensolaris:~/.Trash/OOo_2 (copy).4.1_Solarisx86_install_wJRE_en-US$ ls -l
total 25
drwxr-xr-x  2 bleonard staff     4 2008-05-29 15:40 licenses
drwxr-xr-x  3 root     root      5 2008-06-25 09:28 none
drwxr-xr-x 31 bleonard staff    31 2008-05-29 15:40 packages
-rwxr-xr-x  1 bleonard staff 13829 2008-05-29 15:40 setup
-rwxr-xr-x  1 bleonard staff  3925 2008-05-29 15:40 update
bleonard@opensolaris:~/.Trash/OOo_2 (copy).4.1_Solarisx86_install_wJRE_en-US$ ⁞

I'm not exactly sure how this came to be, but the problem is easy enough to fix if you find yourself in the same predicament. Simply open a terminal, which will place you in your home directory, and enter:

pfexec rm -r .Trash

There's no need to recreate the .Trash directory. It will be recreated the next time you move something to the Trash.

Comments:

Note that in more recent builds of OpenSolaris, the trash folder has moved to ~/.local/share/Trash, per the freedesktop.org Trash spec.

(Technically, it's $XDG_DATA_HOME/Trash, in fact.)

Posted by Calum on September 26, 2008 at 10:06 AM GMT #

Moving files to the trash seems so windozy. When I want to delete something, i just use 'rm'

Maybe I am weird.

Posted by Joseph Sniderman on December 25, 2008 at 05:41 PM GMT #

it doesnt work.it only says no such file or directory.

Posted by rennii on June 16, 2010 at 01:03 PM GMT #

The location of the Trash folder has moved to ~/.local/share/Trash.

Posted by Brian Leonard on June 16, 2010 at 01:45 PM GMT #

Post a Comment:
  • HTML Syntax: NOT allowed
About

The Observatory is a blog for users of Oracle Solaris. Tune in here for tips, tricks and more as we explore the Solaris operating system from Oracle.

Connect with Oracle Solaris:


Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today