- Ansible Network Health Checks Collection provides platform-agnostic roles to perform automated health checks across various network devices.
- The collection includes capabilities for performing network device health, detecting failures, and recommending proactive maintenance.
- Designed for network administrators, automation engineers, and IT professionals, this collection enhances network visibility, operational monitoring, and configuration validation.
The collection includes the following roles:
| Name | Description |
|---|---|
| network.healthchecks.bgp | Monitor BGP neighbor states and session status to ensure proper routing protocol operation. |
| network.healthchecks.cpu | Monitor CPU usage to detect excessive CPU consumption and ensure device stability. |
| network.healthchecks.memory | Monitor memory usage to detect excessive memory consumption and ensure device stability. |
| network.healthchecks.uptime | Monitor system uptime to detect system stability and identify devices needing maintenance. |
| network.healthchecks.environment | Monitor environmental factors like temperature and power supply to prevent hardware failures. |
| network.healthchecks.filesystem | Ensure sufficient disk space and check for file system errors that may affect operations. |
| network.healthchecks.crashfiles | Monitor crash files to detect system crashes and stability issues. |
| network.healthchecks.interfaces | Monitor interface states and operational status to ensure proper network connectivity. |
| network.healthchecks.ospf | Monitor OSPF neighbor states and session status to ensure proper routing protocol operation. |
The network.healthchecks.bgp role monitors BGP neighbor states and session status to ensure proper routing protocol operation and network connectivity.
For detailed documentation, features, and examples, see the BGP Health Check README.
The network.healthchecks.cpu role monitors CPU usage on network devices to detect excessive CPU consumption and ensure device stability.
For detailed documentation, features, and examples, see the CPU Health Check README.
The network.healthchecks.memory role monitors memory usage on network devices to detect excessive memory consumption and ensure device stability.
For detailed documentation, features, and examples, see the Memory Health Check README.
The network.healthchecks.uptime role monitors system uptime on network devices to detect system stability and identify devices that may need maintenance.
For detailed documentation, features, and examples, see the Uptime Health Check README.
The network.healthchecks.environment role monitors environmental factors like temperature and power supply to prevent hardware failures.
For detailed documentation, features, and examples, see the Environment Health Check README.
The network.healthchecks.filesystem role ensures sufficient disk space and checks for file system errors that may affect operations.
For detailed documentation, features, and examples, see the Filesystem Health Check README.
The network.healthchecks.crashfiles role monitors crash files on network devices to detect system crashes and stability issues.
For detailed documentation, features, and examples, see the Crash Files Health Check README.
The network.healthchecks.interfaces role monitors interface states and operational status to ensure proper network connectivity and identify potential link issues.
For detailed documentation, features, and examples, see the Interfaces Health Check README.
The network.healthchecks.ospf role monitors OSPF neighbor states and session status to ensure proper routing protocol operation and network connectivity.
For detailed documentation, features, and examples, see the OSPF Health Check README.
- Requires Ansible
- Requires Content Collections
- Testing Requirements
- Users need to include platform-specific collections as per their requirements:
To consume this Validated Content from Automation Hub, add the following to your ansible.cfg:
[galaxy]
server_list = automation_hub
[galaxy_server.automation_hub]
url=https://console.redhat.com/api/automation-hub/content/validated/
auth_url=https://sso.redhat.com/auth/realms/redhat-external/protocol/openid-connect/token
token=<SuperSecretToken>
Utilize the current Token, and if the token has expired, obtain the necessary token from the Automation Hub Web UI.
The project uses tox to run ansible-lint and ansible-test sanity.
Assuming this repository is checked out in the proper structure, run:
tox -e ansible-lint
tox -e py39-sanityTo run integration tests, ensure that your inventory has a network_healthchecks group.
Depending on what test target you are running, comment out the host(s).
[network_hosts]
cpu
bgp
memory
[cpu:vars]
< enter inventory details for this group >
[bgp:vars]
< enter inventory details for this group > ansible-test network-integration -i /path/to/inventory --python 3.9 [target]We welcome community contributions to this collection. If you find problems, please open an issue or create a PR against this repository.
Don't know how to start? Refer to the Ansible community guide!
Want to submit code changes? Take a look at the Quick-start development guide.
We also use the following guidelines:
This collection follows the Ansible project's Code of Conduct. Please read and familiarize yourself with this document.
Release notes are available here.
- Developing network resource modules
- Ansible Networking docs
- Ansible Collection Overview
- Ansible Roles overview
- Ansible User guide
- Ansible Developer guide
- Ansible Community Code of Conduct
GNU General Public License v3.0 or later.
See LICENSE to see the full text.