Handle crashes of your applications automatically and debug with ease!
ABRT (Automatic Bug Reporting Tool) is a set of tools to help users detect and report application crashes. It’s main purpose is to ease the process of reporting an issue and finding a solution.
ABRT can also be a valuable tool in developer’s toolbox, helping with collecting and debugging crashes in various programming languages.
Coupled with FAF (Fedora Analysis Framework) it provides extensive statistics about crashes of your application over its complete life cycle.
ABRT is installed by default on most Fedora spins. You can verify its
functionality by forcefully crashing an application of your choice. We choose
sleep as our victim for demonstration purposes. Following commands
sleep in background and then kill it with
SIGSEGV signal to produce
sleep 10m & kill -SIGSEGV $!
When ABRT handles a crash you will get notified via desktop pop-up or console notification
abrt-console-notification package is installed. You can then investigate the
gnome-abrt GUI application or use
abrt-cli when working from console.
It is always a good idea to test the ABRT functionality for applications you are developing or maintaining in Fedora. If you are building your own RPMs you might have to enable handling of non-GPG signed software. In case ABRT failed to handle crash of your application consult troubleshooting section of ABRT project documentation.
If the crashing application is part of Fedora you can leverage reporting to Fedora hosted FAF instance and Red Hat Bugzilla. This is one of the advantages of having a package included in official Fedora repositories that allows developers and maintainers to receive bug reports from users of their application.
Available since Fedora 23 is the new ABRT CLI tailored specifically for developers.
It is part of a
abrt-cli-ng package and can be installed with:
$ sudo dnf install abrt-cli-ng
CLI is then available as
abrt executable, try running it on your system:
By default it lists crashes that belong to currently logged-in user. To get detailed
information about a last crash use
$ abrt info
bash-completion is installed on your system, the CLI can use it to complete
hashes of problems or package names for its subcommands:
$ abrt backtrace <TAB>
If the last parameter specifying problem to use is omitted subcommand will work with the last problem that occurred on the system.
To run GDB against a last problem use:
$ abrt gdb
To install debuginfo packages for the affected package use
$ abrt debuginfo-install
These two can be combined to automatically install debuginfo packages prior running gdb with:
$ abrt gdb --debuginfo-install
To get the full list of commands and options use
$ abrt --help
$ abrt <subcommand> --help
Refer to ABRT project documentation for more information and configuration examples.