Uninstall Observium Ubuntu đź’Ž
First, stop the web server and the poller services to prevent data corruption or processes interfering with the removal.
# Stop Apache (or Nginx if you used that)
sudo systemctl stop apache2
sudo systemctl disable apache2
# Stop the Observium poller service (if configured as a systemd service)
sudo systemctl stop observium
sudo systemctl disable observium
If you installed Observium-specific packages like rrdtool, snmpd, fping, and you no longer need them:
sudo apt remove --purge snmpd rrdtool fping mysql-server apache2 php*
sudo apt autoremove --purge
Be cautious — this may remove other services if they share dependencies.
RRDtool and SNMP tools are heavy dependencies. If you installed them solely for Observium, you can remove them:
sudo apt purge rrdtool snmp snmpd
But verify that no other monitoring system needs them.
That covers a thorough, end-to-end uninstall of Observium on Ubuntu. If you want, tell me your Observium path, PHP version, and whether you used MySQL/MariaDB and Apache or Nginx, and I’ll generate exact commands tailored to your system.
To uninstall Observium from Ubuntu, you need to manually remove its directory, database, and configuration files, as it is typically installed via a tarball rather than a standard package manager. 1. Stop Services and Remove Cron Jobs
Before deleting files, stop the services and remove the automated polling tasks:
Cron Jobs: Remove the Observium cron file to stop background polling:sudo rm /etc/cron.d/observium
Web Server: Disable the Observium site configuration (assuming you named it observium.conf):sudo a2dissite observium.confsudo systemctl reload apache2 2. Delete the Installation Directory
The default installation directory is usually /opt/observium. Remove this directory to delete the application files and RRD data: sudo rm -rf /opt/observium 3. Drop the Database
Remove the MariaDB/MySQL database and the associated user. Log into your database: sudo mysql -u root -p
Run the following commands inside the MySQL prompt:DROP DATABASE observium;DROP USER 'observium'@'localhost';FLUSH PRIVILEGES;EXIT; 4. Remove Logs and Dependencies (Optional)
If you no longer need the logs or specific packages installed just for Observium: Logs: sudo rm /var/log/apache2/observium*
Dependencies: If you want to remove the web server and PHP (be careful if other apps use them), you can use APT purge:sudo apt-get purge apache2 mariadb-server php*sudo apt autoremove
For more detailed guidance on managing Ubuntu software, you can refer to the official Ubuntu Documentation. Remove an application - Ubuntu Documentation
The Uninstall
It started, as these things often do, with a single red alert at 3:14 AM.
Leo, the sole systems administrator for a modest but growing cloud startup, fumbled for his phone. The glow of the screen illuminated his tired face. Observium, the network monitoring tool he’d lovingly installed on an Ubuntu server three years ago, was screaming that a core switch was down.
He stumbled to his home office, logged in, and realized the truth: the switch was fine. Observium was lying.
That was the first crack. Over the next week, more cracks appeared. The graphs for memory usage flatlined. The auto-discovery feature, once a marvel, now identified servers as "unknown device (generic)." The web interface took forty-five seconds to load. Upgrading it—a task involving a labyrinth of ./discovery.php and ./poller.php commands—failed with a PHP dependency error so cryptic it felt like a personal insult.
The final straw came when Leo’s boss, Jenna, asked for a simple bandwidth report for a client. Leo spent two hours trying to extract a clean CSV from Observium’s MySQL database, only to get data that showed negative packets transmitted.
"We need a new solution," Jenna said, not unkindly. "Can you remove the old one?"
"Remove," Leo repeated. The word felt heavier than "uninstall." It meant admitting failure. It meant confronting the ghost of his past self—the eager junior admin who had followed a quickstart guide with religious fervor, pasting commands without truly understanding them.
"By Friday," Jenna added, and walked away.
Friday arrived like a storm front. Leo sat before the terminal, the cursor blinking on a cold, gray afternoon. The server, affectionately named monitor.internal, hummed quietly in the rack.
He took a deep breath. Then, he began.
His first instinct was the nuclear option. sudo apt remove observium. He typed it, heart pounding. The terminal whirred, thought for a moment, and replied:
Package 'observium' is not installed, so not removed.
Of course. He hadn't used apt. He’d compiled it from source, following a blog post titled "The Ultimate Network Monitoring Guide (2019)." The guide had made him feel like a wizard. Now, it made him feel like an archaeologist.
He opened his old notes. The installation path was /opt/observium. The web root had a symlink: /var/www/html/observium. The database was called observium_db. The cron job ran poller.php every five minutes. It was a mess of his own making.
Step one was to stop the bleeding. He disabled the cron job:
sudo crontab -u www-data -l > old_cron.txt
sudo crontab -u www-data -r
The poller fell silent. A small victory. uninstall observium ubuntu
Step two was to unplug the web interface. He removed the symlink:
sudo rm /var/www/html/observium
He reloaded Apache. The old dashboard, with its dead graphs and red alerts, was gone. A generic "404 Not Found" page stared back at him. It was peaceful.
Step three was the database. He logged into MySQL with trembling fingers.
DROP DATABASE observium_db;
DROP USER 'observium'@'localhost';
FLUSH PRIVILEGES;
The database vanished in a whisper. Thousands of data points, three years of history—gone. He felt a strange pang, like deleting a save file for a game he no longer played.
Step four was the purge. The actual files.
sudo rm -rf /opt/observium
He watched the directories scroll by: rrd/, logs/, includes/, html/. All those custom alerts he’d written. All those graphs he’d tweaked. All gone.
He checked for leftovers. Configuration files? sudo find / -name "*observium*" -type f 2>/dev/null. A few old logrotate snippets in /etc/logrotate.d/. He deleted those too. He checked PHP modules he’d installed specifically for Observium—php7.4-mysqlnd, php7.4-snmp. He left them for now. No need to break other things.
Finally, he ran sudo apt autoremove to clean up orphaned packages. A library called libsnmp-dev was removed. He didn't even know what that was for.
He rebooted the Ubuntu server.
When it came back up, the terminal was clean. htop showed CPU usage at 2%. Memory was mostly free. The server was quiet. It was just an Ubuntu box again, waiting for its next purpose.
Leo leaned back in his chair. He felt lighter. The frantic red alerts, the sluggish interface, the nagging dread of an unsupported, decaying system—all of it was gone. He had not just uninstalled a program. He had exorcised a ghost.
He opened a fresh terminal window and typed:
sudo apt update
sudo apt install prometheus node-exporter grafana
The new future began to install.
And for the first time in months, Leo smiled.
How to Completely Uninstall Observium from Ubuntu Whether you are migrating to a different monitoring solution or simply cleaning up your server, uninstalling Observium requires more than just removing a few files. Because Observium relies on a stack of dependencies—including a web server, a database, and several PHP modules—a proper cleanup ensures no orphan processes or security holes are left behind.
This guide will walk you through the process of stopping the services, removing the application files, and dropping the associated databases. Step 1: Stop the Observium Cron Jobs First, stop the web server and the poller
Observium relies heavily on cron jobs for polling and discovery. If you don't disable these first, the system will continue trying to run scripts that you are about to delete, leading to a flood of local error logs. Open the cron configuration: sudo nano /etc/cron.d/observium Use code with caution.
If the file exists, delete its contents or simply remove the file entirely: sudo rm /etc/cron.d/observium Use code with caution. Step 2: Remove the Web Server Configuration
You likely have an Apache or Nginx virtual host pointing to your Observium directory. You should disable and remove this to prevent the web server from throwing errors. For Apache: Disable the site: sudo a2dissite observium.conf Use code with caution. Restart Apache: sudo systemctl restart apache2 Use code with caution. Delete the configuration file: sudo rm /etc/apache2/sites-available/observium.conf Use code with caution. For Nginx: Remove the symbolic link: sudo rm /etc/nginx/sites-enabled/observium Use code with caution. Restart Nginx: sudo systemctl restart nginx Use code with caution. Remove the site config: sudo rm /etc/nginx/sites-available/observium Use code with caution. Step 3: Drop the MySQL/MariaDB Database
Observium stores all your historical data and device information in a database. To remove it: Log into your database server: sudo mysql -u root -p Use code with caution. Identify the database name (usually observium) and drop it: DROP DATABASE observium; Use code with caution.
(Optional) Remove the specific database user created for Observium: DROP USER 'observium'@'localhost'; FLUSH PRIVILEGES; EXIT; Use code with caution. Step 4: Delete the Observium Files
Now that the services are disconnected, you can remove the actual application directory. By default, Observium is installed in /opt/observium. sudo rm -rf /opt/observium Use code with caution.
Warning: This command is permanent. Ensure you have backed up any custom templates or configurations if you plan to use them elsewhere. Step 5: Clean Up Dependencies (Optional)
If Observium was the only application on this server using certain packages (like SNMP tools or specific PHP modules), you might want to remove them to save space.
Note: Be careful with this step if you have other websites or tools running on the same Ubuntu instance.
sudo apt-get purge snmp snmpd fping ImageMagick sudo apt-get autoremove Use code with caution. Step 6: Verify Removal
Finally, check that no Observium-related processes are still running: ps aux | grep observium Use code with caution.
If the output is empty (aside from your grep command), the uninstallation is successful. Summary Checklist Cron jobs deleted Apache/Nginx virtual host removed MySQL database and user dropped /opt/observium directory deleted Unused packages purged
Are you planning to replace Observium with another monitoring tool like LibreNMS or Zabbix, or are you decommissioning the server entirely?
Uninstalling Observium from an Ubuntu system requires a manual process because it is typically installed by extracting a tarball and setting up services rather than using a standard package manager like apt. Review of Uninstallation Steps
To completely remove Observium and its associated components, follow these steps: Install Observium on Debian/Ubuntu
Ignore these—they simply confirm the packages are already removed. If you installed Observium-specific packages like rrdtool ,
If you want to remove packages that were installed specifically for Observium:
sudo apt-get remove --purge apache2 mysql-server php7.4 php7.4-cli php7.4-mysql php7.4-gd php7.4-snmp php7.4-curl snmp fping graphviz rrdtool
Warning: This will remove Apache and MySQL entirely. Only run this if you don't need these services for other applications.