Drivers Overview
Connector() Class
The switches/connect/ directory contains the drivers for the various devices supported by OpenL2M.
All drivers are derived from a base Connector() class. This implements basic attributes and functions used by all drivers. It is also the programatic interface used by the HTML templates in /templates/, mostly through the conn object passed into the templates.
The following pages attempt to document the Connector() class, and how to use it to store various pieces of information about a device. Below that are (some) details about some of the specific drivers, which use the Connector() class.
Information about the Connector() class:
Interface Operations
The following sections describe how actions on the interfaces or ports of a device are implemented and should be used in vendor drivers.
Vendor Drivers
Here are some details about some of the drivers we have implemented. We currently provide several sub-connectors (sub-classes):
several based on SNMP (generic, Arista, Aruba/HP-Procurve, Aruba/AOS-CX, Cisco, Juniper, Netgear).
a Juniper PyEz-NC API based driver.
a REST-API based connector for the Aruba AOS-S line of devices.
a REST-API based connector for the Aruba AOS-CX line of devices.
a REST-API based connector for Arista devices.
a read-only driver based on the Napalm automation framework.
a SSH commands-only driver using the Python Netmiko module.
Note that the SNMP driver can support several vendors that implemented their own SNMP data. See that driver for more details.
We implement the ability to run regular Command-Line Interface (CLI) commands through SSH logins. This uses the Python Netmiko library. This is also implemented as a part of the base Connector() class. This allows vendor-drivers to override this functionality and implement their own mechanism to run CLI commands. See SSH connections for details.
Finally, we provide an overview of how to implement a new driver.
Details about (some of) the drivers:
- Driver Hierarchy Overview
- SNMP Driver Overview
- Aruba AOS-CX API Driver Overview
- Arista eAPI Driver Overview
- Aruba AOS-S REST API Driver
- Junos PyEZ Driver Overview
- HPE Comware REST API Driver
- HPE CW7 NetConf Driver (Abandoned)
- Napalm Driver Overview
- SSH CLI commands
- Generic REST API Driver
- Implementing New Drivers