linuxcore-file

Cannot locate core file with abrt-hook-cpp installed


I've been led to understand that if abrt-ccpp.service is installed on a Linux PC, it supersedes/overwrites (I've read both, not sure which is true) the file /proc/sys/kernel/core_pattern, which otherwise specifies the location and filename pattern of core files.

Question:

When I execute systemctl, why does abrt-ccpp.service report exited under the SUB column? I don't understand the combination of active and exited: is the service "alive"/active/running or not?

> systemctl
UNIT                 LOAD   ACTIVE SUB
abrt-ccpp.service    loaded active exited ...

Question:

Where are core files generated? I wrote this program to generate a SIGSEGV:

#include <iostream>

int main(int argc, char* argv[], char* envz[])
{
  int* pInt = NULL;
  std::cout << *pInt << std::endl;
  return 0;
}

Compilation and execution as follows:

> g++ main.cpp
> ./a.out
Segmentation fault (core dumped)

But I cannot locate where the core file is generated.

What I have tried:

...

# Specify where you want to store coredumps and all files which are needed for
# reporting. (default:/var/tmp/abrt)
#
# Changing dump location could cause problems with SELinux. See man_abrt_selinux(8).
#
#DumpLocation = /var/tmp/abrt

...

I am out of ideas of what else to try and where else to look.

In case helpful, this is the content of my /proc/sys/kernel/core_pattern:

> cat /proc/sys/kernel/core_pattern
|/usr/libexec/abrt-hook-ccpp %s %c %p %u %g %t e

Can someone help explain how the abrt-hook-ccpp service works and where it generates core files? Thank you.


Solution

  • I'd like to credit https://unix.stackexchange.com/users/119298/meuh who answered this at https://unix.stackexchange.com/questions/343240/cannot-locate-core-file-with-abrt-hook-cpp-installed.

    The answer was to add this line in file /etc/abrt/abrt-action-save-package-data.conf

    ProcessUnpackaged = yes
    

    The comment from @daniel-kamil-kozar was also a viable workaround.