ARP-Netconf
Resources Summary
Section titled “Resources Summary”| YANG Path | get/get-config | edit-config | rpc |
|---|---|---|---|
| /arp-global | Y | merge, replace, create, delete | — |
| /arp-global/arp-dynamic-learning | Y | merge, replace, create, delete | — |
| /interfaces/{name}/arp-dynamic-learning | Y | merge, replace, create, delete | — |
| /show-arp-proxy-count | — | — | Y |
| /show-interface-arp-proxy | — | — | Y |
| clear-neighbors | — | — | Y |
Examples
Section titled “Examples”This chapter provides examples on how to use Netconf to manage ARP configurations on AsterNOS devices.
Create ARP Global Configurations
Section titled “Create ARP Global Configurations”The default expiration time for ARP is 300 seconds.
Request example to create ARP global configurations via edit-config.
<config><top> <arp-global operation="create"> <arp-dynamic-learning> <expire-time>1000</expire-time> </arp-dynamic-learning> <log-enable>True</log-enable> </arp-global></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:0f6026e2-0dc9-4c98-a169-3c4354f85976"> <ok/></rpc-reply>Modify ARP Global Configurations
Section titled “Modify ARP Global Configurations”Request example to modify ARP global configurations via edit-config.
<config><top> <arp-global operation="merge"> <arp-dynamic-learning> <expire-time>500</expire-time> </arp-dynamic-learning> <log-enable>False</log-enable> </arp-global></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:0f51d60f-6c64-4b0d-b6eb-2dc68b3ee2b1"> <ok/></rpc-reply>Delete ARP Global Configurations
Section titled “Delete ARP Global Configurations”Request example to delete ARP global configurations via edit-config.
<config><top> <arp-global operation="delete"/></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:5ab6f1f4-613e-4c38-8a8b-f6600ca31b5d"> <ok/></rpc-reply>Get ARP Global Configurations
Section titled “Get ARP Global Configurations”Request example to get ARP global configurations via get-config with subtree filter.
<filter type="subtree"> <top> <arp-global/> </top></filter>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:7f798925-a9b7-440a-80fc-990e5941d955"> <data> <top> <arp-global xmlns="http://asterfusion.com/ns/yang/asternos-arp"> <log-enable>false</log-enable> <arp-dynamic-learning> <expire-time>500</expire-time> </arp-dynamic-learning> </arp-global> </top> </data></rpc-reply>Create Static ARP for Interface
Section titled “Create Static ARP for Interface”Request example to create static ARP for interface via edit-config.
<config><top> <interfaces> <interface> <name>Ethernet1</name> <ipv4> <address operation="create"> <ip-prefix>20.1.1.1/20</ip-prefix> </address> <address operation="create"> <ip-prefix>30.1.1.1/20</ip-prefix> </address> <neighbor operation="create"> <ip>20.1.1.2</ip> <mac-address>00:0e:c6:56:9d:35</mac-address> </neighbor> <neighbor operation="create"> <ip>30.1.1.2</ip> <mac-address>00:0e:c6:56:9d:35</mac-address> </neighbor> </ipv4> </interface> </interfaces></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:61fd81c6-e86b-4c48-8ad2-22bd334c9cf1"> <ok/></rpc-reply>Delete Static ARP for Interface
Section titled “Delete Static ARP for Interface”Request example to delete static ARP for interface via edit-config.
<config><top> <interfaces> <interface> <name>Ethernet1</name> <ipv4> <neighbor operation="delete"> <ip>20.1.1.2</ip> </neighbor> </ipv4> </interface> </interfaces></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:4caaeb3b-781c-4a05-a3f1-26c2cd2829ba"> <ok/></rpc-reply>Delete All ARP for Interface
Section titled “Delete All ARP for Interface”Request example to delete all ARP for interface via edit-config.
<config><top> <interfaces> <interface> <name>Ethernet1</name> <ipv4> <neighbor operation="delete"> </neighbor> </ipv4> </interface> </interfaces></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:7868a8f4-fa4d-4c6e-b66f-55996b2ad188"> <ok/></rpc-reply>Get All Static ARP for Interface
Section titled “Get All Static ARP for Interface”Request example to get all static ARP for interface via get-config with subtree filter.
<filter type="subtree"> <top> <interfaces> <interface> <name>Ethernet1</name> <ipv4> <neighbor> </neighbor> </ipv4> </interface> </interfaces> </top></filter>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:844d304d-90d3-47f8-adba-16f2741874f1"> <data> <top> <interfaces xmlns="http://asterfusion.com/ns/yang/asternos-interfaces"> <interface> <name>Ethernet1</name> <ipv4 xmlns="http://asterfusion.com/ns/yang/asternos-ip"> <neighbor> <ip>20.1.1.2</ip> <mac-address>00:0e:c6:56:9d:35</mac-address> </neighbor> <neighbor> <ip>30.1.1.2</ip> <mac-address>00:0e:c6:56:9d:35</mac-address> </neighbor> </ipv4> </interface> </interfaces> </top> </data></rpc-reply>Show All ARP
Section titled “Show All ARP”Request example to show all ARP via rpc show-ipv4-neighbor-summary
<show-ipv4-neighbor-summary/>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:93a9278f-91ac-4ef7-a2aa-a6dec1f58456"> <data xmlns="http://asterfusion.com/ns/yang/asternos-ip"> Address MacAddress Iface Vlan -------------- ----------------- ------- ------ 192.168.0.1 60:eb:5a:01:10:03 eth0 - 192.168.0.76 60:eb:5a:01:10:03 eth0 - 192.168.15.127 60:eb:5a:01:10:03 eth0 - Total number of entries 3 </data></rpc-reply>Enable ARP Proxy On Vlan Interface
Section titled “Enable ARP Proxy On Vlan Interface”ARP proxy only supports configuration on VLAN interface. The ARP proxy currently only supports merge and get operations. To disable this feature, the mode needs to be set to disable.
Request example to enable ARP proxy on vlan interface via edit-config.
<config><top> <vlans> <vlan operation="create"> <vlanid>100</vlanid> </vlan> </vlans> <interfaces> <interface> <name>Vlan100</name> <arp-dynamic-learning> <mode>anycast_gw</mode> </arp-dynamic-learning> </interface> </interfaces></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:a5891471-02ee-4d3f-892c-ed515e3a7a53"> <ok/></rpc-reply>Disable ARP Proxy On Vlan Interface
Section titled “Disable ARP Proxy On Vlan Interface”Request example to disable ARP proxy on vlan interface via edit-config.
<config><top> <interfaces> <interface> <name>Vlan100</name> <arp-dynamic-learning> <mode>disable</mode> </arp-dynamic-learning> </interface> </interfaces></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:49687cc0-903d-4865-be5f-e709e1c9e981"> <ok/></rpc-reply>Get ARP Proxy On Vlan Interface
Section titled “Get ARP Proxy On Vlan Interface”Request example to get ARP proxy on vlan interface via get-config with subtree filter.
<filter type="subtree"> <top> <interfaces> <interface> <name>Vlan100</name> <arp-dynamic-learning> </arp-dynamic-learning> </interface> </interfaces> </top></filter>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:49687cc0-903d-4865-be5f-e709e1c9e981"> <data> <top> <interfaces xmlns="http://asterfusion.com/ns/yang/asternos-interfaces"> <interface> <name>Vlan100</name> <arp-dynamic-learning xmlns="http://asterfusion.com/ns/yang/asternos-arp"> <mode>anycast_gw</mode> </arp-dynamic-learning> </interface> </interfaces> </top> </data></rpc-reply>Show ARP Proxy Summary
Section titled “Show ARP Proxy Summary”Request example to show ARP proxy summary via rpc show-interface-arp-proxy.
<show-interface-arp-proxy/>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:c71e86a7-3247-4962-b746-f066cfe5cbc4"> <data xmlns="http://asterfusion.com/ns/yang/asternos-arp"> <interface> <name>Vlan100</name> <mode>anycast_gw</mode> </interface> </data></rpc-reply>Properties Descriptions
Section titled “Properties Descriptions”Arp Global
Section titled “Arp Global”Tree Diagram
module: asternos-arp +--rw arp-global +--rw arp-dynamic-learning | +--rw expire-time? uint32 +--rw log-enable? boolean
augment /if:interfaces/if:interface: +--rw arp-dynamic-learningTable of Properties
| Name | Required | Type/Range | Description |
|---|---|---|---|
| arp-global | M | Path-only node, has no configurable value. | |
| arp-dynamic-learning | M | Path-only node, has no configurable value. global ARP dynamic learning configuration. | |
| expire-time | O | 60..7200 | ARP aging timer, units seconds. Default value: 300 |
| log-enable | O | ”true" "false” | Indicates if the ARP log is enabled |
global ARP dynamic learning configuration
Section titled “global ARP dynamic learning configuration”Tree Diagram
module: asternos-arp +--rw arp-global +--rw arp-dynamic-learning +--rw expire-time? uint32
augment /if:interfaces/if:interface: +--rw arp-dynamic-learningTable of Properties
| Name | Required | Type/Range | Description |
|---|---|---|---|
| arp-dynamic-learning | M | Path-only node, has no configurable value. global ARP dynamic learning configuration. | |
| expire-time | O | 60..7200 | ARP aging timer, units seconds. Default value: 300 |
Arp Dynamic Learning
Section titled “Arp Dynamic Learning”Tree Diagram
module: asternos-arp
augment /if:interfaces/if:interface: +--rw arp-dynamic-learningShow Arp Proxy Count
Section titled “Show Arp Proxy Count”Tree Diagram
module: asternos-arp
augment /if:interfaces/if:interface: +--rw arp-dynamic-learning
rpcs: +---x show-arp-proxy-count +---w input | +---w second? uint32 +--ro output +--ro data? <anydata>Table of Properties
| Name | Required | Type/Range | Description |
|---|---|---|---|
| show-arp-proxy-count | O | ||
| second | O | integer | Time interval in seconds |
| data | O | A table that shows the number of ARP proxy packets. |
Show Interface Arp Proxy
Section titled “Show Interface Arp Proxy”Tree Diagram
module: asternos-arp
augment /if:interfaces/if:interface: +--rw arp-dynamic-learning
rpcs: +---x show-interface-arp-proxy +--ro output +--ro data +--ro interface* [] +--ro name? union +--ro mode? enumerationTable of Properties
| Name | Required | Type/Range | Description |
|---|---|---|---|
| show-interface-arp-proxy | O | ||
| data | M | Path-only node, has no configurable value. A table that shows arp-proxy status of all Interface | |
| interface | M | Path-only node, has no configurable value. | |
| name | O | union | The name of the interface. |
| mode | O | ”disable" "default" "anycast_gw” | ARP proxy mode. |
Clear Neighbors
Section titled “Clear Neighbors”Tree Diagram
module: asternos-arp
augment /if:interfaces/if:interface: +--rw arp-dynamic-learning
rpcs: +---x clear-neighbors +---w input | +---w interface union +--ro output +--ro data? stringTable of Properties
| Name | Required | Type/Range | Description |
|---|---|---|---|
| clear-neighbors | O | ||
| interface | M | → asternos-interfaces:interface-ref | all - to flush neighbors on all the interface. interface name - remove neighbors on a specific interface. |
| data | O | string | The result string indicating operation success or failure. |