You are not logged in.

#1 2024-01-25 06:02:21

YAOMTC
Member
Registered: 2010-02-23
Posts: 207

`systemd-tmpfiles --clean` not removing core dumps [SOLVED]

Why would `systemd-tmpfiles --clean` not remove files from `/var/lib/systemd/coredump/`? There's 2.4 GB of files in there and that command has no affect on them

It says it will clean up "marked directories". Looking this up leads me to `tmpfiles.d`, and one of those locations is  `/usr/lib/tmpfiles.d/` where `systemd-tmp.conf` lists the coredump folder as one to clean up... There's files going back to the 13th, that's 11 days ago, quite a bit more than the 3 days they're supposed to stick around.

Journal has this:

Jan 14 22:26:16 archlinux systemd[1]: Starting Cleanup of Temporary Directories...
Jan 14 22:26:16 archlinux systemd[1]: systemd-tmpfiles-clean.service: Deactivated successfully.
Jan 14 22:26:16 archlinux systemd[1]: Finished Cleanup of Temporary Directories.

and,

Jan 15 03:53:02 archlinux systemd[1]: systemd-tmpfiles-clean.timer: Deactivated successfully.
Jan 15 03:53:02 archlinux systemd[1]: Stopped Daily Cleanup of Temporary Directories.

and,

Jan 15 11:34:41 archlinux systemd[1]: Starting Cleanup of Temporary Directories...
Jan 15 11:34:42 archlinux systemd[1]: systemd-tmpfiles-clean.service: Deactivated successfully.
Jan 15 11:34:42 archlinux systemd[1]: Finished Cleanup of Temporary Directories.

and,

Jan 16 08:46:09 archlinux systemd[1]: Starting Cleanup of Temporary Directories...
Jan 16 08:46:09 archlinux systemd[1]: systemd-tmpfiles-clean.service: Deactivated successfully.
Jan 16 08:46:09 archlinux systemd[1]: Finished Cleanup of Temporary Directories.

But /var/lib/systemd/coredump/ is supposed to be one of those temporary directories, right?

Last edited by YAOMTC (2024-02-07 09:05:33)

Offline

#2 2024-01-26 15:02:22

pebcak
Member
Registered: 2020-08-11
Posts: 18

Re: `systemd-tmpfiles --clean` not removing core dumps [SOLVED]

YAOMTC wrote:

Looking this up leads me to `tmpfiles.d`, and one of those locations is  `/usr/lib/tmpfiles.d/` where `systemd-tmp.conf` lists the coredump folder as one to clean up

But /var/lib/systemd/coredump/ is supposed to be one of those temporary directories, right?

The line in the systemd-tmp.conf is "prefixed" by r!: r! /var/lib/systemd/coredump/.#*

This is what man tmpfiles.d says:

If the exclamation mark ("!") is used, this line is only safe to execute during boot, and can break a running system. Lines without the exclamation mark are presumed to be safe to execute at any time, e.g. on package upgrades.
       systemd-tmpfiles(8) will take lines with an exclamation mark only into consideration, if the --boot option is given.

So you might need to do some research on the options.

I haven't used this tool myself so I am afraid I cannot be of more help.

Offline

#3 2024-01-27 17:18:46

YAOMTC
Member
Registered: 2010-02-23
Posts: 207

Re: `systemd-tmpfiles --clean` not removing core dumps [SOLVED]

Might it be because I set up Arch using archinstall? I didn't set up any of these timers and didn't know about this tool running in the background until now.

Offline

#4 2024-02-07 09:05:17

YAOMTC
Member
Registered: 2010-02-23
Posts: 207

Re: `systemd-tmpfiles --clean` not removing core dumps [SOLVED]

Now the newest files in that directory are from January 27. Still quite a bit older than the 3 days mentioned here, but given there's files that have since been cleaned up, I'm going to assume that's out of date.

Offline

Board footer

Powered by FluxBB