[ad_1]
Previous month I described how you can simplify your VLAN- or VRF lab topologies with VRF- and VLAN back links, quickly setting vlan.accessibility or vrf attribute on a established of links. Hyperlink groups let you to do the exact same for any established of website link characteristics.
Sample Topology
Visualize you have a modest community with three PE-routers linked to a central P-router:

As prolonged as you are Okay with the default parameters (default OSPF price, default IPv4 handle pool), you could describe that lab with a pretty easy topology file:
defaults.unit: eos
module: [ ospf ]
nodes: [ pe1, pe2, pe3, p ]
inbound links: [ pe1-p, pe2-p, pe3-p ]
Now let’s suppose that you’d like to use unnumbered core hyperlinks, established OSPF price tag on individuals hyperlinks, and established hyperlink part to main. You can no longer use the basic checklist of one-way links but have to define url attributes on each individual solitary connection. Not only is the topology file more durable to examine, it also has copy characteristics.
defaults.unit: eos
module: [ ospf ]
nodes: [ pe1, pe2, pe3, p ]
back links:
- pe1:
p:
unnumbered: true
ospf.expense: 100
role: core
- pe2:
p:
unnumbered: real
ospf.charge: 100
function: main
- pe3:
p:
unnumbered: correct
ospf.price tag: 100
position: core
Website link Groups to the Rescue
netlab launch 1.5.1 introduced link teams – a basic way to set the exact same set of attributes on numerous inbound links.
Hyperlink groups are outlined within the hyperlinks checklist all you have to do is to established the team attribute to explain to netlab it is working with a group of backlinks, and outline member backlinks in the users attribute.
Utilizing a core team, we can get our lab topology again into an simple-to-browse pretty much-non-redundant structure:
defaults.system: eos
module: [ ospf ]
nodes: [ pe1, pe2, pe3, p ]
hyperlinks:
- group: main
unnumbered: accurate
ospf.expense: 100
job: main
members: [ pe1-p, pe2-p, pe3-p ]
Guiding the Scenes
Just before beginning the topology information transformation approach, netlab expands link groups into unique backlinks:
- A new website link knowledge framework is established for each member link, expanding many simplified website link definition formats into dictionaries.
- Team characteristics are extra to the website link attribute. Url characteristics (if specified) get precedence about group characteristics.
Working with this procedure, netlab created the pursuing set of inbound links from the over topology file:
Main hyperlinks developed from the core url group
$ netlab produce -o yaml:one-way links
- interfaces:
- ifindex: 1
ifname: Ethernet1
ipv4: correct
node: pe1
- ifindex: 1
ifname: Ethernet1
ipv4: legitimate
node: p
linkindex: 1
node_rely: 2
ospf:
expense: 100
part: core
style: p2p
unnumbered: genuine
- interfaces:
- ifindex: 1
ifname: Ethernet1
ipv4: true
node: pe2
- ifindex: 2
ifname: Ethernet2
ipv4: correct
node: p
linkindex: 2
node_count: 2
ospf:
charge: 100
role: core
type: p2p
unnumbered: correct
- interfaces:
- ifindex: 1
ifname: Ethernet1
ipv4: legitimate
node: pe3
- ifindex: 3
ifname: Ethernet3
ipv4: real
node: p
linkindex: 3
node_rely: 2
ospf:
cost: 100
part: main
kind: p2p
unnumbered: accurate
Get Begun
Website link groups were being introduced in netlab release 1.5.1. To update, execute pip3 set up --up grade networklab
.
New to netlab? Commence with the Receiving Commenced document and the set up guidebook.
[ad_2]
Source url