Continuing with this week's theme, check out these sample apps to enable MPLS Traffic Engineering on a router using the OpenConfig MPLS model:
https://github.com/CiscoDevNet/ydk-py-samples/tree/master/samples/basic/ydk/models/openconfig
nc-create-config-mpls-20-ydk.py - Enable RSVP-TE on interfaces
nc-create-config-mpls-30-ydk.py - Set MPLS-TE timers
nc-create-config-mpls-32-ydk.py - Enable MPLS-TE on interfaces
nc-create-config-mpls-34-ydk.py - Set affinities (admin groups)
nc-delete-config-mpls-30-ydk.py - Delete RSVP-TE/MPLS-TE config
These apps will get your node ready to establish TE LSPs. For an LSR role, these two apps should suffice:
nc-create-config-mpls-20-ydk.py - Enable RSVP-TE on interfaces
nc-create-config-mpls-32-ydk.py - Enable MPLS-TE on interfaces
For an LER role, these apps will give a good base to start configuring your TE tunnels:
nc-create-config-mpls-20-ydk.py - Enable RSVP-TE on interfaces
nc-create-config-mpls-30-ydk.py - Set MPLS-TE timers
nc-create-config-mpls-32-ydk.py - Enable MPLS-TE on interfaces
nc-create-config-mpls-34-ydk.py - Set affinities (admin groups)
In a later posting, we'll see examples of actual tunnel configurations.
As always, make sure you review the README file for how to use these apps. You'll find it at:
https://github.com/CiscoDevNet/ydk-py-samples/tree/master/samples/basic
For other OpenConfig examples, see:
Sample apps for OpenConfig BGP posted
More OpenConfig apps for BGP
Sample apps for OpenConfig routing policy
Enjoy!