Cannot delete trash.

I have a folder with other folders & files in it. I want it deleted.
When I empty trash it says permission denied.

11.1, Gnome.


wgcrowder

wgcrowder’s Profile: http://forums.opensuse.org/member.php?userid=19668
View this thread: http://forums.opensuse.org/showthread.php?t=405958

Open a terminal window (console), and become root with su command. Then
navigate to Trash directory, located in user’s home directory. Something
like:

cd /home/name_of_user/.local/share/Trash/

There are 2 directories contained here: ‘files’ and ‘info’. You can
either delete the directories and files with

rm -r * (take care to make sure you’re in right directory first)

or navigate to ‘files’ directory and remove the offending files with

rm -f …

(The directories get regenerated the next time files are moved to trash
anyway).


deano_ferrari

deano_ferrari’s Profile: http://forums.opensuse.org/member.php?userid=122
View this thread: http://forums.opensuse.org/showthread.php?t=405958

william@linux-rb3c:~> su
Password:
linux-rb3c:/home/william # cd/home/william/share/trash
bash: cd/home/william/share/trash: No such file or directory
linux-rb3c:/home/william # cd/home/william/.local/share/trash
bash: cd/home/william/.local/share/trash: No such file or directory
linux-rb3c:/home/william # cd /home/william/.local/share/Trash/
linux-rb3c:/home/william/.local/share/Trash # rm -1
rm: invalid option – ‘1’
Try `rm --help’ for more information.
linux-rb3c:/home/william/.local/share/Trash #


wgcrowder

wgcrowder’s Profile: http://forums.opensuse.org/member.php?userid=19668
View this thread: http://forums.opensuse.org/showthread.php?t=405958

You need to make sure you are in the correct directory first (and take
care with syntax). The

ls -a

command will show whats contained within a directory. If you see
‘files’ directory, then do

cd files

ls -a

Delete required directory with

rm -r 1 (rm -f … for files).


deano_ferrari

deano_ferrari’s Profile: http://forums.opensuse.org/member.php?userid=122
View this thread: http://forums.opensuse.org/showthread.php?t=405958

No, no it’s so confusing. Recursion, omg. :slight_smile:

@william, what you did here:
>
> william@linux-rb3c:~> su
> Password:
> …
> linux-rb3c:/home/william # cd /home/william/.local/share/Trash/
> linux-rb3c:/home/william/.local/share/Trash # rm -1
> rm: invalid option – ‘1’
> Try `rm --help’ for more information.
> linux-rb3c:/home/william/.local/share/Trash #
>
was absolutely right, so repeat it - some lines being removed they have
NO sense, so you don’t need to type them again.
Now make sure that you are in the right directory by typing:
Code:

ls

The output should be

Code:

1


if you can’t see this file, make sure that you have typed exactly the
same commands as before!
No remove the file with:

Code:

rm 1


this is a number - one - not a letter!


http://yami.googlecode.com/
http://akoskm.blogspot.com/

ram88’s Profile: http://forums.opensuse.org/member.php?userid=1058
View this thread: http://forums.opensuse.org/showthread.php?t=405958

wgcrowder;1933232 Wrote:
> the name of the folder is 1
>
>
> william@linux-rb3c:~> su
> Password:
> linux-rb3c:/home/william # cd/home/william/share/trash
> bash: cd/home/william/share/trash: No such file or directory
> linux-rb3c:/home/william # cd/home/william/.local/share/trash
> bash: cd/home/william/.local/share/trash: No such file or directory
> linux-rb3c:/home/william # cd /home/william/.local/share/Trash/
> linux-rb3c:/home/william/.local/share/Trash # rm -1
> rm: invalid option – ‘1’
> Try `rm --help’ for more information.
> linux-rb3c:/home/william/.local/share/Trash #
There are a lot of spaces missing in what you type!!!
Take care. When you would have copied/pasted the commands this would
not have been possible.

Also I would recommend all involved very strongly to use the CODE tags
around this sort of coding (like ram88 does) to make evry character
readable.


Henk van Velden

hcvv’s Profile: http://forums.opensuse.org/member.php?userid=180
View this thread: http://forums.opensuse.org/showthread.php?t=405958