No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

NETCONF YANG API Reference

AR100, AR120, AR160, AR1200, AR2200, AR3200, and AR3600 V300R003

NETCONF YANG API Reference
Rate and give feedback :
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Static Route

Static Route

Data Model

The data model files matching the static route definition are ietf-routing.yang and ietf-ipv4-unicast-routing.yang.

Table 3-393 Static route

Object

Description

ietf-routing:routing

Indicates that the operation request (creating, deleting, and modifying) object is the relevant static route configurations. It is only used to contain sub-objects, but does not have any data meaning.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/destination-prefix

Indicates the destination IP address and mask length of a static route. It is in the format of X.X.X.X/Y with Y ranging from 0 to 32.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/outgoing-interface

Indicates the interface that forwards packets.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-address

Indicates the next hop IP address of a route.The value is in dotted decimal notation.

ietf-routing:routing/routing-instance/name

Indicates the VPN instance name. The value is a string of 1 to 31 case-sensitive characters, spaces not supported. When double quotation marks are used around the string, spaces are allowed in the string. If the name of a VPN instance is default-routing-instance, it is the public network route.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-nexthop/outgoing-interface

Indicates the interface that forwards packets.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-nexthop/nexthop-option

Indicates whether the DHCP is configured. When the value is set to none, indicating that no linkage will be made, the configured route is the outbound interface of a single next hop.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-nexthop/preference

Indicates the priority of the static routing protocol. The value is an integer that ranges from 1 to 255. A smaller value indicates a higher priority.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-nexthop/route-track-parameters

Indicates the NQA test instance associated with a static route.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-nexthop/route-track-parameters/nqa-admin-name

Indicates the administrator name of the NQA test instance associated with a static route.The value is a string of 1 to 32 case-sensitive characters without any space.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-nexthop/route-track-parameters/nqa-test-name

Indicates the name of the NQA test instance associated with a static route.The value is a string of 1 to 32 case-sensitive characters without any space.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:ipv4-address-nexthop/next-hop-address

Indicates the next hop IP address of a route.The value is in dotted decimal notation.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:ipv4-address-nexthop/preference

Indicates the priority of the static routing protocol. The value is an integer that ranges from 1 to 255. A smaller value indicates a higher priority.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:ipv4-address-nexthop/route-track-parameters

Indicates the NQA test instance associated with a static route.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:ipv4-address-nexthop/route-track-parameters/nqa-admin-name

Indicates the administrator name of the NQA test instance associated with a static route.The value is a string of 1 to 32 case-sensitive characters without any space.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:ipv4-address-nexthop/route-track-parameters/nqa-test-name

Indicates the name of the NQA test instance associated with a static route.The value is a string of 1 to 32 case-sensitive characters without any space.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-ipv4-nexthop/outgoing-interface

Indicates the interface that forwards packets.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-ipv4-nexthop/next-hop-address

Indicates the next hop IP address of a route.The value is in dotted decimal notation.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-ipv4-nexthop/preference

Indicates the priority of the static routing protocol. The value is an integer that ranges from 1 to 255. A smaller value indicates a higher priority.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-ipv4-nexthop/route-track-parameters

Indicates the NQA test instance associated with a static route.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-ipv4-nexthop/route-track-parameters/nqa-admin-name

Indicates the administrator name of the NQA test instance associated with a static route.The value is a string of 1 to 32 case-sensitive characters without any space.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-interface-ipv4-nexthop/route-track-parameters/nqa-test-name

Indicates the name of the NQA test instance associated with a static route.The value is a string of 1 to 32 case-sensitive characters without any space.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-routing-instance-ipv4-nexthop/dest-routing-instance

Indicates the next hop VPN instance name. The value is a string of 1 to 31 case-sensitive characters without spaces. The character string can contain spaces if it is enclosed with double quotation marks (").When the value is set to default-routing-instance, it is the next hop of a public network.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-routing-instance-ipv4-nexthop/next-hop-address

Indicates the next hop IP address of a route.The value is in dotted decimal notation.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-routing-instance-ipv4-nexthop/preference

Indicates the priority of the static routing protocol. The value is an integer that ranges from 1 to 255. A smaller value indicates a higher priority.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-routing-instance-ipv4-nexthop/route-track-parameters

Indicates the NQA test instance associated with a static route.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-routing-instance-ipv4-nexthop/route-track-parameters/nqa-admin-name

Indicates the administrator name of the NQA test instance associated with a static route.The value is a string of 1 to 32 case-sensitive characters without any space.

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route/next-hop/next-hop-options/huawei-ipv4-static-route:egress-routing-instance-ipv4-nexthop/route-track-parameters/nqa-test-name

Indicates the name of the NQA test instance associated with a static route.The value is a string of 1 to 32 case-sensitive characters without any space.

Configuring the Outbound Interface for a Static Route

Configuring the Outbound Interface for a Static Route

This section provides a sample of configuring the outbound interface for a static.

Table 3-394 Configuring the outbound interface for a static route

Operation

XPATH

edit-config:merge

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance

Data Requirements
Table 3-395 Configuring GigabitEthernet0/0/6 as the outbound interface for a static route

Item

Data

Description

Destination IP address and mask length

101.21.242.136/24

Set the destination IP address of the static route to 101.21.242.136/24, and outbound interface to GigabitEthernet0/0/6. Configure the route as a public network route.

Interface name

GigabitEthernet0/0/6

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0">
   <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <interface xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="merge">
     <name>GigabitEthernet0/0/6</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:iana-if-type">x:ethernetCsmacd</type>
    </interface>
   </interfaces>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:default-routing-instance</type>
     <enabled>true</enabled>
     <interfaces>
      <interface>GigabitEthernet0/0/6</interface>
     </interfaces>
     <routing-protocols>
      <routing-protocol xc:operation="merge">
       <type>static</type>
       <name>default0</name>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <next-hop>
           <outgoing-interface>GigabitEthernet0/0/6</outgoing-interface>
          </next-hop>
          <destination-prefix>101.21.242.136/24</destination-prefix>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4"> 
  <ok/> 
</rpc-reply> 
Modifying the Outbound Interface for a Static Route

This section provides a sample of modifying the outbound interface for a static.

Table 3-396 Modifying the outbound interface for a static route

Operation

XPATH

edit-config:replace

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance

Data Requirements
Table 3-397 Modifying the outbound interface for a static route

Item

Data

Description

Destination IP address and mask length

101.21.242.136/24

Modify the outbound interface for the static route of which the destination IP address is 101.21.242.136/24 to GigabitEthernet0/0/5.

Interface name

GigabitEthernet0/0/5

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0">
   <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <interface xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="merge">
     <name>GigabitEthernet0/0/5</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:iana-if-type">x:ethernetCsmacd</type>
    </interface>
   </interfaces>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:default-routing-instance</type>
     <enabled>true</enabled>
     <interfaces>
      <interface>GigabitEthernet0/0/5</interface>
     </interfaces>
     <routing-protocols>
      <routing-protocol xc:operation="replace">
       <type>static</type>
       <name>default0</name>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <next-hop>
           <outgoing-interface>GigabitEthernet0/0/5</outgoing-interface>
          </next-hop>
          <destination-prefix>101.21.242.136/24</destination-prefix>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4"> 
  <ok/> 
</rpc-reply> 
Deleting the Outbound interface for a Static Route

This section provides a sample of deleting the outbound interface for a static route.

Table 3-398 Deleting the outbound interface for a static route

Operation

XPATH

edit-config:remove

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance

Data Requirements
Table 3-399 Deleting the outbound interface for a static route

Item

Data

Description

Destination IP address and mask length

101.21.242.136/24

Delete the static route of which the destination IP address and mask are 101.21.242.136/24 and the outbound interface is GigabitEthernet0/0/5.

Interface name

GigabitEthernet0/0/5

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0">
   <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <interface xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="remove">
     <name>GigabitEthernet0/0/5</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:iana-if-type">x:ethernetCsmacd</type>
    </interface>
   </interfaces>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:default-routing-instance</type>
     <enabled>true</enabled>
     <interfaces>
      <interface>GigabitEthernet0/0/5</interface>
     </interfaces>
     <routing-protocols>
      <routing-protocol xc:operation="remove">
       <type>static</type>
       <name>default0</name>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <next-hop>
           <outgoing-interface>GigabitEthernet0/0/5</outgoing-interface>
          </next-hop>
          <destination-prefix>101.21.242.136/24</destination-prefix>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4"> 
  <ok/> 
</rpc-reply> 

Configuring the Next Hop IP Address of a Static Route

Configuring the Next Hop IP Address of a Static Route

This section provides a sample of configuring the next hop IP address of a static route.

Table 3-400 Configuring the next hop IP address of a static route

Operation

XPATH

edit-config:merge

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-401 Configuring the next hop IP address of a static route

Item

Data

Description

Destination IP address and mask length

101.21.242.136/24

Set the destination IP address and next hop IP address of a static route to 101.21.242.136/24 and 10.1.1.2, respectively. Configure the route as a public network route.

Next hop IP address

10.1.1.2

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0">
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:default-routing-instance</type>
     <enabled>true</enabled>
     <routing-protocols>
      <routing-protocol xc:operation="merge">
       <type>static</type>
       <name>default0</name>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <next-hop>
           <next-hop-address>10.1.1.2</next-hop-address>
          </next-hop>
          <destination-prefix>101.21.242.136/24</destination-prefix>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4"> 
  <ok/> 
</rpc-reply> 
Modifying the Next Hop IP Address of a Static Route

This section provides a sample of modifying the next hop IP address of a static route.

Table 3-402 Modifying the next hop IP address of a static route

Operation

XPATH

edit-config:replace

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-403 Modifying the next hop IP address of a static route

Item

Data

Description

Destination IP address and mask length

101.21.242.136/24

Modify the next hop IP address of the static route of which the destination IP address is 101.21.242.136/24 to 100.1.1.2.

Next hop IP address

100.1.1.2

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0">
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:default-routing-instance</type>
     <enabled>true</enabled>
     <routing-protocols>
      <routing-protocol xc:operation="remove">
       <type>static</type>
       <name>default0</name>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <next-hop>
           <next-hop-address>10.1.1.2</next-hop-address>
          </next-hop>
           <destination-prefix>101.21.242.136/24</destination-prefix>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4"> 
  <ok/> 
</rpc-reply> 
Deleting the Next Hop IP Address of a Static Route

This section provides a sample of deleting the Next Hop IP Address of a Static Route.

Table 3-404 Deleting the next hop IP address of a static Route

Operation

XPATH

edit-config:remove

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-405 Deleting the next hop IP address of a static Route

Item

Data

Description

Destination IP address and mask length

101.21.242.136/24

Delete the static route of which the destination IP address and mask are 101.21.242.136/24 and the next hop IP address is 100.1.1.2.

Next hop IP address

100.1.1.2

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0">
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:default-routing-instance</type>
     <enabled>true</enabled>
     <routing-protocols>
      <routing-protocol xc:operation="replace">
       <type>static</type>
       <name>default0</name>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <next-hop>
           <next-hop-address>100.1.1.2</next-hop-address>
          </next-hop>
          <destination-prefix>101.21.242.136/24</destination-prefix>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_5c58e95e243e4ed1b6a2dc7d7c5f23a4"> 
  <ok/> 
</rpc-reply> 

Configuring Association Between DHCP and the Outbound Interface of a Static Route

Creating Association Between DHCP and the Outbound Interface of a Static Route

This section provides a sample of creating association between DHCP and the outbound interface of a static route.

Table 3-406 Creating association between DHCP and the outbound interface of a static route

Operation

XPATH

edit-config:merge

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance

Data Requirements
Table 3-407 Creating association between DHCP and the outbound interface of a static route

Item

Data

Description

Destination IP address and mask length

23.10.110.30/32

Create a static route with the destination IP address and next hop outbound interface of 23.10.110.30/32 and GigabitEthernet0/0/3, respectively. Associate the route with DHCP. Set the priority to 70, administrator name of the NQA test instance associated with the route to adminName1, and the test instance name to testName1. Configure the route as a public network route.

Interface name

GigabitEthernet0/0/3

Association with DHCP

dhcp

Priority of the static route

70

Association between NQA and the outbound interface route

-

Name of the administrator for the NQA test instance

adminName1

Name of the NQA test instance

testName1

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_69b9226383d944c481b72439df58b7ed">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0">
   <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <interface>
     <name>GigabitEthernet0/0/3</name>
     <type xmlns:iana="urn:ietf:params:xml:ns:yang:iana-if-type">iana:ethernetCsmacd</type>
    </interface>
   </interfaces>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <routing-protocols>
      <routing-protocol xc:operation="merge">
       <type xmlns:rt="urn:ietf:params:xml:ns:yang:ietf-routing">rt:static</type>
       <name>6052b335b62949dcb457e4acca05e0c2</name>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
        <route>
         <destination-prefix>23.10.110.30/32</destination-prefix>
          <next-hop>
           <egress-interface-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <outgoing-interface xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">GigabitEthernet0/0/3</outgoing-interface>
            <nexthop-option xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">dhcp</nexthop-option>
            <preference xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">70</preference>
            <route-track-parameters>
             <nqa-admin-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">adminName1</nqa-admin-name>
             <nqa-test-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">testName1</nqa-test-name>
            </route-track-parameters>
           </egress-interface-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_69b9226383d944c481b72439df58b7ed"> 
  <ok/> 
</rpc-reply> 
Modifying the Outbound Interface of a Static Route Associated with DHCP

This section provides a sample of modifying the outbound interface of a static route associated with DHCP

Table 3-408 Modifying the outbound interface of a static route associated with DHCP

Operation

XPATH

edit-config:replace

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance

Data Requirements
Table 3-409 Modifying the outbound interface of a static route associated with DHCP

Item

Data

Description

Destination IP address and mask length

23.10.110.30/32

Modify the next hop outbound interface of the static route with the destination IP address of 23.10.110.30/32 to GigabitEthernet0/0/4. Associate the route with DHCP. Set the priority to 70, administrator name of the NQA test instance associated with the route to adminName1, and the test instance name to testName1. Configure the route as a public network route.

Interface name

GigabitEthernet0/0/4

Association with DHCP

dhcp

Priority of the static route

70

Association between NQA and the outbound interface route

-

Name of the administrator for the NQA test instance

adminName1

Name of the NQA test instance

testName1

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_69b9226383d944c481b72439df58b7ed">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0">
   <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <interface>
     <name>GigabitEthernet0/0/3</name>
     <type xmlns:iana="urn:ietf:params:xml:ns:yang:iana-if-type">iana:ethernetCsmacd</type>
    </interface>
   </interfaces>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <routing-protocols>
      <routing-protocol xc:operation="remove">
       <type xmlns:rt="urn:ietf:params:xml:ns:yang:ietf-routing">rt:static</type>
       <name>6052b335b62949dcb457e4acca05e0c2</name>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>23.10.110.30/32</destination-prefix>
          <next-hop>
           <egress-interface-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <outgoing-interface xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">GigabitEthernet0/0/3</outgoing-interface>
            <nexthop-option xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">dhcp</nexthop-option>
            <preference xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">70</preference>
            <route-track-parameters>
             <nqa-admin-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">adminName1</nqa-admin-name>
             <nqa-test-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">testName1</nqa-test-name>
            </route-track-parameters>
           </egress-interface-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<?xml version="1.0" encoding="UTF-8"?> 
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_69b9226383d944c481b72439df58b7ed"> 
  <ok/> 
</rpc-reply> 
Deleting a Static Route Associated with DHCP

This section provides a sample of deleting a static route associated with DHCP.

Table 3-410 Deleting a static route associated with DHCP

Operation

XPATH

edit-config:remove

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance

Data Requirements
Table 3-411 Deleting a static route associated with DHCP

Item

Data

Description

Destination IP address and mask length

23.10.110.30/32

Delete the static route of which the destination IP address is 23.10.110.30/32.

Interface name

GigabitEthernet0/0/4

Association with DHCP

dhcp

Priority of the static route

70

Association between NQA and the outbound interface route

-

Name of the administrator for the NQA test instance

adminName1

Name of the NQA test instance

testName1

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_69b9226383d944c481b72439df58b7ed">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0">
   <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <interface>
     <name>GigabitEthernet0/0/4</name>
     <type xmlns:iana="urn:ietf:params:xml:ns:yang:iana-if-type">iana:ethernetCsmacd</type>
    </interface>
   </interfaces>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <routing-protocols>
      <routing-protocol xc:operation="remove">
       <type xmlns:rt="urn:ietf:params:xml:ns:yang:ietf-routing">rt:static</type>
       <name>6052b335b62949dcb457e4acca05e0c2</name>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>23.10.110.30/32</destination-prefix>
          <next-hop>
           <egress-interface-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <outgoing-interface xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">GigabitEthernet0/0/4</outgoing-interface>
            <nexthop-option xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">dhcp</nexthop-option>
            <preference xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">70</preference>
            <route-track-parameters>
             <nqa-admin-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">adminName1</nqa-admin-name>
             <nqa-test-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">testName1</nqa-test-name>
            </route-track-parameters>
           </egress-interface-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="DEVICECONFIG_69b9226383d944c481b72439df58b7ed"> 
  <ok/> 
</rpc-reply> 

Configuring Association Between the Next Hop IP Address of a Static Route and an NQA Test Instance

Creating Association Between the Next Hop IP Address of a Static Route and an NQA Test Instance

This section provides a sample of creating association between the next hop IP address of a static route and an NQA test instance.

Table 3-412 Creating association between the next hop IP address of a static route and an NQA test instance

Operation

XPATH

edit-config:merge

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-413 Creating association between the next hop IP address of a static route and an NQA test instance

Item

Data

Description

Destination IP address and mask length

119.131.181.21/32

Create a static route with the destination IP address and next hop IP address of 119.131.181.21/32 and 4.5.6.6, respectively. Set the priority to 70, administrator name of the NQA test instance associated with the route to adminName1, and the NQA test instance name to testName1. Configure the route as a public network route.

Next hop IP address

4.5.6.6

Priority of the static route

70

Association between NQA and the outbound interface route

-

Name of the administrator for the NQA test instance

adminName1

Name of the NQA test instance

testName1

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <routing-protocols>
      <routing-protocol xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="merge">
       <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:static</type>
       <name>9b5d839e8eb54740a24b2fcc353b6fcc</name>
       <enabled>true</enabled>
       <route-preference>70</route-preference>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>119.131.181.21/32</destination-prefix>
          <next-hop>
           <ipv4-address-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <next-hop-address>4.5.6.6</next-hop-address>
            <preference xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">70</preference>
            <route-track-parameters>
             <nqa-admin-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">adminName1</nqa-admin-name>
             <nqa-test-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">testName1</nqa-test-name>
            </route-track-parameters>
           </ipv4-address-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<?xml version="1.0" encoding="UTF-8"?> 
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255"> 
  <ok/> 
</rpc-reply> 
Modifying the Next Hop IP Address of a Static Route Associated with an NQA Test Instance

This section provides a sample of modifying the next hop IP address of a static route associated with an NQA test instance

Table 3-414 Modifying the next hop IP address of a static route associated with an NQA test instance

Operation

XPATH

edit-config:replace

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-415 Modifying the next hop IP address of a static route associated with an NQA test instance

Item

Data

Description

Destination IP address and mask length

119.131.181.21/32

Modify the next hop IP address of the static route of which the destination IP address is 119.131.181.21/32 to 14.5.6.6. Set the priority to 70, administrator name of the NQA test instance associated with the route to adminName1, and the NQA test instance name to testName1. Configure the route as a public network route.

Next hop IP address

14.5.6.6

Priority of the static route

70

Association between NQA and the outbound interface route

-

Name of the administrator for the NQA test instance

adminName1

Name of the NQA test instance

testName1

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <routing-protocols>
      <routing-protocol xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="replace">
       <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:static</type>
       <name>9b5d839e8eb54740a24b2fcc353b6fcc</name>
       <enabled>true</enabled>
       <route-preference>70</route-preference>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>119.131.181.21/32</destination-prefix>
          <next-hop>
          <ipv4-address-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <next-hop-address>14.5.6.6</next-hop-address>
            <preference xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">70</preference>
            <route-track-parameters>
             <nqa-admin-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">adminName1</nqa-admin-name>
             <nqa-test-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">testName1</nqa-test-name>
            </route-track-parameters>
           </ipv4-address-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<?xml version="1.0" encoding="UTF-8"?> 
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255"> 
  <ok/> 
</rpc-reply> 
Deleting a Static Route Associated with an NQA Test Instance

This section provides a sample of deleting a static route associated with an NQA test instance.

Table 3-416 Deleting a static route associated with an NQA test instance

Operation

XPATH

edit-config:remove

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-417 Deleting a static route associated with an NQA test instance

Item

Data

Description

Destination IP address and mask length

119.131.181.21/32

Delete the static route of which the destination IP address is 119.131.181.21/32.

Next hop IP address

14.5.6.6

Priority of the static route

70

Association between NQA and the outbound interface route

-

Name of the administrator for the NQA test instance

adminName1

Name of the NQA test instance

testName1

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <routing-protocols>
      <routing-protocol xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="remove">
       <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:static</type>
       <name>9b5d839e8eb54740a24b2fcc353b6fcc</name>
       <enabled>true</enabled>
       <route-preference>70</route-preference>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>119.131.181.21/32</destination-prefix>
          <next-hop>
           <ipv4-address-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <next-hop-address>14.5.6.6</next-hop-address>
            <preference xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">70</preference>
            <route-track-parameters>
             <nqa-admin-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">adminName1</nqa-admin-name>
             <nqa-test-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">testName1</nqa-test-name>
            </route-track-parameters>
           </ipv4-address-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255"> 
  <ok/> 
</rpc-reply> 

Configuring a Static Route with Multiple Next Hops Associated with an NQA Test Instance

Creating a Static Route with Multiple Next Hops Associated with an NQA Test Instance

This section provides a sample of creating a static route with multiple next hops associated with an NQA test instance.

Table 3-418 Creating a static route with multiple next hops associated with an NQA test instance

Operation

XPATH

edit-config:merge

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-419 Creating a static route with multiple next hops associated with an NQA test instance

Item

Data

Description

Destination IP address and mask length

119.131.166.131/24

Create a static route with the destination IP address of 119.131.166.131/24. Set the next hop outbound interface to GigabitEthernet0/0/2, next hop IP address to 1.1.1.1, priority to 10, administrator name of the NQA test instance associated with the route to adminName1, and NQA test instance name to testName1. Configure the route as a public network route.

Interface name

GigabitEthernet0/0/2

Next hop IP address

1.1.1.1

Priority of the static route

10

Association between NQA and the outbound interface route

-

Name of the administrator for the NQA test instance

adminName1

Name of the NQA test instance

testName1

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="9912ae72-9c09-4ab4-a3e1-246e8fda0ae0">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config>
   <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <interface xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0">
     <name>GigabitEthernet0/0/2</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:iana-if-type">x:ethernetCsmacd</type>
    </interface>
   </interfaces>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="merge">
     <name>default-routing-instance</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:default-routing-instance</type>
     <enabled>true</enabled>
     <interfaces>
      <interface>GigabitEthernet0/0/2</interface>
     </interfaces>
     <routing-protocols>
      <routing-protocol>
       <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:static</type>
        <name>def636bd1fdb438facd5924d63f0a34e</name>
        <enabled>true</enabled>
        <static-routes>
         <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
          <route>
           <destination-prefix>119.131.166.131/24</destination-prefix>
           <next-hop>
            <egress-interface-ipv4-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
             <outgoing-interface>GigabitEthernet0/0/2</outgoing-interface>
             <next-hop-address>1.1.1.1</next-hop-address>
             <preference>10</preference>
             <route-track-parameters>
              <nqa-admin-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">adminName1</nqa-admin-name>
              <nqa-test-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">testName1</nqa-test-name>
            </route-track-parameters>
           </egress-interface-ipv4-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="9912ae72-9c09-4ab4-a3e1-246e8fda0ae0"> 
  <ok/> 
</rpc-reply> 
Modifying Configuration of a Static Route with Multiple Next Hops Associated with an NQA Test Instance

This section provides a sample of modifying configuration of a static route with multiple next hops associated with an NQA test instance.

Table 3-420 Modifying configuration of a static route with multiple next hops associated with an NQA test instance

Operation

XPATH

edit-config:replace

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-421 Modifying configuration of a static route with multiple next hops associated with an NQA test instance

Item

Data

Description

Destination IP address and mask length

119.131.166.131/24

Modify the next hop IP address of the static route of which the destination IP address and next hop outbound interface are 119.131.166.131/24 and GigabitEthernet0/0/2, respectively, to 2.1.1.1. Set the priority to 10, administrator name of the NQA test instance associated with the route to adminName2, and NQA test instance name to testName2. Configure the route as a public network route.

Interface name

GigabitEthernet0/0/2

Next hop IP address

2.1.1.1

Priority of the static route

10

Association between NQA and the outbound interface route

-

Name of the administrator for the NQA test instance

adminName2

Name of the NQA test instance

testName2

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="9912ae72-9c09-4ab4-a3e1-246e8fda0ae0">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config>
   <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <interface xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0">
     <name>GigabitEthernet0/0/2</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:iana-if-type">x:ethernetCsmacd</type>
    </interface>
   </interfaces>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="replace">
     <name>default-routing-instance</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:default-routing-instance</type>
     <enabled>true</enabled>
     <interfaces>
      <interface>GigabitEthernet0/0/2</interface>
     </interfaces>
     <routing-protocols>
      <routing-protocol>
       <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:static</type>
       <name>def636bd1fdb438facd5924d63f0a34e</name>
       <enabled>true</enabled>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>119.131.166.131/24</destination-prefix>
          <next-hop>
           <egress-interface-ipv4-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <outgoing-interface>GigabitEthernet0/0/2</outgoing-interface>
            <next-hop-address>2.1.1.1</next-hop-address>
            <preference>10</preference>
            <route-track-parameters>
             <nqa-admin-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">adminName2</nqa-admin-name>
             <nqa-test-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">testName2</nqa-test-name>
            </route-track-parameters>
           </egress-interface-ipv4-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<?xml version="1.0" encoding="UTF-8"?> 
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="9912ae72-9c09-4ab4-a3e1-246e8fda0ae0"> 
  <ok/> 
</rpc-reply> 
Deleting a Static Route with Multiple Next Hops Associated with an NQA Test Instance

This section provides a sample of deleting a static route with multiple next hops associated with an NQA test instance.

Table 3-422 Deleting a static route with multiple next hops associated with an NQA test instance

Operation

XPATH

edit-config:remove

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-423 Deleting a static route with multiple next hops associated with an NQA test instance

Item

Data

Description

Destination IP address and mask length

119.131.166.131/24

Delete the static route of which the destination IP address is 119.131.166.131/24.

Interface name

GigabitEthernet0/0/2

Next hop IP address

2.1.1.1

Priority of the static route

10

Association between NQA and the outbound interface route

-

Name of the administrator for the NQA test instance

adminName2

Name of the NQA test instance

testName2

VPN instance name

default-routing-instance

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="9912ae72-9c09-4ab4-a3e1-246e8fda0ae0">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config>
   <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
    <interface xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0">
     <name>GigabitEthernet0/0/2</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:iana-if-type">x:ethernetCsmacd</type>
    </interface>
   </interfaces>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="remove">
     <name>default-routing-instance</name>
     <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:default-routing-instance</type>
     <enabled>true</enabled>
     <interfaces>
      <interface>GigabitEthernet0/0/2</interface>
     </interfaces>
     <routing-protocols>
      <routing-protocol>
       <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:static</type>
       <name>def636bd1fdb438facd5924d63f0a34e</name>
       <enabled>true</enabled>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>119.131.166.131/24</destination-prefix>
          <next-hop>
           <egress-interface-ipv4-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <outgoing-interface>GigabitEthernet0/0/2</outgoing-interface>
            <next-hop-address>2.1.1.1</next-hop-address>
            <preference>10</preference>
            <route-track-parameters>
             <nqa-admin-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">adminName2</nqa-admin-name>
             <nqa-test-name xmlns="urn:huawei:params:xml:ns:yang:huawei-route-protection">testName2</nqa-test-name>
            </route-track-parameters>
           </egress-interface-ipv4-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<?xml version="1.0" encoding="UTF-8"?> 
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="9912ae72-9c09-4ab4-a3e1-246e8fda0ae0"> 
  <ok/> 
</rpc-reply> 

Specifying a VPN Instance for a Static Route with Multiple Next Hops

Creating a Static Route with Multiple Next Hops and Specifying a VPN Instance

This section provides a sample of creating a static route with multiple next hops and specifying a VPN instance.

Table 3-424 Creating a static route with multiple next hops and specifying a VPN instance

Operation

XPATH

edit-config:merge

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-425 Creating a static route with multiple next hops and specifying a VPN instance

Item

Data

Description

Destination IP address and mask length

119.131.181.21/32

Create a static route with the destination IP address of 119.131.181.21/32. Set the VPN instance name to vpnaaaa, and next hop IP address to 4.5.6.6.

VPN instance name

vpnaaaa

Next hop IP address

4.5.6.6

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <routing-protocols>
      <routing-protocol xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="merge">
       <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:static</type>
       <name>9b5d839e8eb54740a24b2fcc353b6fcc</name>
       <enabled>true</enabled>
       <route-preference>70</route-preference>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>119.131.181.21/32</destination-prefix>
          <next-hop>
           <egress-routing-instance-ipv4-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <dest-routing-instance>vpnaaaa</dest-routing-instance>
            <next-hop-address>4.5.6.6</next-hop-address>
           </egress-routing-instance-ipv4-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255"> 
  <ok/> 
</rpc-reply> 
Modifying the VPN Instance for a Static Route with Multiple Next Hops

This section provides a sample of modifying the VPN instance for a static route with multiple next hops.

Table 3-426 Modifying the VPN instance for a static route with multiple next hops

Operation

XPATH

edit-config:replace

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-427 Modifying the VPN instance for a static route with multiple next hops

Item

Data

Description

Destination IP address and mask length

119.131.181.21/32

Modify the VPN instance for the static route with the destination IP address of 119.131.181.21/32 to vpnbb. Set the next hop IP address to 4.5.6.6.

VPN instance name

vpnbb

Next hop IP address

4.5.6.6

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config>
   <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
    <routing-instance>
     <name>default-routing-instance</name>
     <routing-protocols>
      <routing-protocol xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="replace">
       <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:static</type>
       <name>9b5d839e8eb54740a24b2fcc353b6fcc</name>
       <enabled>true</enabled>
       <route-preference>70</route-preference>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>119.131.181.21/32</destination-prefix>
          <next-hop>
           <egress-routing-instance-ipv4-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <dest-routing-instance>vpnbb</dest-routing-instance>
            <next-hop-address>4.5.6.6</next-hop-address>
           </egress-routing-instance-ipv4-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255"> 
  <ok/> 
</rpc-reply> 
Deleting a Static Route with Multiple Next Hops and a Specified VPN Instance

This section provides a sample of deleting a static route with multiple next hops and a specified VPN instance.

Table 3-428 Deleting a static route with multiple next hops and a specified VPN instance

Operation

XPATH

edit-config:remove

ietf-routing:routing/routing-instance/routing-protocols/routing-protocol/static-routes/ietf-ipv4-unicast-routing:ipv4/route

ietf-routing:routing/routing-instance/name

Data Requirements
Table 3-429 Deleting a static route with multiple next hops and a specified VPN instance

Item

Data

Description

Destination IP address and mask length

119.131.181.21/32

Delete the static route of which the destination IP address is 119.131.181.21/32.

VPN instance name

vpnbb

Next hop IP address

4.5.6.6

Request Example
<rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255">
 <edit-config>
  <target>
   <running/>
  </target>
  <error-option>rollback-on-error</error-option>
  <config>
  <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
   <routing-instance>
    <name>default-routing-instance</name>
     <routing-protocols>
      <routing-protocol xmlns:ns0="urn:ietf:params:xml:ns:netconf:base:1.0" ns0:operation="remove">
       <type xmlns:x="urn:ietf:params:xml:ns:yang:ietf-routing">x:static</type>
       <name>9b5d839e8eb54740a24b2fcc353b6fcc</name>
       <enabled>true</enabled>
       <route-preference>70</route-preference>
       <static-routes>
        <ipv4 xmlns="urn:ietf:params:xml:ns:yang:ietf-ipv4-unicast-routing">
         <route>
          <destination-prefix>119.131.181.21/32</destination-prefix>
          <next-hop>
           <egress-routing-instance-ipv4-nexthop xmlns="urn:huawei:params:xml:ns:yang:hw-ipv4-static-route">
            <dest-routing-instance>vpnbb</dest-routing-instance>
            <next-hop-address>4.5.6.6</next-hop-address>
           </egress-routing-instance-ipv4-nexthop>
          </next-hop>
         </route>
        </ipv4>
       </static-routes>
      </routing-protocol>
     </routing-protocols>
    </routing-instance>
   </routing>
  </config>
 </edit-config>
</rpc>
Response Example

Sample of successful response

<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="6952ac28-14f1-4236-a2de-d46253d6b255"> 
  <ok/> 
</rpc-reply> 
Translation
Download
Updated: 2019-03-06

Document ID: EDOC1100022096

Views: 8352

Downloads: 69

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next