
Streamline Your Network Management: A Guide to Integrating LibreNMS with Oxidized
In modern network management, visibility is everything. While powerful tools like LibreNMS provide exceptional monitoring capabilities, and Oxidized offers robust configuration backup, they often operate in separate silos. This separation can complicate troubleshooting and obscure the direct link between a configuration change and a resulting performance issue.
By integrating LibreNMS with Oxidized, you can break down these silos and create a unified dashboard for network monitoring and configuration management. This powerful combination allows you to view device configurations, track changes, and compare versions directly within the LibreNMS interface, giving you a complete picture of your network’s health and history from a single pane of glass.
This guide will walk you through the straightforward process of connecting these two essential tools to streamline your workflow and enhance your operational efficiency.
Why Integrate LibreNMS and Oxidized?
Before diving into the technical steps, it’s important to understand the value this integration brings.
- Centralized Visibility: Access device configurations and their complete version history without ever leaving the LibreNMS web UI. No more switching between terminals or separate web interfaces.
- Simplified Change Tracking: Quickly identify what changed, who changed it, and when. The integration displays a clear “diff” view, highlighting additions and deletions between configuration versions.
- Faster Troubleshooting: When a device starts showing performance issues or goes down, you can immediately check the “Config” tab in LibreNMS to see if a recent change is the culprit. This correlates performance data with configuration changes, drastically reducing the time it takes to diagnose problems.
- Proactive Management: By easily reviewing configuration drift, you can enforce network standards and identify unauthorized or accidental changes before they cause a major outage.
Prerequisites
This guide assumes you have both LibreNMS and Oxidized installed and functioning correctly. Your LibreNMS instance should be successfully monitoring the network devices that Oxidized is backing up.
Step 1: Enable the API in Your Oxidized Configuration
For LibreNMS to fetch configuration data, you must first enable the REST API within Oxidized. This is done by editing the main Oxidized configuration file, which is typically located at ~/.config/oxidized/config.
Open the file and add the following rest block. If the block already exists, ensure it is configured correctly.
rest: 127.0.0.1:8888
This simple line tells Oxidized to start a web server API and listen for requests on port 8888 of the local machine (127.0.0.1). If LibreNMS and Oxidized are on different servers, you will need to change 127.0.0.1 to the server’s network IP address (0.0.0.0 to listen on all interfaces) and adjust your firewall rules accordingly.
Security Tip: For production environments, it is highly recommended to secure the API with SSL/TLS. This encrypts the communication between LibreNMS and Oxidized. To enable it, you will need an SSL certificate and private key. Your configuration would look like this:
rest: 127.0.0.1:8888
ssl:
key: /path/to/your/oxidized.key
cert: /path/to/your/oxidized.crt
After saving your changes, remember to restart the Oxidized service for the new configuration to take effect.
# Example command for systemd
sudo systemctl restart oxidized
Step 2: Configure LibreNMS to Connect to Oxidized
Next, you need to tell your LibreNMS installation how to connect to the newly enabled Oxidized API. This is done by adding a configuration block to your config.php file, which is located in the root of your LibreNMS installation (e.g., /opt/librenms/config.php).
Add the following lines to your config.php:
// Oxidized integration
$config['oxidized']['enabled'] = TRUE;
$config['oxidized']['url'] = 'http://127.0.0.1:8888';
$config['oxidized']['features']['versioning'] = true;
Let’s break down these settings:
$config['oxidized']['enabled'] = TRUE;: This line globally enables the integration within LibreNMS.$config['oxidized']['url']: This must be the full URL of your Oxidized API.- If you enabled SSL, change this to
https://127.0.0.1:8888. - If Oxidized is on a different server, use its IP address or hostname instead of
127.0.0.1.
- If you enabled SSL, change this to
$config['oxidized']['features']['versioning'] = true;: This is a crucial setting that enables the version history and diff-viewing features. Without it, you will only see the latest configuration.
If you have configured authentication or group support in Oxidized, you can add those settings here as well. For example:
$config['oxidized']['username'] = 'your_oxidized_user';
$config['oxidized']['password'] = 'your_oxidized_password';
$config['oxidized']['group_support'] = true;
Once you have added and saved the configuration, no service restart is needed for LibreNMS; the changes will be applied immediately.
Step 3: Verify the Integration
With both sides configured, verification is simple.
- Log in to your LibreNMS web interface.
- Navigate to the dashboard for any network device that is being backed up by Oxidized.
- Look at the navigation tabs for the device. You should now see a new tab labeled “Config”.
Clicking this tab will take you to a new page displaying the most recent configuration backup for that device. If you enabled versioning, you’ll see a history of backups with timestamps. You can select any two versions and click “Diff” to see a color-coded comparison of exactly what has changed—an incredibly powerful tool for diagnostics and auditing.
By following these steps, you have successfully transformed two separate network tools into a cohesive and integrated network management platform. This synergy not only saves time but also provides deeper insights, enabling a more proactive and intelligent approach to managing your network infrastructure.
Source: https://centlinux.com/librenms-oxidized-integration/


