1 SNMP4SDN Developer Guide
2 ========================
7 We propose a southbound plugin that can control the off-the-shelf
8 commodity Ethernet switches for the purpose of building SDN using
9 Ethernet switches. For Ethernet switches, forwarding table, VLAN table,
10 and ACL are where one can install flow configuration on, and this is
11 done via SNMP and CLI in the proposed plugin. In addition, some settings
12 required for Ethernet switches in SDN, e.g., disabling STP and flooding,
15 .. figure:: ./images/snmp4sdn_in_odl_architecture.jpg
16 :alt: SNMP4SDN as an OpenDaylight southbound plugin
18 SNMP4SDN as an OpenDaylight southbound plugin
23 The modules in the plugin are depicted as the following figure.
25 .. figure:: ./images/snmp4sdn_modules.jpg
26 :alt: Modules in the SNMP4SDN Plugin
28 Modules in the SNMP4SDN Plugin
30 - AclService: add/remove ACL profile and rule on the switches.
32 - FdbService: add/modify/remove FDB table entry on the switches.
34 - VlanService: add/modify/remove VLAN table entry on the switches.
36 - TopologyService: query and acquire the subnet topology.
38 - InventoryService: acquire the switches and their ports.
40 - DiscoveryService: probe and resolve the underlying switches as well
41 as the port pairs connecting the switches. The probing is realized by
42 SNMP queries. The updates from discovery will also be reflected to
45 - MiscConfigService: do kinds of settings on switches
47 - Supported STP and ARP settings such as enable/disable STP, get
48 port’s STP state, get ARP table, set ARP entry, and others
50 - VendorSpecificHandler: to assist the flow configuration services to
51 call the switch-talking modules with correct parameters value and
54 - Switch-talking modules
56 - For the services above, when they need to read or configure the
57 underlying switches via SNMP or CLI, these queries are dealt with
58 the modules SNMPHandler and CLIHandler which directly talk with
59 the switches. The SNMPListener is to listen to snmp trap such as
60 link up/down event or switch on/off event.
65 In terms of the architecture of the SNMP4SDN Plugin’s features, the
66 features include flow configuration, topology discovery, and
67 multi-vendor support. Their architectures please refer to Wiki
69 Design <https://wiki.opendaylight.org/view/SNMP4SDN:Developer_Guide#Design>`__).
71 Installation and Configuration Guide
72 ------------------------------------
74 - Please refer to the *Getting Started Guide* in
75 https://www.opendaylight.org/downloads, find the SNMP4SDN section.
77 - For the latest full guide, please refer to Wiki (`Installation
78 Guide <https://wiki.opendaylight.org/view/SNMP4SDN:Installation_Guide>`__,
80 Configuration <https://wiki.opendaylight.org/view/SNMP4SDN:User_Guide#Configuration>`__).
85 - For the latest full guide, please refer to Wiki (`User Guide -
86 Tutorial <https://wiki.opendaylight.org/view/SNMP4SDN:User_Guide#Tutorial_.2F_How-To>`__).
88 Programmatic Interface(s)
89 -------------------------
91 SNMP4SDN Plugin exposes APIs via MD-SAL with YANG model. The methods
92 (RPC call) and data structures for them are listed below.
103 - get-node-connector-list
105 - set-discovery-interval (given interval time in seconds)
111 - node: composed of node-id, node-type
113 - node-connector: composed of node-connector-id,
114 node-connector-type, node
116 - topo-edge: composed of head-node-connector-id,
117 head-node-connector-type, head-node-id, head-node-type,
118 tail-node-connector-id, tail-node-connector-type, tail-node-id,
126 - add-vlan (given node ID, VLAN ID, VLAN name)
128 - add-vlan-and-set-ports (given node ID, VLAN ID, VLAN name, tagged
129 ports, untagged ports)
131 - set-vlan-ports (given node ID, VLAN ID, tagged ports, untagged
134 - delete-vlan (given node ID, VLAN ID)
136 - get-vlan-table (given node ID)
143 - create-acl-profile (given node ID, acl-profile-index, acl-profile)
145 - del-acl-profile (given node ID, acl-profile-index)
147 - set-acl-rule (given node ID, acl-index, acl-rule)
149 - del-acl-rule (given node ID, acl-index)
151 - clear-acl-table (given node ID)
155 - acl-profile-index: composed of profile-id, profile name
157 - acl-profile: composed of acl-layer, vlan-mask, src-ip-mask,
160 - acl-layer: IP or ETHERNET
162 - acl-index: composed of acl-profile-index, acl-rule-index
164 - acl-rule-index: composed of rule-id, rule-name
166 - acl-rule: composed of port-list, acl-layer, acl-field, acl-action
168 - acl-field: composed of vlan-id, src-ip, dst-ip
170 - acl-action: PERMIT or DENY
177 - set-fdb-entry (given fdb-entry)
179 - del-fdb-entry (given node-id, vlan-id, dest-mac-adddr)
181 - get-fdb-entry (given node-id, vlan-id, dest-mac-adddr)
183 - get-fdb-table (given node-id)
187 - fdb-entry: composed of node-id, vlan-id, dest-mac-addr, port,
190 - fdb-entry-type: OTHER/INVALID/LEARNED/SELF/MGMT
197 - set-stp-port-state (given node-id, port, is\_nable)
199 - get-stp-port-state (given node-id, port)
201 - get-stp-port-root (given node-id, port)
203 - enable-stp (given node-id)
205 - disable-stp (given node-id)
207 - delete-arp-entry (given node-id, ip-address)
209 - set-arp-entry (given node-id, arp-entry)
211 - get-arp-entry (given node-id, ip-address)
213 - get-arp-table (given node-id)
218 DISABLE/BLOCKING/LISTENING/LEARNING/FORWARDING/BROKEN
220 - arp-entry: composed of ip-address and mac-address
227 - reload-db (The following 4 RPC implemention is TBD)
231 - delete-switch-entry
239 - switch-info: compose of node-ip, node-mac, community,
240 cli-user-name, cli-password, model
245 - `SNMP4SDN Wiki <https://wiki.opendaylight.org/view/SNMP4SDN:Main>`__
247 - SNMP4SDN Mailing List
248 (`user <https://lists.opendaylight.org/mailman/listinfo/snmp4sdn-users>`__,
249 `developer <https://lists.opendaylight.org/mailman/listinfo/snmp4sdn-dev>`__)
251 - `Latest troubleshooting in
252 Wiki <https://wiki.opendaylight.org/view/SNMP4SDN:User_Guide#Troubleshooting>`__