A NetBox plugin for pinging and discovering IPs
Project description
NetBox Ping Plugin
A NetBox plugin for pinging and discovering IPs in your network.
Features
- Ping IPs and subnets directly from NetBox
- Auto-discover new IPs
- Track IP status with custom fields and tags
- Bulk scan operations
- Dark mode compatible UI
Installation
pip install netbox-ping
Configuration
Add to your configuration.py:
PLUGINS = ['netbox_ping']
PLUGINS_CONFIG = {
'netbox_ping': {
'coming_soon': True
}
}
Usage
- Install the plugin
- Navigate to Plugins > NetBox Ping
- Click "Create Required Fields & Tags"
- Start scanning your networks!
Requirements
- NetBox 4.0 or later
- Python 3.8 or later
pingcommand available on the system
Installation
Package Installation
- Install the package from your NetBox installation path:
source /opt/netbox/venv/bin/activate cd /opt/netbox pip install git+https://github.com/DenDanskeMine/netbox-prefix-pinger.git
Enable the Plugin
- Add the plugin to
PLUGINSin/opt/netbox/netbox/netbox/configuration.py:PLUGINS = [ 'netbox_ping', ]
Run Migrations
- Apply database migrations:
cd /opt/netbox python3 manage.py migrate
Collect Static Files
- Collect static files:
python3 manage.py collectstatic
Restart NetBox
- Restart the NetBox service:
sudo systemctl restart netbox
Usage
- Navigate to the "Plugins" menu in NetBox
- Select "Network Tools" from the dropdown
- You'll see a list of all prefixes in your NetBox instance
- Two actions are available for each prefix:
- Check Status: Checks all existing IPs in the prefix
- Scan Subnet: Discovers and adds new active IPs
Status Indicators
- 🟢 Online Tag: IP is responding to ping
- 🔴 Offline Tag: IP is not responding
- Custom Field "Up_Down": Boolean indicator of IP status
Configuration
No additional configuration is required. The plugin will automatically:
- Create required custom fields
- Create online/offline tags
- Set up necessary permissions
Permissions
Users need the following permissions to use the plugin:
ipam.view_prefixipam.view_ipaddress
Development
To set up a development environment:
-
Clone the repository:
git clone https://github.com/yourusername/netbox-ping.git cd netbox-ping
-
Create a virtual environment:
python3 -m venv venv source venv/bin/activate
-
Install development dependencies:
pip install -e .
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Support
If you have any questions or need help, please:
- Open an issue on GitHub
- Check existing issues for answers
- Contact the maintainer
Acknowledgments
- Built for NetBox (https://github.com/netbox-community/netbox)
- Inspired by the need for simple IP status tracking, this is my first plugin for NetBox.
- I'm not a good python developer, so this is probably not the best way to do this.
- The plugin
netbox-interface-synchronizationgave me a lot of inspiration, code wise, as the offical NetBox development repo had some issues, i couldn't get around. - The plugin netbox-interface-synchronization is a great plugin, and i recommend using it if you need to synchronize interfaces.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file netbox_ping-0.25.tar.gz.
File metadata
- Download URL: netbox_ping-0.25.tar.gz
- Upload date:
- Size: 18.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1bf4074b77522f3468b8ce41bb878e4338090cd928fd76828d8c57eb006a255d
|
|
| MD5 |
cfc7ae6ca13fb0304bb9b819db42f895
|
|
| BLAKE2b-256 |
918256f9daca5b2350a1400df6d8fba3f883d193241f06af9a6eb36afdc0105d
|
File details
Details for the file netbox_ping-0.25-py3-none-any.whl.
File metadata
- Download URL: netbox_ping-0.25-py3-none-any.whl
- Upload date:
- Size: 22.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4033c7946ce254729c8e0a647db0ed94072d732b8df0cad689df3d0dab9aaaec
|
|
| MD5 |
c1d24c14ddf858f69bc7dc8f2d6c8cad
|
|
| BLAKE2b-256 |
aff3204996e605816e5ff8fa800d2cecb8aa010ce4d5c377f4fd583370a38c62
|