NAPALM Huawei VRP driver
raw JSON → 1.2.0 verified Sat May 09 auth: no python
Driver for Huawei VRP (Versatile Routing Platform) devices under the NAPALM automation framework. Version 1.2.0 provides multi-vendor network automation with getters like get_facts, get_interfaces, get_bgp_neighbors, and configuration management. Releases are irregular, with v1.2.0 from April 2024.
pip install napalm-huawei-vrp Common errors
error ModuleNotFoundError: No module named 'napalm_huawei_vrp' ↓
cause Package not installed.
fix
Run 'pip install napalm-huawei-vrp'.
error napalm.base.exceptions.ConnectionException: Could not open connection to ... ↓
cause Wrong SSH port, credentials, or connectivity.
fix
Check hostname, port (default 22), username/password, and that device is reachable.
Warnings
breaking v1.0.0 dropped support for NAPALM <3.0 and changed driver name from 'huawei_vrp' (case-sensitive). ↓
fix Use exact string 'huawei_vrp' in get_network_driver().
gotcha Optional_args like 'port' must be integers, not strings. ↓
fix Pass port=22 (int) instead of port='22'.
deprecated NAPALM v3+ deprecated napalm_base; import from napalm directly. ↓
fix Install napalm>=3.0 and use 'from napalm import get_network_driver'.
Imports
- HuaweiVRP
from napalm_huawei_vrp import HuaweiVRPDriver
Quickstart
from napalm import get_network_driver
import os
driver = get_network_driver('huawei_vrp')
device = driver(
hostname='192.0.2.1',
username=os.environ.get('USER', 'admin'),
password=os.environ.get('PASSWORD', 'admin'),
optional_args={'port': 22}
)
device.open()
print(device.get_facts())
device.close()