OcNOS SP : OpenConfig Command Reference : EVPN Openconfig Translation
EVPN Openconfig Translation
Configure EVPN-MAC with inter-instance-policies
This XML configuration snippet is used to configure EVPN-MAC with inter-instance-policies.Use the below commands to configure only the MAC-VRF entry with route-target configured.
Release
This configuration was introduced in OcNOS version 6.1.0.
OpenConfig NetConf Payload
Here is a sample OpenConfig NetConf Payload to configure only the MAC-VRF entry with route-target configured.
<network-instances xmlns="http://openconfig.net/yang/network-instance">
<network-instance>
<name>object-test</name>
<config>
<name>object-test</name>
<type xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:L2L3</type>
<router-id>102.143.73.1</router-id>
<route-distinguisher>102.143.73.1:2</route-distinguisher>
</config>
<encapsulation>
<config>
<encapsulation-type>MPLS</encapsulation-type>
</config>
</encapsulation>
<inter-instance-policies>
<import-export-policy>
<config>
<export-route-target>6:6</export-route-target>
<import-route-target>6:6</import-route-target>
<export-route-target>3:3</export-route-target>
</config>
</import-export-policy>
</inter-instance-policies>
</network-instance>
</network-instances>
OcNOS CLI Command
The below CLI is used to configure only the MAC-VRF entry with route-target configured.
mac vrf object-test
router-id 102.143.73.1
rd 102.143.73.1:2
route-target export 3:3
route-target both 6:6
!
OcNOS NetConf Payload
Here is a sample of OcNOS NetConf Payload to configure only the MAC-VRF entry with route-target configured.
<network-instances xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-network-instance">
<network-instance>
<instance-name>object-test</instance-name>
<instance-type>mac-vrf</instance-type>
<config>
<instance-name>object-test</instance-name>
<instance-type>mac-vrf</instance-type>
</config>
<vrf xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-vrf">
<config>
<vrf-name>object-test</vrf-name>
<router-id>102.143.73.1</router-id>
</config>
<bgp-vrf xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-bgp-vrf">
<config>
<rd-string>102.143.73.1:2</rd-string>
</config>
<route-target>
<rt-rd-string>3:3</rt-rd-string>
<config>
<rt-rd-string>3:3</rt-rd-string>
<direction>export</direction>
</config>
</route-target>
<route-target>
<rt-rd-string>6:6</rt-rd-string>
<config>
<rt-rd-string>6:6</rt-rd-string>
<direction>import export</direction>
</config>
</route-target>
</bgp-vrf>
</vrf>
</network-instance>
</network-instances>
Validation with NetConf get
Here is a NetConf validation response that provides information about configuring only the MAC-VRF entry with route-target configured.
<network-instances xmlns="http://openconfig.net/yang/network-instance">
<network-instance>
<name>object-test</name>
<config>
<name>object-test</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:L2L3</type>
<router-id>102.143.73.1</router-id>
<route-distinguisher>102.143.73.1:2</route-distinguisher>
</config>
<encapsulation>
<config>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</config>
<state>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</state>
</encapsulation>
<state>
<name>object-test</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:L2L3</type>
<router-id>102.143.73.1</router-id>
<route-distinguisher>102.143.73.1:2</route-distinguisher>
</state>
<inter-instance-policies>
<import-export-policy>
<config>
<export-route-target>3:3</export-route-target>
<export-route-target>6:6</export-route-target>
<import-route-target>6:6</import-route-target>
</config>
<state>
<export-route-target>3:3</export-route-target>
<export-route-target>6:6</export-route-target>
<import-route-target>6:6</import-route-target>
</state>
</import-export-policy>
</inter-instance-policies>
</network-instance>
</network-instances>
Restrictions
MAC-VRF entry cannot be configured by OpenConfig without route-target.
The leaves mentioned below must be configured:
network-instances/network-instance/config/router-id
network-instances/network-instance/config/route-distinguisher
Configure EVPN-VPLS type
This XML configuration snippet is used to configure EVPN-VPLS type.
Release
This configuration was introduced in OcNOS version 6.1.0.
Initial Configuration:
Here is the initial configuration necessary to be implemented before applying EVPN-VPLS configuration.
router ldp
!
interface lo
ip address 10.143.73.1/32 secondary
!
interface eth4
ip address 10.255.128.8/31
label-switching
enable-ldp ipv4
!
interface eth2.1001 switchport
encapsulation dot1q 1001
!
ospf area-interface-config-mode
router ospf 100
ospf router-id 10.143.73.1
area 0.0.0.0 interface eth4
area 0.0.0.0 interface lo
OcNOS CLI Command
The below CLI command is used to configure EVPN-VPLS type.
evpn mpls enable
!
mac vrf vpls1001
router-id 10.143.73.1
rd 10.143.73.1:1001
route-target both 1001:1001
!
evpn mpls vtep-ip-global 10.143.73.1
!
evpn mpls id 1001
host-reachability-protocol evpn-bgp vpls1001
!
interface eth2.1001 switchport
encapsulation dot1q 1001
access-if-evpn
map vpn-id 1001
!
router bgp 65010
neighbor 10.143.73.3 remote-as 65010
neighbor 10.143.73.3 update-source lo
!
address-family l2vpn evpn
neighbor 10.143.73.3 activate
exit-address-family
 
OcNOS NetConf Payload
Here is a sample OcNOS NetConf Payload to configure EVPN-VPLS type.
<network-instances xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-network-instance">
<network-instance>
<instance-name>default</instance-name>
<instance-type>vrf</instance-type>
<vrf xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-vrf">
<config>
<vrf-name>default</vrf-name>
</config>
</vrf>
<config>
<instance-name>default</instance-name>
<instance-type>vrf</instance-type>
</config>
</network-instance>
<network-instance>
<instance-name>vpls1001</instance-name>
<instance-type>mac-vrf</instance-type>
<config>
<instance-name>vpls1001</instance-name>
<instance-type>mac-vrf</instance-type>
</config>
<vrf xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-vrf">
<config>
<vrf-name>vpls1001</vrf-name>
</config>
<bgp-vrf xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-bgp-vrf">
<config>
<rd-string>10.143.73.1:1001</rd-string>
</config>
<route-target>
<rt-rd-string>1001:1001</rt-rd-string>
<config>
<rt-rd-string>1001:1001</rt-rd-string>
<direction>import export</direction>
</config>
</route-target>
</bgp-vrf>
</vrf>
</network-instance>
</network-instances>
<bgp xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-bgp">
<bgp-instance>
<bgp-as>65010</bgp-as>
<config>
<bgp-as>65010</bgp-as>
</config>
<peer>
<peer-address>10.143.73.3</peer-address>
<config>
<peer-address>10.143.73.3</peer-address>
<peer-as>65010</peer-as>
<source-identifier>lo</source-identifier>
</config>
<address-family>
<afi>l2vpn</afi>
<safi>evpn</safi>
<config>
<afi>l2vpn</afi>
<safi>evpn</safi>
<activate />
</config>
</address-family>
</peer>
<address-family>
<afi>l2vpn</afi>
<safi>evpn</safi>
<config>
<afi>l2vpn</afi>
<safi>evpn</safi>
</config>
</address-family>
</bgp-instance>
</bgp>
<evpn-mpls xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-evpn-mpls">
<mpls-tenant>
<tenant-identifier>1001</tenant-identifier>
<config>
<vrf-name>vpls1001</vrf-name>
<tenant-identifier>1001</tenant-identifier>
</config>
</mpls-tenant>
<global>
<config>
<enable-evpn-mpls />
<vtep-ipv4>10.143.73.1</vtep-ipv4>
</config>
</global>
</evpn-mpls>
<evpn xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-ethernet-vpn">
<interfaces>
<interface>
<name>eth2.1001</name>
<config>
<name>eth2.1001</name>
</config>
<access-interfaces>
<access-interface>
<access-if>access-if-evpn</access-if>
<config>
<access-if>access-if-evpn</access-if>
<evpn-identifier>1001</evpn-identifier>
</config>
</access-interface>
</access-interfaces>
</interface>
</interfaces>
</evpn>
<interfaces xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-interface">
<interface>
<name>eth2.1001</name>
<config>
<enable-switchport />
</config>
</interface>
</interfaces>
OpenConfig NetConf Payload
Here is a sample OpenConfig NetConf Payload to configure EVPN-VPLS type.
<network-instances xmlns="http://openconfig.net/yang/network-instance">
<network-instance>
<name>default</name>
<config>
<name>default</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:DEFAULT_INSTANCE</type>
</config>
<protocols>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<enabled>true</enabled>
</config>
</protocol>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</identifier>
<name>100</name>
<ospfv2>
<global>
<config>
<router-id>10.143.73.1</router-id>
<log-adjacency-changes>false</log-adjacency-changes>
</config>
</global>
<areas>
<area>
<identifier>0.0.0.0</identifier>
<config>
<identifier>0.0.0.0</identifier>
</config>
<interfaces>
<interface>
<id>eth4</id>
<config>
<id>eth4</id>
</config>
<interface-ref>
<config>
<interface>eth4</interface>
</config>
</interface-ref>
</interface>
<interface>
<id>lo</id>
<config>
<id>lo</id>
</config>
<interface-ref>
<config>
<interface>lo</interface>
</config>
</interface-ref>
</interface>
</interfaces>
</area>
</areas>
</ospfv2>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</identifier>
<name>100</name>
<enabled>true</enabled>
</config>
</protocol>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
<bgp>
<global>
<config>
<as>65010</as>
</config>
<afi-safis>
<afi-safi>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<config>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</config>
</afi-safi>
</afi-safis>
</global>
<neighbors>
<neighbor>
<neighbor-address>10.143.73.3</neighbor-address>
<afi-safis>
<afi-safi>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<config>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</config>
</afi-safi>
</afi-safis>
<config>
<enabled>true</enabled>
<neighbor-address>10.143.73.3</neighbor-address>
<peer-as>65010</peer-as>
</config>
<transport>
<config>
<local-address>lo</local-address>
</config>
</transport>
</neighbor>
</neighbors>
</bgp>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
<enabled>true</enabled>
</config>
</protocol>
</protocols>
<tables>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
</config>
</table>
</tables>
</network-instance>
<network-instance>
<name>vpls1001</name>
<config>
<name>vpls1001</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:L2L3</type>
<router-id>10.143.73.1</router-id>
<route-distinguisher>10.143.73.1:1001</route-distinguisher>
</config>
<encapsulation>
<config>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</config>
</encapsulation>
<inter-instance-policies>
<import-export-policy>
<config>
<export-route-target>1001:1001</export-route-target>
<import-route-target>1001:1001</import-route-target>
</config>
</import-export-policy>
</inter-instance-policies>
<connection-points>
<connection-point>
<connection-point-id>1001</connection-point-id>
<config>
<connection-point-id>1001</connection-point-id>
</config>
<endpoints>
<endpoint>
<endpoint-id>1001</endpoint-id>
<config>
<endpoint-id>1001</endpoint-id>
</config>
<local>
<config>
<interface>eth2</interface>
<subinterface>1001</subinterface>
</config>
</local>
<remote/>
</endpoint>
</endpoints>
</connection-point>
</connection-points>
<evpn>
<evpn-instances>
<evpn-instance>
<evi>1001</evi>
<config>
<evi>1001</evi>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</config>
</evpn-instance>
</evpn-instances>
</evpn>
</network-instance>
</network-instances>
Validation with NetConf get
Here is a NetConf validation response that provides detailed information about configuring EVPN-VPLS type.
<network-instances xmlns="http://openconfig.net/yang/network-instance">
<network-instance>
<name>default</name>
<config>
<name>default</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:DEFAULT_INSTANCE</type>
</config>
<state>
<name>default</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:DEFAULT_INSTANCE</type>
</state>
<protocols>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<enabled>true</enabled>
</config>
<state>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<enabled>true</enabled>
</state>
</protocol>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</identifier>
<name>100</name>
<ospfv2>
<global>
<config>
<router-id>10.143.73.1</router-id>
<log-adjacency-changes>false</log-adjacency-changes>
</config>
<state>
<log-adjacency-changes>false</log-adjacency-changes>
<router-id>10.143.73.1</router-id>
</state>
</global>
<areas>
<area>
<identifier>0.0.0.0</identifier>
<config>
<identifier>0.0.0.0</identifier>
</config>
<state>
<identifier>0.0.0.0</identifier>
</state>
<interfaces>
<interface>
<id>eth4</id>
<config>
<id>eth4</id>
</config>
<interface-ref>
<config>
<interface>eth4</interface>
</config>
</interface-ref>
<state>
<id>eth4</id>
</state>
</interface>
<interface>
<id>lo</id>
<config>
<id>lo</id>
</config>
<interface-ref>
<config>
<interface>lo</interface>
</config>
</interface-ref>
<state>
<id>lo</id>
</state>
</interface>
</interfaces>
</area>
</areas>
</ospfv2>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</identifier>
<name>100</name>
<enabled>true</enabled>
</config>
</protocol>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
<bgp>
<global>
<config>
<as>65010</as>
</config>
<state>
<as>65010</as>
<total-prefixes>0</total-prefixes>
</state>
<afi-safis>
<afi-safi>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<config>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</config>
<add-paths>
<state>
<receive>false</receive>
<send>false</send>
</state>
</add-paths>
<state>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</state>
</afi-safi>
</afi-safis>
</global>
<neighbors>
<neighbor>
<neighbor-address>10.143.73.3</neighbor-address>
<afi-safis>
<afi-safi>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<config>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</config>
<state>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</state>
</afi-safi>
</afi-safis>
<config>
<enabled>true</enabled>
<neighbor-address>10.143.73.3</neighbor-address>
<peer-as>65010</peer-as>
</config>
<transport>
<config>
<local-address>lo</local-address>
</config>
<state>
<local-address>lo</local-address>
</state>
</transport>
<state>
<enabled>true</enabled>
<neighbor-address>10.143.73.3</neighbor-address>
<peer-as>65010</peer-as>
</state>
</neighbor>
</neighbors>
</bgp>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
<enabled>true</enabled>
</config>
<state>
<enabled>true</enabled>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
</state>
</protocol>
</protocols>
<tables>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
<state>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</state>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
<state>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</state>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
</config>
<state>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
</state>
</table>
</tables>
<interfaces>
<interface>
<id>eth0</id>
<config>
<id>eth0</id>
<interface>eth0</interface>
</config>
<state>
<id>eth0</id>
<interface>eth0</interface>
</state>
</interface>
<interface>
<id>eth1</id>
<config>
<id>eth1</id>
<interface>eth1</interface>
</config>
<state>
<id>eth1</id>
<interface>eth1</interface>
</state>
</interface>
<interface>
<id>eth2</id>
<config>
<id>eth2</id>
<interface>eth2</interface>
</config>
<state>
<id>eth2</id>
<interface>eth2</interface>
</state>
</interface>
<interface>
<id>eth2.1001</id>
<config>
<id>eth2.1001</id>
<interface>eth2</interface>
<subinterface>1001</subinterface>
</config>
<state>
<id>eth2.1001</id>
<interface>eth2</interface>
<subinterface>1001</subinterface>
</state>
</interface>
<interface>
<id>eth3</id>
<config>
<id>eth3</id>
<interface>eth3</interface>
</config>
<state>
<id>eth3</id>
<interface>eth3</interface>
</state>
</interface>
<interface>
<id>eth4</id>
<config>
<id>eth4</id>
<interface>eth4</interface>
</config>
<state>
<id>eth4</id>
<interface>eth4</interface>
</state>
</interface>
<interface>
<id>eth5</id>
<config>
<id>eth5</id>
<interface>eth5</interface>
</config>
<state>
<id>eth5</id>
<interface>eth5</interface>
</state>
</interface>
<interface>
<id>eth6</id>
<config>
<id>eth6</id>
<interface>eth6</interface>
</config>
<state>
<id>eth6</id>
<interface>eth6</interface>
</state>
</interface>
<interface>
<id>eth7</id>
<config>
<id>eth7</id>
<interface>eth7</interface>
</config>
<state>
<id>eth7</id>
<interface>eth7</interface>
</state>
</interface>
<interface>
<id>eth8</id>
<config>
<id>eth8</id>
<interface>eth8</interface>
</config>
<state>
<id>eth8</id>
<interface>eth8</interface>
</state>
</interface>
<interface>
<id>lo</id>
<config>
<id>lo</id>
<interface>lo</interface>
</config>
<state>
<id>lo</id>
<interface>lo</interface>
</state>
</interface>
</interfaces>
<mpls>
<signaling-protocols>
<ldp>
<interface-attributes>
<interfaces>
<interface>
<interface-id>eth4</interface-id>
<config>
<interface-id>eth4</interface-id>
</config>
<address-families>
<address-family>
<afi-name>IPV4</afi-name>
<config>
<afi-name>IPV4</afi-name>
<enabled>true</enabled>
</config>
</address-family>
<address-family>
<afi-name>IPV6</afi-name>
<config>
<afi-name>IPV6</afi-name>
<enabled>false</enabled>
</config>
</address-family>
</address-families>
</interface>
</interfaces>
</interface-attributes>
</ldp>
</signaling-protocols>
<global>
<interface-attributes>
<interface>
<interface-id>eth4</interface-id>
<config>
<interface-id>eth4</interface-id>
<mpls-enabled>true</mpls-enabled>
</config>
<interface-ref>
<config>
<interface>eth4</interface>
</config>
</interface-ref>
<state>
<mpls-enabled>true</mpls-enabled>
</state>
</interface>
</interface-attributes>
</global>
</mpls>
</network-instance>
<network-instance>
<name>vpls1001</name>
<config>
<name>vpls1001</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:L2L3</type>
<router-id>10.143.73.1</router-id>
<route-distinguisher>10.143.73.1:1001</route-distinguisher>
</config>
<encapsulation>
<config>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</config>
<state>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</state>
</encapsulation>
<state>
<name>vpls1001</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:L2L3</type>
<router-id>10.143.73.1</router-id>
<route-distinguisher>10.143.73.1:1001</route-distinguisher>
</state>
<inter-instance-policies>
<import-export-policy>
<config>
<export-route-target>1001:1001</export-route-target>
<import-route-target>1001:1001</import-route-target>
</config>
<state>
<export-route-target>1001:1001</export-route-target>
<import-route-target>1001:1001</import-route-target>
</state>
</import-export-policy>
</inter-instance-policies>
<connection-points>
<connection-point>
<connection-point-id>1001</connection-point-id>
<config>
<connection-point-id>1001</connection-point-id>
</config>
<endpoints>
<endpoint>
<endpoint-id>1001</endpoint-id>
<config>
<endpoint-id>1001</endpoint-id>
</config>
<state>
<endpoint-id>1001</endpoint-id>
</state>
<local>
<config>
<interface>eth2</interface>
<subinterface>1001</subinterface>
</config>
<state>
<interface>eth2</interface>
<subinterface>1001</subinterface>
</state>
</local>
<remote/>
</endpoint>
</endpoints>
<state>
<connection-point-id>1001</connection-point-id>
</state>
</connection-point>
</connection-points>
<evpn>
<evpn-instances>
<evpn-instance>
<evi>1001</evi>
<config>
<evi>1001</evi>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</config>
<state>
<evi>1001</evi>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</state>
</evpn-instance>
</evpn-instances>
</evpn>
</network-instance>
</network-instances>
Restrictions
The paths mentioned below do not have a translation from OpenConfig model to OcNOS model. If you try to apply a configuration using only these paths, it will not be applied on OcNOS side.
/network-instances/network-instance/connection-points
/network-instances/network-instance/connection-points/connection-point/endpoints
Those containers are used only to handle “virtual-circuit-identifier” attribute and “local” container, and the configuration is translated only when those attributes are configured.
/network-instances/network-instance/connection-points
The deletion of this attribute only deletes the configurations of "virtual-circuit-identifier" and "local" container. To delete all configuration from "evpn-mpls" container, the delete operation must be placed on the path:
/network-instances/network-instance/evpn/evpn-instances/evpn-instance[evi].
Configure EVPN-VPWS type
This XML configuration snippet is used to configure EVPN-VPWS type.
Release
This configuration was introduced in OcNOS version 6.1.0.
Initial Configuration:
Here is the initial configuration necessary to be implemented before configuring EVPN-VPWS type.
router ldp
!
interface lo
ip address 10.143.73.1/32 secondary
!
interface eth4
ip address 10.255.128.8/31
label-switching
enable-ldp ipv4
!
interface eth2.2 switchport
encapsulation dot1q 2
!
ospf area-interface-config-mode
router ospf 100
ospf router-id 10.143.73.1
area 0.0.0.0 interface eth4
area 0.0.0.0 interface lo
 
OcNOS CLI Command
The below CLI command is used to configure EVPN-VPWS type.
evpn mpls enable
!
mac vrf vrf2
router-id 10.143.73.1
rd 10.143.73.1:2
route-target both 2:2
!
evpn mpls vtep-ip-global 10.143.73.1
!
evpn mpls id 2 xconnect target-mpls-id 252
host-reachability-protocol evpn-bgp vrf2
!
interface eth2.2 switchport
encapsulation dot1q 2
access-if-evpn
map vpn-id 2
!
router bgp 65010
neighbor 10.143.73.3 remote-as 65010
neighbor 10.143.73.3 update-source lo
!
address-family l2vpn evpn
neighbor 10.143.73.3 activate
exit-address-family
OcNOS NetConf Payload
Here is a sample OcNOS NetConf Payload to configure EVPN-VPWS type.
<network-instances xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-network-instance">
<network-instance>
<instance-name>default</instance-name>
<instance-type>vrf</instance-type>
<vrf xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-vrf">
<config>
<vrf-name>default</vrf-name>
</config>
</vrf>
<config>
<instance-name>default</instance-name>
<instance-type>vrf</instance-type>
</config>
</network-instance>
<network-instance>
<instance-name>vrf2</instance-name>
<instance-type>mac-vrf</instance-type>
<config>
<instance-name>vrf2</instance-name>
<instance-type>mac-vrf</instance-type>
</config>
<vrf xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-vrf">
<config>
<vrf-name>vrf2</vrf-name>
</config>
<bgp-vrf xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-bgp-vrf">
<config>
<rd-string>10.143.73.1:2</rd-string>
</config>
<route-target>
<rt-rd-string>2:2</rt-rd-string>
<config>
<rt-rd-string>2:2</rt-rd-string>
<direction>import export</direction>
</config>
</route-target>
</bgp-vrf>
</vrf>
</network-instance>
</network-instances>
<bgp xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-bgp">
<bgp-instance>
<bgp-as>65010</bgp-as>
<config>
<bgp-as>65010</bgp-as>
</config>
<peer>
<peer-address>10.143.73.3</peer-address>
<config>
<peer-address>10.143.73.3</peer-address>
<peer-as>65010</peer-as>
<source-identifier>lo</source-identifier>
</config>
<address-family>
<afi>l2vpn</afi>
<safi>evpn</safi>
<config>
<afi>l2vpn</afi>
<safi>evpn</safi>
<activate />
</config>
</address-family>
</peer>
<address-family>
<afi>l2vpn</afi>
<safi>evpn</safi>
<config>
<afi>l2vpn</afi>
<safi>evpn</safi>
</config>
</address-family>
</bgp-instance>
</bgp>
<evpn-mpls xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-evpn-mpls">
<mpls-tenant>
<tenant-identifier>2</tenant-identifier>
<config>
<vrf-name>vrf2</vrf-name>
<tenant-identifier>2</tenant-identifier>
<vpws-identifier>252</vpws-identifier>
</config>
</mpls-tenant>
<global>
<config>
<enable-evpn-mpls />
<vtep-ipv4>10.143.73.1</vtep-ipv4>
</config>
</global>
</evpn-mpls>
<evpn xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-ethernet-vpn">
<interfaces>
<interface>
<name>eth2.2</name>
<config>
<name>eth2.2</name>
</config>
<access-interfaces>
<access-interface>
<access-if>access-if-evpn</access-if>
<config>
<access-if>access-if-evpn</access-if>
<evpn-identifier>2</evpn-identifier>
</config>
</access-interface>
</access-interfaces>
</interface>
</interfaces>
</evpn>
<interfaces xmlns="http://www.ipinfusion.com/yang/ocnos/ipi-interface">
<interface>
<name>eth2.2</name>
<config>
<enable-switchport />
</config>
</interface>
</interfaces>NetConf
 
OpenConfig NetConf Payload
Here is a sample OpenConfig NetConf Payload to configure EVPN-VPWS type.
<network-instances xmlns="http://openconfig.net/yang/network-instance">
<network-instance>
<name>default</name>
<config>
<name>default</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:DEFAULT_INSTANCE</type>
</config>
<protocols>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<enabled>true</enabled>
</config>
</protocol>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</identifier>
<name>100</name>
<ospfv2>
<global>
<config>
<router-id>10.143.73.1</router-id>
<log-adjacency-changes>false</log-adjacency-changes>
</config>
</global>
<areas>
<area>
<identifier>0.0.0.0</identifier>
<config>
<identifier>0.0.0.0</identifier>
</config>
<interfaces>
<interface>
<id>eth4</id>
<config>
<id>eth4</id>
</config>
<interface-ref>
<config>
<interface>eth4</interface>
</config>
</interface-ref>
</interface>
<interface>
<id>lo</id>
<config>
<id>lo</id>
</config>
<interface-ref>
<config>
<interface>lo</interface>
</config>
</interface-ref>
</interface>
</interfaces>
</area>
</areas>
</ospfv2>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</identifier>
<name>100</name>
<enabled>true</enabled>
</config>
</protocol>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
<bgp>
<global>
<config>
<as>65010</as>
</config>
<afi-safis>
<afi-safi>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<config>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</config>
</afi-safi>
</afi-safis>
</global>
<neighbors>
<neighbor>
<neighbor-address>10.143.73.3</neighbor-address>
<afi-safis>
<afi-safi>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<config>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</config>
</afi-safi>
</afi-safis>
<config>
<enabled>true</enabled>
<neighbor-address>10.143.73.3</neighbor-address>
<peer-as>65010</peer-as>
</config>
<transport>
<config>
<local-address>lo</local-address>
</config>
</transport>
</neighbor>
</neighbors>
</bgp>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
<enabled>true</enabled>
</config>
</protocol>
</protocols>
<tables>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
</config>
</table>
</tables>
</network-instance>
<network-instance>
<name>vrf2</name>
<config>
<name>vrf2</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:L2L3</type>
<router-id>10.143.73.1</router-id>
<route-distinguisher>10.143.73.1:2</route-distinguisher>
</config>
<encapsulation>
<config>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</config>
</encapsulation>
<inter-instance-policies>
<import-export-policy>
<config>
<export-route-target>2:2</export-route-target>
<import-route-target>2:2</import-route-target>
</config>
</import-export-policy>
</inter-instance-policies>
<connection-points>
<connection-point>
<connection-point-id>2</connection-point-id>
<config>
<connection-point-id>2</connection-point-id>
</config>
<endpoints>
<endpoint>
<endpoint-id>2</endpoint-id>
<config>
<endpoint-id>2</endpoint-id>
</config>
<local>
<config>
<interface>eth2</interface>
<subinterface>2</subinterface>
</config>
</local>
<remote>
<config>
<virtual-circuit-identifier>252</virtual-circuit-identifier>
</config>
</remote>
</endpoint>
</endpoints>
</connection-point>
</connection-points>
<evpn>
<evpn-instances>
<evpn-instance>
<evi>2</evi>
<config>
<evi>2</evi>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</config>
</evpn-instance>
</evpn-instances>
</evpn>
</network-instance>
</network-instances>
Validation with NetConf get
Here is a NetConf validation response that provides detailed information about configuring EVPN-VPWS type.
<network-instances xmlns="http://openconfig.net/yang/network-instance">
<network-instance>
<name>default</name>
<config>
<name>default</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:DEFAULT_INSTANCE</type>
</config>
<state>
<name>default</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:DEFAULT_INSTANCE</type>
</state>
<protocols>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<enabled>true</enabled>
</config>
<state>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</identifier>
<name>DIRECTLY_CONNECTED</name>
<enabled>true</enabled>
</state>
</protocol>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</identifier>
<name>100</name>
<ospfv2>
<global>
<config>
<router-id>10.143.73.1</router-id>
<log-adjacency-changes>false</log-adjacency-changes>
</config>
<state>
<log-adjacency-changes>false</log-adjacency-changes>
<router-id>10.143.73.1</router-id>
</state>
</global>
<areas>
<area>
<identifier>0.0.0.0</identifier>
<config>
<identifier>0.0.0.0</identifier>
</config>
<state>
<identifier>0.0.0.0</identifier>
</state>
<interfaces>
<interface>
<id>eth4</id>
<config>
<id>eth4</id>
</config>
<interface-ref>
<config>
<interface>eth4</interface>
</config>
</interface-ref>
<state>
<id>eth4</id>
</state>
</interface>
<interface>
<id>lo</id>
<config>
<id>lo</id>
</config>
<interface-ref>
<config>
<interface>lo</interface>
</config>
</interface-ref>
<state>
<id>lo</id>
</state>
</interface>
</interfaces>
</area>
</areas>
</ospfv2>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</identifier>
<name>100</name>
<enabled>true</enabled>
</config>
</protocol>
<protocol>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
<bgp>
<global>
<config>
<as>65010</as>
</config>
<state>
<as>65010</as>
<total-prefixes>0</total-prefixes>
</state>
<afi-safis>
<afi-safi>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<config>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</config>
<add-paths>
<state>
<receive>false</receive>
<send>false</send>
</state>
</add-paths>
<state>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</state>
</afi-safi>
</afi-safis>
</global>
<neighbors>
<neighbor>
<neighbor-address>10.143.73.3</neighbor-address>
<afi-safis>
<afi-safi>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<config>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</config>
<state>
<afi-safi-name
xmlns:oc-bgp-types="http://openconfig.net/yang/bgp-types">oc-bgp-types:L2VPN_EVPN</afi-safi-name>
<enabled>true</enabled>
</state>
</afi-safi>
</afi-safis>
<config>
<enabled>true</enabled>
<neighbor-address>10.143.73.3</neighbor-address>
<peer-as>65010</peer-as>
</config>
<transport>
<config>
<local-address>lo</local-address>
</config>
<state>
<local-address>lo</local-address>
</state>
</transport>
<state>
<enabled>true</enabled>
<neighbor-address>10.143.73.3</neighbor-address>
<peer-as>65010</peer-as>
</state>
</neighbor>
</neighbors>
</bgp>
<config>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
<enabled>true</enabled>
</config>
<state>
<enabled>true</enabled>
<identifier
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</identifier>
<name>65010</name>
</state>
</protocol>
</protocols>
<tables>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
<state>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</state>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
<state>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:DIRECTLY_CONNECTED</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</state>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:STATIC</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:OSPF</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV4</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:IPV6</address-family>
</config>
</table>
<table>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
<config>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
</config>
<state>
<protocol
xmlns:oc-pol-types="http://openconfig.net/yang/policy-types">oc-pol-types:BGP</protocol>
<address-family
xmlns:oc-types="http://openconfig.net/yang/openconfig-types">oc-types:MPLS</address-family>
</state>
</table>
</tables>
<interfaces>
<interface>
<id>eth0</id>
<config>
<id>eth0</id>
<interface>eth0</interface>
</config>
</interface>
<interface>
<id>eth1</id>
<config>
<id>eth1</id>
<interface>eth1</interface>
</config>
</interface>
<interface>
<id>eth2</id>
<config>
<id>eth2</id>
<interface>eth2</interface>
</config>
</interface>
<interface>
<id>eth2.2</id>
<config>
<id>eth2.2</id>
<interface>eth2</interface>
<subinterface>2</subinterface>
</config>
</interface>
<interface>
<id>eth3</id>
<config>
<id>eth3</id>
<interface>eth3</interface>
</config>
</interface>
<interface>
<id>eth4</id>
<config>
<id>eth4</id>
<interface>eth4</interface>
</config>
</interface>
<interface>
<id>eth5</id>
<config>
<id>eth5</id>
<interface>eth5</interface>
</config>
</interface>
<interface>
<id>eth6</id>
<config>
<id>eth6</id>
<interface>eth6</interface>
</config>
</interface>
<interface>
<id>eth7</id>
<config>
<id>eth7</id>
<interface>eth7</interface>
</config>
</interface>
<interface>
<id>eth8</id>
<config>
<id>eth8</id>
<interface>eth8</interface>
</config>
</interface>
<interface>
<id>lo</id>
<config>
<id>lo</id>
<interface>lo</interface>
</config>
</interface>
</interfaces>
<mpls>
<signaling-protocols>
<ldp>
<interface-attributes>
<interfaces>
<interface>
<interface-id>eth4</interface-id>
<config>
<interface-id>eth4</interface-id>
</config>
<address-families>
<address-family>
<afi-name>IPV4</afi-name>
<config>
<afi-name>IPV4</afi-name>
<enabled>true</enabled>
</config>
</address-family>
<address-family>
<afi-name>IPV6</afi-name>
<config>
<afi-name>IPV6</afi-name>
<enabled>false</enabled>
</config>
</address-family>
</address-families>
</interface>
</interfaces>
</interface-attributes>
</ldp>
</signaling-protocols>
<global>
<interface-attributes>
<interface>
<interface-id>eth4</interface-id>
<config>
<interface-id>eth4</interface-id>
<mpls-enabled>true</mpls-enabled>
</config>
<interface-ref>
<config>
<interface>eth4</interface>
</config>
</interface-ref>
<state>
<mpls-enabled>true</mpls-enabled>
</state>
</interface>
</interface-attributes>
</global>
</mpls>
</network-instance>
<network-instance>
<name>vrf2</name>
<config>
<name>vrf2</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:L2L3</type>
<router-id>10.143.73.1</router-id>
<route-distinguisher>10.143.73.1:2</route-distinguisher>
</config>
<encapsulation>
<config>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</config>
<state>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</state>
</encapsulation>
<state>
<name>vrf2</name>
<type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:L2L3</type>
<router-id>10.143.73.1</router-id>
<route-distinguisher>10.143.73.1:2</route-distinguisher>
</state>
<inter-instance-policies>
<import-export-policy>
<config>
<export-route-target>2:2</export-route-target>
<import-route-target>2:2</import-route-target>
</config>
<state>
<export-route-target>2:2</export-route-target>
<import-route-target>2:2</import-route-target>
</state>
</import-export-policy>
</inter-instance-policies>
<connection-points>
<connection-point>
<connection-point-id>2</connection-point-id>
<config>
<connection-point-id>2</connection-point-id>
</config>
<endpoints>
<endpoint>
<endpoint-id>2</endpoint-id>
<config>
<endpoint-id>2</endpoint-id>
</config>
<state>
<endpoint-id>2</endpoint-id>
</state>
<local>
<config>
<interface>eth2</interface>
<subinterface>2</subinterface>
</config>
<state>
<interface>eth2</interface>
<subinterface>2</subinterface>
</state>
</local>
<remote>
<config>
<virtual-circuit-identifier>252</virtual-circuit-identifier>
</config>
<state>
<virtual-circuit-identifier>252</virtual-circuit-identifier>
</state>
</remote>
</endpoint>
</endpoints>
<state>
<connection-point-id>2</connection-point-id>
</state>
</connection-point>
</connection-points>
<evpn>
<evpn-instances>
<evpn-instance>
<evi>2</evi>
<config>
<evi>2</evi>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</config>
<state>
<evi>2</evi>
<encapsulation-type
xmlns:oc-ni-types="http://openconfig.net/yang/network-instance-types">oc-ni-types:MPLS</encapsulation-type>
</state>
</evpn-instance>
</evpn-instances>
</evpn>
</network-instance>
</network-instances>
Restrictions
Since there is no equivalent in OpenConfig, and there is no obligation to have the configuration set in any case for the leaf /evpn-mpls/global/config/vtep-ipv4 this leaf (vtep-ipv4) is no longer supported in the translation. If you want to set the configuration, you must use the OcNOS namespace.
The paths mentioned below do not have a translation from OpenConfig model to OcNOS model. If you try to apply a configuration using only these paths, it will not be applied on OcNOS side.
/network-instances/network-instance/connection-points
/network-instances/network-instance/connection-points/connection-point/endpoints
Those containers are used only to handle virtual-circuit-identifier attribute and local container, and the configuration is translated only when those attributes are configured.
/network-instances/network-instance/connection-point
The deletion of this attribute only deletes the configurations of virtual-circuit-identifier and local container. To delete all configuration from evpn-mpls container, the delete operation must be placed on the path:
/network-instances/network-instance/evpn/evpn-instances/evpn-instance