22

I'm looking for a way to remove any trace of old coredumps in coredumpctl list. At the moment it lists coredumps beginning at 2014-12-14 - I've updated software so often between then and now that I doubt those old coredumps are going to help me debug any problems now. Unfortunately removing the files from /var/lib/systemd/coredump only made the asterisk in the "PRESENT" column of coredumpctls output disappear.

I couldn't find any way to remove all information about coredumps in the manpages or in the help output of coredumpctl.

5

It seems the metadata is kept in the systemd journal, so it is gone after

rm /var/log/journal/*/*
killall -9 systemd-journald

The downside is that all other syslog is gone as well.

Maybe the cleaner method would be the one given in How to clear journalctl

journalctl --vacuum-time=2d
  • 7
    It's not a solution. It's not even a workaround. It's an action that deletes all the logged stuff as well as the dumps. Not good! – EnzoR Dec 2 '18 at 11:24
2

First you may prune the journal discarding entries older than a day:

journalctl --vacuum-time=1d

Since "coredumpctl list" lists the dumpfiles recorded by the journal, you may manually delete the dump files from /var/lib/systemd/coredump that are not listed.

coredumpctl list

Browse the dump files, compare the files with the results from the command and delete the files not listed.

  • 5
    It's not a solution. It's not even a workaround. It's an action that deletes a lot of the logged stuff in the attempt to delete the dumps. Also not good! – EnzoR Dec 2 '18 at 11:25
  • Who ever wanted to build up a library of core dumps in the first place? You fix the bug and forget, right? – Adrian May Jul 20 at 8:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.