Apport is the default crash reporting system in Ubuntu. When an application, background service, or kernel module crashes, the Apport daemon intercepts the core dump, gathers extensive system telemetry (including memory states, log files, and package versions), and prepares an error report to be sent to Canonical. While this telemetry is invaluable for Ubuntu’s developers to identify and patch bugs, it is often highly undesirable in a production server environment. Generating massive core dumps consumes significant CPU cycles and disk I/O, which can exacerbate the impact of the crash. Furthermore, automatically packaging memory dumps poses a severe data privacy risk, as they may contain plaintext passwords, API keys, or customer data.
This guide explains how to completely disable the Apport daemon in Ubuntu Server, preventing it from intercepting crashes and generating error reports.
Disable Apport via its Configuration File
The most correct and persistent way to disable Apport is by modifying its primary configuration file. This ensures the daemon respects your wishes even across package updates.
- Log into your Ubuntu Server via SSH or local console with
sudoprivileges. - Open the Apport configuration file in your preferred text editor (like
nano):sudo nano /etc/default/apport - Look for the line that says
enabled=1. This single parameter controls whether the service runs. - Change the
1to a0, so the line reads exactly:enabled=0 - Save the file and exit the editor (in nano, press
Ctrl+O,Enter, thenCtrl+X).
Stop and Mask the Systemd Service
While altering the configuration file is usually sufficient, you should also manually stop the currently running daemon and explicitly mask it in systemd to ensure it never wakes up again.
- Stop the active Apport service:
sudo systemctl stop apport.service - Disable it from starting on boot:
sudo systemctl disable apport.service - Mask the service to completely paralyze it, preventing it from being triggered by dependencies:
sudo systemctl mask apport.service
Your Ubuntu Server is now free from the overhead and privacy risks of automated crash reporting. If an application crashes, it will simply terminate normally, leaving only a standard entry in the system journal rather than generating a massive, resource-intensive core dump.