Skip to main content

NetBox LibreNMS Plugin

The NetBox LibreNMS Plugin enables integration between NetBox and LibreNMS, allowing you to leverage data from both systems. NetBox remains the Source of Truth (SoT) for you network, but this plugin allows you to easily onboard device objects from existing data in LibreNMS. The plugin does not automatically create objects in NetBox to ensure only verified data is used to populate NetBox.

Ask DeepWiki

Features

The plugin offers the following key features:

Device Import

Search and import devices from LibreNMS into NetBox with comprehensive validation and control:

  • Filter devices by location, type, OS, hostname, or system name
  • Validate import prerequisites (Site, Device Type, Device Role)
  • Smart matching for Sites, Device Types, and Platforms
  • Import as physical Devices or Virtual Machines
  • Bulk import multiple devices
  • Automatic Virtual Chassis creation for stackable switches
  • Background job processing for large device sets

See the Device Import Guide for detailed usage instructions.

Device Field Sync

Synchronize device information from LibreNMS to NetBox. The following device fields can be synchronized:

  • Device Name (with naming preference support)
  • Serial Number (including virtual chassis members)
  • Device Type
  • Platform

Interface Sync

Pull interface data from Devices and Virtual Machines from LibreNMS into NetBox. The following interface attributes are synchronized:

  • Name
  • Description
  • Status (Enabled/Disabled)
  • Type (with custom mapping support)
  • Speed
  • MTU
  • MAC Address
  • VLAN (Tagged and untagged)

Set custom mappings for interface types to ensure that the correct interface type is used when syncing from LibreNMS to NetBox.

Cable Sync

Create cable connection in NetBox from LibreNMS links data.

IP Address Sync

Create IP address in NetBox from LibreNMS device IP data.

VLAN Sync

  • Create VLAN objects in NetBox from LibreNMS device VLAN data
  • Per-VLAN group assignment with scope-aware auto-selection

Add device to LibreNMS from Netbox

  • Add device to LibreNMS from Netbox device page. SNMP v2c and v3 are supported.

Site & Location Synchronization

The plugin also supports synchronizing NetBox Sites with LibreNMS locations:

  • Compare NetBox sites to LibreNMS location data
  • Create LibreNMS locations to match NetBox sites
  • Update existing LibreNMS locations latitude and longitude values based on NetBox data ⚠️ (currently not working due to LibreNMS API issue)
  • Sync device site to LibreNMS location

Multi LibreNMS Server Configuration

  • Configure multiple LibreNMS instances in your NetBox configuration
  • Switch between different LibreNMS servers through the web interface
  • Maintain backward compatibility with single-server configurations

Screenshots/GIFs

Screenshots from older plugin version

Site & Location Sync

Site Location Sync

Sync devices and Interfaces

Add device and interfaces

Virtual Chassis Member Select

Virtual Chassis Member Selection

Interface Type Mappings

Interfaces Type Mappings

Contributing

There's more to do! Coding is not my day job. Bugs will exist and improvements will be needed. Contributions are very welcome! I've got more ideas for new features and improvements but please contribute if you can!

Development Environment

An easy way to get started with development is to use the included development container:

  • Local Development: Open the project in VS Code and choose "Reopen in Container"
  • GitHub Codespaces: Click "Code" → "Create codespace" in the GitHub repository
  • Ready in 5 minutes: A complete NetBox environment with PostgreSQL, Redis, and the plugin pre-installed

📖 See the Dev Container README for detailed setup instructions, available commands, and troubleshooting.

Alternatively, share your ideas for the plugin over in discussions.

Compatibility

NetBox Version Plugin Version
4.1 0.2.x - 0.3.5
4.2 - 4.5 0.3.6+

Installing

Standard Installation

Activate your virtual environment and install the plugin:

source /opt/netbox/venv/bin/activate

Install with pip:

(venv) $ pip install netbox-librenms-plugin

Add to your local_requirements.txt to ensure it is automatically reinstalled during future upgrades.

echo "netbox-librenms-plugin" >> /opt/netbox/local_requirements.txt #Check your NetBox install location

Docker

For adding to a NetBox Docker setup see how to create a custom Docker image. the general instructions for using netbox-docker with plugins.

Add the plugin to plugin_requirements.txt (netbox-docker):

# plugin_requirements.txt
netbox-librenms-plugin

Configuration

1. Enable the Plugin

Enable the plugin in /opt/netbox/netbox/netbox/configuration.py, or if you use netbox-docker, your /configuration/plugins.py file :

PLUGINS = [
    'netbox_librenms_plugin'
]

2. Apply the plugin configuration

Multi server example:

PLUGINS_CONFIG = {
    'netbox_librenms_plugin': {
        'servers': {
            'production': {
                'display_name': 'Production LibreNMS',
                'librenms_url': 'https://librenms-prod.example.com',
                'api_token': 'your_production_token',
                'cache_timeout': 300,
                'verify_ssl': True,
                'interface_name_field': 'ifDescr'
            },
            'testing': {
                'display_name': 'Test LibreNMS',
                'librenms_url': 'https://librenms-test.example.com',
                'api_token': 'your_test_token',
                'cache_timeout': 300,
                'verify_ssl': False,
                'interface_name_field': 'ifName'
            },
            'development': {
                'display_name': 'Dev LibreNMS',
                'librenms_url': 'https://librenms-dev.example.com',
                'api_token': 'your_dev_token',
                'cache_timeout': 180,
                'verify_ssl': False,
                'interface_name_field': 'ifDescr'
            }
        }
    }
}

Or use the original single server confiig example:

PLUGINS_CONFIG = {
    'netbox_librenms_plugin': {
        'librenms_url': 'https://your-librenms-instance.com',
        'api_token': 'your_librenms_api_token',
        'cache_timeout': 300,
        'verify_ssl': True, # Optional: Change to False if needed,
        'interface_name_field': 'ifDescr', # Optional: LibreNMS field used for interface name. ifName used as default
    }
}

3. Apply Database Migrations

Apply database migrations with Netbox manage.py:

(venv) $ python manage.py migrate

4. Collect Static Files

The plugin includes static files that need to be collected by NetBox. Run the following command to collect static files:

(venv) $ python manage.py collectstatic --no-input

5. Restart Netbox

Restart the Netbox service to apply changes:

sudo systemctl restart netbox

6. Custom Field

As of version 0.4.4, the plugin automatically creates the librenms_id custom field (JSON type) when migrations are run. No manual setup is required.

The field is created for Device, Virtual Machine, Interface, and VM Interface objects and stores a per-server mapping (e.g., {"production": 42}).

For more info check out custom field docs

Update

source /opt/netbox/venv/bin/activate
pip install -U netbox-librenms-plugin
python manage.py migrate
python manage.py collectstatic --no-input
systemctl restart netbox

Uninstall

See the instructions for uninstalling plugins.

Credits

Based on the NetBox plugin tutorial and docs:

This package was created with Cookiecutter. Thanks to the netbox-community/cookiecutter-netbox-plugin for the project template.

Metadata

Release files for netbox-librenms-experimental-plugin 0.1.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for netbox-librenms-experimental-plugin 0.1.4
File Size Uploaded Provenance Actions
netbox_librenms_experimental_plugin-0.1.4.tar.gz 11.2 MB With provenance Details for netbox_librenms_experimental_plugin-0.1.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for netbox-librenms-experimental-plugin 0.1.4
File Interpreter ABI Platform Actions
netbox_librenms_experimental_plugin-0.1.4-py3-none-any.whl Python 3 none any Details for netbox_librenms_experimental_plugin-0.1.4-py3-none-any.whl

Total release size: 11.6 MB

Release files / netbox_librenms_experimental_plugin-0.1.4.tar.gz

Download URL netbox_librenms_experimental_plugin-0.1.4.tar.gz
Size 11.2 MB
Tags Source
SHA-256 checksum
How to use checksums
738c6a361dae1a53647dbf1d206d3648a5ecea6d37ecedd4f84bf3f237b860eb
BLAKE2b-256 checksum
How to use checksums
7dc11af62159940df1836543680bfa5869725db8113a4a2a2d6471ef28c84106
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.13

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 19, 2026.

Transparency log

Release files / netbox_librenms_experimental_plugin-0.1.4-py3-none-any.whl

Download URL netbox_librenms_experimental_plugin-0.1.4-py3-none-any.whl
Size 400.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
72dc4ef3ef9faad49a248e87b0694746cfd21f7a84d3c666dfada41af9d5f16f
BLAKE2b-256 checksum
How to use checksums
5ba9e8b9556025557e6c11b80f42b6128dacfe46a08680f007ab5008d234370a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.13

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 19, 2026.

Transparency log

Security for netbox-librenms-experimental-plugin 0.1.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for netbox_librenms_experimental_plugin-0.1.4.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 19, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page