netbox-windows-dhcp
A NetBox plugin that connects NetBox to Windows DHCP Server through PowerShell Universal (PSU). It keeps DHCP scopes, options, exclusions, reservations and leases in step between NetBox and your DHCP servers, in whichever direction you choose.
What it does
- Brings your DHCP servers into NetBox. Import failovers, scopes, option values and exclusion ranges from a live server, then keep them up to date with a scheduled sync.
- Tracks leases and reservations as NetBox IP Addresses, with status, DNS name, client MAC and lease details, and cleans up the ones the server no longer has.
- Lets you choose the source of truth. With the push settings on, NetBox wins and changes are pushed to the DHCP servers, most of them right away. With them off, the DHCP servers win and NetBox mirrors them.
- Handles failover pairs: changes go to the primary and are replicated to the partner. If the primary is down, the sync reads through the secondary.
- Protects what you choose: a tag keeps IPs (or whole prefixes) out of the sync's reach, and maintenance mode pauses a server, failover or scope.
- Keeps you out of trouble: edits the next sync would undo are refused, and a failed read from a server never deletes anything.
- Runs everything as background jobs, recorded in NetBox's changelog and able to fire NetBox event rules.
- Full REST API for all plugin objects.
Requirements
NetBox 4.5 or 4.6, Python 3.12 or later, and a licensed PowerShell Universal install on each Windows DHCP server. See Requirements for the details.
Quick start
pip install netbox-windows-dhcp
Add 'netbox_windows_dhcp' to PLUGINS in configuration.py, run python manage.py migrate, and restart NetBox and its RQ workers. Then set up PSU on each DHCP server and import your first server; the Installation guide walks through every step.
Documentation
| Guide | What's in it |
|---|---|
| Requirements | Software versions and licenses |
| Installation | From a running NetBox and PSU to your first imported DHCP server |
| Upgrading | Upgrading the plugin and the PSU scripts |
| Configuration | The Settings and Schedule pages, and PLUGINS_CONFIG overrides |
| How the sync works | Who wins for what, how scopes and IPs are matched, and the safety rules |
| Editing rules | What you can create, edit and delete, and when |
| Operations | Maintenance mode, protected IPs, Unassigned Scopes, commands and troubleshooting |
| REST API | The plugin's NetBox API |
| PowerShell Universal | How the plugin uses PSU, and the PSU endpoint reference |
| Changelog | What changed in each release |
Testing
The plugin ships an offline Django test suite (no DHCP server, PSU or network needed). Run it from the NetBox install directory:
python manage.py test netbox_windows_dhcp --keepdb
License
Released under the GNU General Public License v3.0 (or later). See LICENSE.
Metadata
Release files for netbox-windows-dhcp 2.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| netbox_windows_dhcp-2.0.0.tar.gz | 210.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| netbox_windows_dhcp-2.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 458.2 kB
Release files / netbox_windows_dhcp-2.0.0.tar.gz
| Download URL | netbox_windows_dhcp-2.0.0.tar.gz |
|---|---|
| Size | 210.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
337b2b724090032a960b5542f8a4068826b4735d4eb13da766f9d1ce2aca4f9d
|
|
BLAKE2b-256 checksum How to use checksums |
1108e29580d71ee42d67d8c4d0356531b2367adecc0dc1c6e61fa9c38515745f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.7
|
Release files / netbox_windows_dhcp-2.0.0-py3-none-any.whl
| Download URL | netbox_windows_dhcp-2.0.0-py3-none-any.whl |
|---|---|
| Size | 247.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5f28d10a0f0f634feb558f4ea63be668497a597a85c8cd7d32d07c4ac1db8487
|
|
BLAKE2b-256 checksum How to use checksums |
b2ea0f7bdcc44448bc499a4f6dedea9aed3eb84c37028f38c6e1a86d843aa0c1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.14.7
|