You are not logged in.

#1 2013-08-16 20:53:50

Strychnine
Member
Registered: 2013-06-01
Posts: 15

[SOLVED] trash located in /

Hi,

I'm new to arch, and I'm experiencing an issue with the trash.

At one point, I had to delete some files, but Dolphin give me a message saying that the trash had reached it's maximum size. So, I've empty it, and try to delete my files again.
Dolphin give me the same error.
I've made some research, and read on some forum that I should try to delete the ~/.local/share/Trash/metadata files.
It doesn't work. An another post said that I should try to delete the whole Trash folder.
It doesn't work, I still had the Dolphin error.
An another forum said to set the trash to "no maximum size" and set Dolphin to clean it up every 7 days.
And in the setting I've see that my trash is now located in /, and I cannot delete any files.

What should I do to get my trash back at ~/.local/share/Trash?
And where can I set Dolphin to empty it each week?

Please forgive me for any english mistake, but I'm french.

Last edited by Strychnine (2013-08-17 02:17:45)

Offline

#2 2013-08-16 21:13:02

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

I've got some news:
I've try (by right clicking on the "trash" shorcut in dolphin) to set the path of the trash to ~/.local/share/Trash/, then to ~/.local/share/Trash/files, but I've got the same issue for both: an other Trash shorcut appears in Dolphin, and when I try to delete one of those, it come back.
And when I try to delete a files, Dolphin crash, or the whole WM. And of course my files didn't get deleted.

Offline

#3 2013-08-16 22:11:46

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

Welcome to Arch's forums.

I would make sure Dolphin is closed and then arrange things at the command line as you wish before restarting Dolphin.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#4 2013-08-16 22:14:11

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

ok, I'll try, but can you give me the doc for setting up by command lines?

Offline

#5 2013-08-16 22:27:23

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

I really just meant mv things and create the directories you want.

However, I would also suggest

mv -n .kde4/share/config/ktrashrc ~/ktrashrc.bkup

You might need to log out and back in in this case - I'm not sure.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#6 2013-08-16 22:44:26

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

ok, so I'm probably a dick, 'cause I run your command, I log out, but it doesn't change at all.
I open the ktrashrc file, and every thing in it is exactly as I want.
What do I need to do then?

Offline

#7 2013-08-16 22:50:46

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

Do the directories you want to use for Trash exist now? That is, did you create them OK?

The reason I suggested ktrashrc was that it was the only file I could find that mentioned the path to Trash. However, it is possible that because yours is set to non-default that it is showing up somewhere else. Have a look at the files under ~/.kde4/share/apps/dolphin and ~/.kde4/share/apps/dolphinpart.

Otherwise, to test whether it is something in your kde config, you can log out of kde, switch to a tty and move ~/.kde4 to ~/kde4.bkup. This will essentially destroy all of your customisations which may or may not be a pain depending on how customised your setup is. However, if it solves the problem, you can then try to figure out what in that directory is the problem. If not, you can log out again, restore your backup and look elsewhere.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#8 2013-08-16 23:07:13

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

I've try all your suggestions, and badly, doesn't work.
first, I do not have any ~/.kde4/share/apps/dolphinpart subfolders, and nothing in ~/.kde4/share/apps/dolphin help.
I've try to switch .kde4/ to .kde4.bkup, then log out and log in, but... when I try to delete somethings, Dolphin say that the Trash need to be cleaned.

Offline

#9 2013-08-16 23:14:31

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

So can you clean it?

Let's step back. What makes you think Trash is at /?

What does ls -al ~/.local/share/Trash give?

EDIT: Dolphin > Settings > Configure Dolphin > Wastebin

I just managed to empty my trash with some difficulty - lots of visits to the command line, basically. I can't say I think much of Dolphin's implementation of this feature. Sort of undermines the point of having a GUI in the first place.

Last edited by cfr (2013-08-16 23:23:14)


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#10 2013-08-16 23:36:34

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

in dolphin settings, there an option to choose the path of the trash:

http://www.noelshack.com/2013-33-1376695947-snapshot1.png]1376695947-snapshot1.png

and still in dolphin, if you right click on the trash shortcut it give:


http://www.noelshack.com/2013-33-1376695947-snapshot2.png]1376695947-snapshot2.png

ls -al ~/.local/share/Trash give

[eol@Alya ~]$ ls -al ~/.local/share/Trash
total 20
drwx------  4 eol wheel 4096 Aug 16 22:25 .
drwxr-xr-x 13 eol wheel 4096 Aug 17 01:10 ..
drwx------  2 eol wheel 4096 Aug 16 22:24 files
drwx------  2 eol wheel 4096 Aug 16 22:24 info
-rw-r--r--  1 eol wheel   16 Aug 16 22:25 metadata

Offline

#11 2013-08-16 23:49:45

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

Sorry but I cannot read the details in those pictures.

However, your Trash should certainly not be owned by wheel. Assuming eol is your username, it should be owned by either eol:eol (if you use user groups) or, probably, eol:users (if you don't).

sudo chown -R eol:<eol or users or whatever is appropriate> ~/.local/share/Trash

Last edited by cfr (2013-08-16 23:50:40)


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#12 2013-08-16 23:52:10

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Offline

#13 2013-08-17 00:00:50

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

Those pictures show nothing wrong. It just shows each partition for which there is a trash file. I don't have / because I use a separate home partition but I have /home. And I have trash:/ in the other picture.

The problem is the ownership of ~/.local/share/Trash.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#14 2013-08-17 00:07:51

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

Ok...

but after the chown command, ls -al ~/.local/share/Trash give

[eol@Alya ~]$ ls -al ~/.local/share/Trash     
total 20
drwx------  4 eol users 4096 Aug 16 22:25 .
drwxr-xr-x 13 eol wheel 4096 Aug 17 02:03 ..
drwx------  2 eol users 4096 Aug 16 22:24 files
drwx------  2 eol users 4096 Aug 16 22:24 info
-rw-r--r--  1 eol users   16 Aug 16 22:25 metadata

and I still can't delete files, it keep saying that the trash has reach its maximum size

Offline

#15 2013-08-17 00:16:26

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

Why are large parts of your home directory owned by eol:wheel rather than eol:users? That output shows that ~/.local/share is owned by eol:wheel.

You need to figure out what or who changed the ownership and which bits of your home directory are affected so that you can undo the damage. Something like

ls -lR ~/ | grep wheel

will give you an idea but only change stuff if you are sure. chowning .local recursively should be fine, at least.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#16 2013-08-17 00:18:57

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

hum. Creepy shit. that's like my whole home directory is owned by wheel...

Should I change the whole directory to eol:users?

Offline

#17 2013-08-17 00:29:33

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

You mean your entire home directory is like that?

Hmm. I'm reluctant to say change it all in case there's anything which should have different ownership. I think changing it would be fine but I'm just not confident enough.

I just realised that you don't probably need sudo to run that command. That is

chown -R eol:users <directory>

should work.

Parts of my home directory have messed up permissions and/or ownership and other parts have non-messed-up but non-standard ownership so it is hard for me to know what is "normal". I think running it without sudo should be relatively safe because you can't change the ownership of anything not owned by your uid that way - all you are changing is the gid. But if you want to be really sure wait until somebody else comments before deciding.

EDIT: The messed up bits of my home directory are messed up for known, non-creepy reasons. I know why they are like that, in other words. (Basically I dumped stuff from another OS and haven't dealt with it all yet.)

Last edited by cfr (2013-08-17 00:31:22)


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#18 2013-08-17 00:35:12

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

I've made the change, and exept some files i've put while logged as root, there were no error. As I didn't need the root's files, I've machinally tried to deleted it. Work.
So I've try to delete my others files (that are owned by eol and wheel) but it didn't work.

EDIT: Is there a reason for everything owned by eol is also owned by wheel? Maybe I made a mistake by putting eol in the wheel group, and messing up everythings?

Last edited by Strychnine (2013-08-17 00:38:22)

Offline

#19 2013-08-17 00:47:05

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

Strychnine wrote:

So I've try to delete my others files (that are owned by eol and wheel) but it didn't work.

Try changing the ownership first.

EDIT: Is there a reason for everything owned by eol is also owned by wheel? Maybe I made a mistake by putting eol in the wheel group, and messing up everythings?

Only you can know the reason wink.

It isn't a mistake to be in wheel but it should not be your primary group. What does

id

give?


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#20 2013-08-17 00:49:21

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

id give e

uid=1000(eol) gid=10(wheel) groups=10(wheel),6(disk),7(lp),50(games),91(video),92(audio),93(optical),94(floppy),95(storage),98(power),100(users)

So, if I want to delete files, I need to quit the wheel group?

Offline

#21 2013-08-17 01:04:57

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

Actually, I have no idea because I have no idea what setting your primary group as wheel might be. That is really not a good way to do things. You should have users as your primary group. You don't need to quit the wheel group - you just don't want it to be primary. That is, you don't want files and directories to be owned by eol:wheel by default when you create them.

I don't honestly know what you should best do at this point.

find .config -uid 1000 -gid 10 | xargs chown eol:users

would correct the ownership on everything in ~/.config, for example. (You will probably have too many files to do this on all of your home at once.) I'm not sure this is the best way...

Then you will also need to modify your user to change your primary group to users. usermod -g can be used to do this - see usermod --help for details.

By the way, you shouldn't be in all those groups with systemd - it can cause weird problems. The only ones you probably want are users and wheel.

I don't know this will solve the trash problem but it should help avoid more serious issues such as security problems.

Last edited by cfr (2013-08-17 01:06:17)


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#22 2013-08-17 01:10:17

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

ok thank you ^^

I've try to change the ownership of my others folders, but it doesn't help...
I'm going to re-read the wiki on the groups, it could be helping, and maybe after the settings for the groups, it going to work again

thank you a lot for all your help

Offline

#23 2013-08-17 02:04:23

Strychnine
Member
Registered: 2013-06-01
Posts: 15

Re: [SOLVED] trash located in /

It seems to be working since i've put my primary group to users
thank you a lot again cfr

Offline

#24 2013-08-17 02:16:14

cfr
Member
From: Cymru
Registered: 2011-11-27
Posts: 7,134

Re: [SOLVED] trash located in /

Glad to hear that. Don't forget to mark your thread solved as explained here. Thanks.


CLI Paste | How To Ask Questions

Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L

Offline

#25 2013-08-22 12:06:34

DaveCode
Member
Registered: 2008-08-15
Posts: 103

Re: [SOLVED] trash located in /

Dolphin trash weirdness is the FreeDesktop trash spec. I had thought my custom XDG vars put trash in tmpfs, but no.

A mounted partition can win a trash folder in its top directory like /Partition/.Trash-NNNN where NNNN is $UID. The rule for the system partition differs, following XDG vars. At least that was the info I gleaned at a quick glance.

FreeDesktop has good rationale for quick delete with top trash folders like that, but Dolphin could still tell us where trashed files live.

The Trash config dialog is cryptic. It justs lists partitions. Even at console you need to read the FreeDesktop site and fish around. Maybe this trash topic belongs on the wiki to help people. It's not limited to Dolphin or KDE. It's FreeDesktop mystery.

I feel like I'm in Mac OS X now, which scribbles hidden dotfiles on every USB stick....and I hope akonadi-fake holds up indefinitely, so far so good....all that nepomuckraking is also dechecked on purpose...crossing fingers....

Offline

Board footer

Powered by FluxBB