23.2. Installing ABRT and Starting its Services

In order to use ABRT, ensure that the abrt-desktop or the abrt-cli package is installed on your system. The abrt-desktop package provides a graphical user interface for ABRT, and the abrt-cli package contains a tool for using ABRT on the command line. You can also install both. The general workflow with both the ABRT GUI and the command line tool is procedurally similar and follows the same pattern.

Warning

Please note that installing the ABRT packages overwrites the /proc/sys/kernel/core_pattern file, which can contain a template used to name core-dump files. The content of this file will be overwritten to:
|/usr/libexec/abrt-hook-ccpp %s %c %p %u %g %t e
See Section 8.2.4, “Installing Packages” for general information on how to install packages using the Yum package manager.

23.2.1. Installing the ABRT GUI

The ABRT graphical user interface provides an easy-to-use front end for working in a desktop environment. You can install the required package by running the following command as the root user:
~]# yum install abrt-desktop
Upon installation, the ABRT notification applet is configured to start automatically when your graphical desktop session starts. You can verify that the ABRT applet is running by issuing the following command in a terminal:
~]$ ps -el | grep abrt-applet
0 S   500  2036  1824  0  80   0 - 61604 poll_s ?        00:00:00 abrt-applet
If the applet is not running, you can start it manually in your current desktop session by running the abrt-applet program:
~]$ abrt-applet &
[1] 2261

23.2.2. Installing ABRT for the Command Line

The command line interface is useful on headless machines, remote systems connected over a network, or in scripts. You can install the required package by running the following command as the root user:
~]# yum install abrt-cli

23.2.3. Installing Supplementary ABRT Tools

To receive email notifications about crashes detected by ABRT, you need to have the libreport-plugin-mailx package installed. You can install it by executing the following command as root:
~]# yum install libreport-plugin-mailx
By default, it sends notifications to the root user at the local machine. The email destination can be configured in the /etc/libreport/plugins/mailx.conf file.
To have notifications displayed in your console at login time, install the abrt-console-notification package as well.
ABRT can detect, analyze, and report various types of software failures. By default, ABRT is installed with support for the most common types of failures, such as crashes of C and C++ applications. Support for other types of failures is provided by independent packages. For example, to install support for detecting exceptions in applications written using the Java language, run the following command as root:
~]# yum install abrt-java-connector
See Section 23.4, “Detecting Software Problems” for a list of languages and software projects which ABRT supports. The section also includes a list of all corresponding packages that enable the detection of the various types of failures.

23.2.4. Starting the ABRT Services

The abrtd daemon requires the abrt user to exist for file system operations in the /var/spool/abrt directory. When the abrt package is installed, it automatically creates the abrt user whose UID and GID is 173, if such user does not already exist. Otherwise, the abrt user can be created manually. In that case, any UID and GID can be chosen, because abrtd does not require a specific UID and GID.
The abrtd daemon is configured to start at boot time. You can use the following command to verify its current status:
~]$ systemctl is-active abrtd.service
active
If systemctl returns inactive or unknown, the daemon is not running. You can start it for the current session by entering the following command as root:
~]# systemctl start abrtd.service
You can use the same commands to start or check status of related error-detection services. For example, make sure the abrt-ccpp service is running if you want ABRT to detect C or C++ crashes. See Section 23.4, “Detecting Software Problems” for a list of all available ABRT detection services and their respective packages.
With the exception of the abrt-vmcore and abrt-pstoreoops services, which are only started when a kernel panic or kernel oops occurs, all ABRT services are automatically enabled and started at boot time when their respective packages are installed. You can disable or enable any ABRT service by using the systemctl utility as described in Chapter 9, Managing Services with systemd.

23.2.5. Testing ABRT Crash Detection

To test that ABRT works properly, use the kill command to send the SEGV signal to terminate a process. For example, start a sleep process and terminate it with the kill command in the following way:
~]$ sleep 100 &
[1] 2823
~]$ kill -s SEGV 2823
ABRT detects a crash shortly after executing the kill command, and, provided a graphical session is running, the user is notified of the detected problem by the GUI notification applet. On the command line, you can check that the crash was detected by running the abrt-cli list command or by examining the crash dump created in the /var/tmp/abrt/ directory. See Section 23.5, “Handling Detected Problems” for more information on how to work with detected crashes.