RADV-Netconf
此内容尚不支持你的语言。
Resources Summary
Section titled “Resources Summary”| YANG Path | get/get-config | edit-config | rpc |
|---|---|---|---|
| /global-router-advertisement | Y | merge, replace, create, delete | — |
| /global-router-advertisement/rdnsses/{rdnss} | Y | replace, create, delete | — |
| /global-router-advertisement/routes/{route} | Y | merge, replace, create, delete | — |
| /show-radv-summary | — | — | Y |
Examples
Section titled “Examples”This chapter provides examples on how to use Netconf to manage Router Advertisements (RADV) on AsterNOS devices.
Create Global RADV
Section titled “Create Global RADV”Request example to create global RADV via edit-config.
<config><top> <global-router-advertisement operation="create"> <enabled>true</enabled> <unicast-only-flag>true</unicast-only-flag> <managed-flag>true</managed-flag> <other-config-flag>true</other-config-flag> <link-mtu>1500</link-mtu> <on-link-flag>true</on-link-flag> <autonomous-flag>false</autonomous-flag> <rdnsses> <rdnss>2001:db8::1</rdnss> </rdnsses> <routes> <route>2001:db8:1234::/48</route> <preferred>high</preferred> </routes> </global-router-advertisement></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:a6c887fb-108c-4ea1-930a-0148684bbd72"> <ok/></rpc-reply>Get Global RADV Status
Section titled “Get Global RADV Status”Request example to get global RADV status via get-config with subtree filter.
<filter type="subtree"> <top> <global-router-advertisement> </global-router-advertisement> </top></filter>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:8d70f415-e472-4bf8-94b5-6e86e358b6a9"> <data> <top> <global-router-advertisement xmlns="http://asterfusion.com/ns/yang/asternos-radv"> <enabled>true</enabled> <unicast-only-flag>true</unicast-only-flag> <managed-flag>true</managed-flag> <other-config-flag>true</other-config-flag> <link-mtu>1500</link-mtu> <on-link-flag>true</on-link-flag> <autonomous-flag>false</autonomous-flag> <rdnsses> <rdnss>2001:db8::1</rdnss> </rdnsses> <routes> <route>2001:db8:1234::/48</route> <preferred>high</preferred> </routes> </global-router-advertisement> </top> </data></rpc-reply>Modify RADV Global Attributes
Section titled “Modify RADV Global Attributes”Request example to modify global RADV attributes via edit-config with merge operation.
<config><top> <global-router-advertisement operation="merge"> <unicast-only-flag>false</unicast-only-flag> <managed-flag>false</managed-flag> <other-config-flag>false</other-config-flag> <link-mtu>6000</link-mtu> <on-link-flag>false</on-link-flag> </global-router-advertisement></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:13cbb602-0c94-487a-9dbf-a1762db39e87"> <ok/></rpc-reply>Create RADV And Set Attributes for Vlanif
Section titled “Create RADV And Set Attributes for Vlanif”RADV is only supported for Vlanif.
Request example to create RADV and set attributes for Vlanif via edit-config.
<config><top> <vlans> <vlan operation="create"> <vlanid>100</vlanid> </vlan> </vlans> <interfaces> <interface operation="merge"> <name>Vlan100</name> <interface-mode>routed</interface-mode> <ipv6> <router-advertisement operation="create"> <managed-flag>true</managed-flag> <other-config-flag>true</other-config-flag> <on-link-flag>true</on-link-flag> <autonomous-flag>true</autonomous-flag> <rdnsses> <rdnss>2222:db8::1</rdnss> </rdnsses> <routes> <route>3333:db8:1234::/48</route> <preferred>high</preferred> </routes> <prefixes> <prefix>3000::/64</prefix> </prefixes> </router-advertisement> </ipv6> </interface> </interfaces></top></config>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:c8890522-c2e0-4015-b4dc-3ec9b73ef6d0"> <ok/></rpc-reply>Get RADV Status for Vlanif
Section titled “Get RADV Status for Vlanif”Request example to get RADV status for Vlanif via get-config with subtree filter.
<filter type="subtree"> <top> <interfaces> <interface> <name>Vlan100</name> <ipv6> <router-advertisement> </router-advertisement> </ipv6> </interface> </interfaces> </top></filter>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:3e03658a-5c91-4399-aeeb-774b03bdd382"> <data> <top> <interfaces xmlns="http://asterfusion.com/ns/yang/asternos-interfaces"> <interface> <name>Vlan100</name> <ipv6 xmlns="http://asterfusion.com/ns/yang/asternos-ip"> <router-advertisement> <managed-flag>true</managed-flag> <other-config-flag>true</other-config-flag> <on-link-flag>true</on-link-flag> <autonomous-flag>true</autonomous-flag> <prefixes> <prefix>3000::/64</prefix> </prefixes> <rdnsses> <rdnss>2222:db8::1</rdnss> </rdnsses> <routes> <route>3333:db8:1234::/48</route> <preferred>high</preferred> </routes> </router-advertisement> </ipv6> </interface> </interfaces> </top> </data></rpc-reply>Delete RADV for Vlanif
Section titled “Delete RADV for Vlanif”Request example to delete RADV for Vlanif via edit-config.
<config><top> <interfaces> <interface> <name>Vlan100</name> <ipv6> <router-advertisement operation="delete"> </router-advertisement> </ipv6> </interface> </interfaces></top></config><rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:ea5228f8-11c9-485d-9186-879540f93faf"> <ok/></rpc-reply>Show RADV Status
Section titled “Show RADV Status”Request example to show RADV status via rpc show-radv-summary.
<show-radv-summary/>Response example
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:42cbaa54-adf3-4f7d-95d9-14f33f953afc"> <data xmlns="http://asterfusion.com/ns/yang/asternos-radv"> Enabled: true Global unicast only: false +-------------+----------+----------------+--------------------+-----------+-----------------+------------+-------------+-------------------------+ | Interface | Prefix | Managed_Flag | Otherconfig_Flag | OffLink | No-autonomous | Link_MTU | RDNSS | Route | Preference | +=============+==========+================+====================+===========+=================+============+=============+=========================+ | global | | off | off | on | on | 6000 | 2001:db8::1 | 2001:db8:1234::/48|high | +-------------+----------+----------------+--------------------+-----------+-----------------+------------+-------------+-------------------------+ </data></rpc-reply>Properties Descriptions
Section titled “Properties Descriptions”Global Router Advertisement
Section titled “Global Router Advertisement”Tree Diagram
module: asternos-radv +--rw global-router-advertisement +--rw enabled? boolean +--rw unicast-only-flag? boolean +--rw managed-flag? boolean +--rw other-config-flag? boolean +--rw link-mtu? cmn:mtu-type +--rw on-link-flag? boolean +--rw autonomous-flag? boolean +--rw rdnsses* [rdnss] | +--rw rdnss inet:ipv6-address-no-zone +--rw routes* [route] +--rw route inet:ipv6-prefix +--rw preferred? enumerationTable of Properties
| Name | Required | Type/Range | Description |
|---|---|---|---|
| global-router-advertisement | M | Path-only node, has no configurable value. | |
| enabled | O | ”true" "false” | A flag indicating whether or not the router sends periodic Router Advertisements and responds to Router Solicitations. Default value: False |
| unicast-only-flag | O | ”true" "false” | Set if RADVD advertise global unicast prefix only or not. Default value: False |
| managed-flag | O | ”true" "false” | The value to be placed in the ‘Managed address configuration’ flag field in the Router Advertisement. Default value: False |
| other-config-flag | O | ”true" "false” | The value to be placed in the ‘Other configuration’ flag field in the Router Advertisement. Default value: False |
| link-mtu | O | cmn:mtu-type | The value to be placed in MTU options sent by the router. A value of zero indicates that no MTU options are sent. Default value: 9216 |
| on-link-flag | O | ”true" "false” | The value to be placed in the on-link flag (‘L-bit’) field in the Prefix Information option. Default value: True |
| autonomous-flag | O | ”true" "false” | The value to be placed in the Autonomous Flag field in the Prefix Information option. Default value: True |
| rdnsses | M | Path-only node, has no configurable value. Support for an advertised prefix entry. | |
| rdnss | O | inet:ipv6-address-no-zone | IPv6 address. |
| routes | M | Path-only node, has no configurable value. Support for an advertised prefix entry. | |
| route | O | inet:ipv6-prefix | IPv6 address prefix. |
| preferred | O | ”low" "medium" "high” | The value to be placed in the Route Preference in the Route Information option. The preference associated with the default router, as either ‘low’, ‘medium’, or ‘high’. Default value: medium |
Support for an advertised prefix entry
Section titled “Support for an advertised prefix entry”Tree Diagram
module: asternos-radv +--rw global-router-advertisement +--rw rdnsses* [rdnss] +--rw rdnss inet:ipv6-address-no-zoneTable of Properties
| Name | Required | Type/Range | Description |
|---|---|---|---|
| rdnsses | M | Path-only node, has no configurable value. Support for an advertised prefix entry. | |
| rdnss | O | inet:ipv6-address-no-zone | IPv6 address. |
Support for an advertised prefix entry
Section titled “Support for an advertised prefix entry”Tree Diagram
module: asternos-radv +--rw global-router-advertisement +--rw routes* [route] +--rw route inet:ipv6-prefix +--rw preferred? enumerationTable of Properties
| Name | Required | Type/Range | Description |
|---|---|---|---|
| routes | M | Path-only node, has no configurable value. Support for an advertised prefix entry. | |
| route | O | inet:ipv6-prefix | IPv6 address prefix. |
| preferred | O | ”low" "medium" "high” | The value to be placed in the Route Preference in the Route Information option. The preference associated with the default router, as either ‘low’, ‘medium’, or ‘high’. Default value: medium |
Show Radv Summary
Section titled “Show Radv Summary”Tree Diagram
module: asternos-radv
rpcs: +---x show-radv-summary +--ro output +--ro data? <anydata>Table of Properties
| Name | Required | Type/Range | Description |
|---|---|---|---|
| show-radv-summary | O | ||
| data | O | A table that shows information of all RADV configurations. |