Skip to content

Commit b1186da

Browse files
committed
Add ditella-8r-1c-srv6-pm project
1 parent 7eb3b58 commit b1186da

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+3125
-0
lines changed

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[submodule "nets-in-progress/ditella-8r-1c-srv6-pm/twampy"]
2+
path = nets-in-progress/ditella-8r-1c-srv6-pm/twampy
3+
url = https://github.com/nokia/twampy
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
export WORKSPACE=/home/rose/workspace
2+
export ROSE_SRV6_TUTORIAL=${WORKSPACE}/rose-srv6-tutorial
3+
4+
# Configure SRV6_PFPML_PATH
5+
export SRV6_PFPML_PATH=/opt/srv6-pm-xdp-ebpf/srv6-pfplm
6+
7+
# Node manager params
8+
export NODE_MANAGER_PATH=${CONTROL_PLANE}/srv6_controller/node-manager/
9+
export NODE_MANAGER_GRPC_PORT=12345
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
fcff:7::1
Lines changed: 356 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,356 @@
1+
# 8r-1c-srv6-pm Topology
2+
3+
A Mininet topology with 8 routers running IS-IS routing protocol, 12 hosts, 3 datacenters and a controller connected out-band to all the routers and hosts of the network.
4+
5+
This topology is the same as 8r-1c-out-band, but same nodes are configured to run Performance Measurement experiments.
6+
7+
## Topology overview
8+
9+
![Alt Topology](docs/images/topology.png)
10+
11+
## Start the topology
12+
13+
To start the topology:
14+
```
15+
python isis8d.py
16+
```
17+
18+
## Description
19+
20+
```text
21+
22+
In folder nodeconf/
23+
- for each host, datacenter, router and controller one folder
24+
- host folders contain start.sh for each host
25+
- sets IPv6 address for hosts
26+
- adds IPv6 routing to gateway
27+
- datacenter folders contain start.sh for each datacenter
28+
- sets IPv6 address for datecenters
29+
- adds IPv6 routing to gateway
30+
- router folders contain
31+
- zebra.conf
32+
- sets for each interface the IPv6 address
33+
- isisd.conf
34+
- contains routing information
35+
- start.sh
36+
- enables IPv6 forwarding
37+
- executes zebra.conf and isisd.conf
38+
- the controller folder contains start.sh
39+
- sets IPv6 address for the controller
40+
- some routers are configured to run Performance Measurement experiments
41+
42+
43+
44+
45+
network:
46+
the network is shown in this link
47+
https://docs.google.com/presentation/d/15w14n_Nf5rE560FluMnw4Wq51pYLvDqG1kEwDvmEHE0/edit#slide=id.g7752c9e8cd_5_88
48+
49+
50+
51+
host - router links:
52+
53+
h11 - r1: fd00:0:11::2/64 r1 - h11: fd00:0:11::1/64
54+
h12 - r1: fd00:0:12::2/64 r1 - h12: fd00:0:12::1/64
55+
h13 - r1: fd00:0:13::2/64 r1 - h13: fd00:0:13::1/64
56+
57+
h31 - r3: fd00:0:31::2/64 r3 - h31: fd00:0:31::1/64
58+
h32 - r3: fd00:0:32::2/64 r3 - h32: fd00:0:32::1/64
59+
h33 - r3: fd00:0:33::2/64 r3 - h33: fd00:0:33::1/64
60+
61+
h51 - r5: fd00:0:51::2/64 r5 - h51: fd00:0:51::1/64
62+
h52 - r5: fd00:0:52::2/64 r5 - h52: fd00:0:52::1/64
63+
h53 - r5: fd00:0:53::2/64 r5 - h53: fd00:0:53::1/64
64+
65+
h81 - r8: fd00:0:81::2/64 r8 - h81: fd00:0:81::1/64
66+
h82 - r8: fd00:0:82::2/64 r8 - h82: fd00:0:82::1/64
67+
h83 - r8: fd00:0:83::2/64 r8 - h83: fd00:0:83::1/64
68+
69+
datacenter - router links:
70+
71+
hdc1 - r2: fcff:2:1::2/48 r2 - hdc1: fcff:2:1::1/48
72+
hdc2 - r8: fcff:8:1::2/48 r8 - hdc2: fcff:8:1::1/48
73+
hdc3 - r5: fcff:5:1::2/48 r5 - hdc3: fcff:5:1::1/48
74+
75+
router - router links:
76+
77+
r1 -r2: fcf0:0:1:2::1/64 r2 - r1: fcf0:0:1:2::2/64
78+
r2 -r3: fcf0:0:2:3::1/64 r3 - r2: fcf0:0:2:3::2/64
79+
r2 -r7: fcf0:0:2:7::1/64 r7 - r2: fcf0:0:2:7::2/64
80+
r3 -r4: fcf0:0:3:4::1/64 r4 - r3: fcf0:0:3:4::2/64
81+
r4 -r5: fcf0:0:4:5::1/64 r5 - r4: fcf0:0:4:5::2/64
82+
r4 -r6: fcf0:0:4:6::1/64 r6 - r4: fcf0:0:4:6::2/64
83+
r5 -r6: fcf0:0:5:6::1/64 r6 - r5: fcf0:0:5:6::2/64
84+
r6 -r7: fcf0:0:6:7::1/64 r7 - r6: fcf0:0:6:7::2/64
85+
r6 -r8: fcf0:0:6:8::1/64 r8 - r6: fcf0:0:6:8::2/64
86+
r7 -r8: fcf0:0:7:8::1/64 r8 - r7: fcf0:0:7:8::2/64
87+
88+
controller - switch links:
89+
90+
controller - sw: fcfd:0:0:fd::1/48 sw - controller: fcfd:0:0:fd::2/48
91+
92+
router - switch links:
93+
94+
r1 - sw: fcfd:0:0:1::1/48 sw - r1: fcfd:0:0:1::2/48
95+
r2 - sw: fcfd:0:0:2::1/48 sw - r1: fcfd:0:0:2::2/48
96+
r3 - sw: fcfd:0:0:3::1/48 sw - r1: fcfd:0:0:3::2/48
97+
r4 - sw: fcfd:0:0:4::1/48 sw - r1: fcfd:0:0:4::2/48
98+
r5 - sw: fcfd:0:0:5::1/48 sw - r1: fcfd:0:0:5::2/48
99+
r6 - sw: fcfd:0:0:6::1/48 sw - r1: fcfd:0:0:6::2/48
100+
r7 - sw: fcfd:0:0:7::1/48 sw - r1: fcfd:0:0:7::2/48
101+
r8 - sw: fcfd:0:0:8::1/48 sw - r1: fcfd:0:0:8::2/48
102+
103+
router localhost
104+
105+
r1 fcff:1::1
106+
r2 fcff:2::1
107+
r3 fcff:3::1
108+
r4 fcff:4::1
109+
r5 fcff:5::1
110+
r6 fcff:6::1
111+
r7 fcff:7::1
112+
r8 fcff:8::1
113+
114+
( The addressing plan is explained in https://docs.google.com/document/d/15giV53fH_eDuWadOxzjPVzlr-a7Rn65MpCbz9QKs7JI/edit )
115+
116+
Note that datacenters are special hosts, which have a public address.
117+
118+
119+
The file etc-hosts in the topology folder maps each IP address to its hostname.
120+
121+
For example,
122+
fcff:1::1 r1
123+
fd00:0:11::2 h11
124+
fcff:2:1::2 hdc1
125+
fcfd:0:0:fd::1 controller.m # .m suffix is used for the management addresses
126+
...
127+
128+
When you start the topology, the entries defined in this file are loaded and added to the system /etc/hosts file.
129+
130+
This allows you to ping the nodes using their hostnames instead of the IP addresses:
131+
h11# ping6 h83
132+
h83# ping6 h11
133+
134+
The entries are automatically removed from the /etc/hosts file when the emulation is stopped.
135+
136+
137+
------Tunnel examples -------------
138+
1) Create a bidirectional tunnel between h11 and h83, passing through router r4
139+
140+
1.1) set tunnel from r1 to r8 for fd00:0:83::/64
141+
142+
on r1: ip -6 route add fd00:0:83::/64 encap seg6 mode encap segs fcff:4::1,fcff:8::1 dev r1-h11
143+
144+
on r8: no explicit decap instruction is needed because net.ipv6.conf.*.seg6_enabled=1
145+
146+
1.2) set tunnel from r8 to r1 for fd00:0:11::/64
147+
148+
on r8: ip -6 route add fd00:0:11::/64 encap seg6 mode encap segs fcff:4::1,fcff:1::1 dev r8-h83
149+
150+
on r1: no explicit decap instruction is needed because net.ipv6.conf.*.seg6_enabled=1
151+
152+
after the tunnel is setup, you can ping from h11 to h83 and viceversa
153+
h11# ping6 fd00:0:83::2
154+
h83# ping6 fd00:0:11::2
155+
156+
on recent versions of Linux kernel (>=5.5) it is also possible to ping the router IP address on
157+
the interface with the host, while on previous ones it was not possible due to a bug in the SRv6
158+
implementation:
159+
h11# ping6 fd00:0:83::1
160+
161+
Note that this is not the suggested approach, the explicit configuration of decap instruction
162+
is preferred, as described hereafter
163+
164+
we use a decap SID in r8 and in r1 with the End.DT6 behavior, the SID used is fcff:8::100
165+
166+
1.3) set tunnel from r1 to r8 for fd00:0:83::/64
167+
168+
on r1: ip -6 route add fd00:0:83::/64 encap seg6 mode encap segs fcff:4::1,fcff:8::100 dev r1-h11
169+
170+
on r8: ip -6 route add fcff:8::100 encap seg6local action End.DT6 table 254 dev r8-h83
171+
172+
1.4) set tunnel from r8 to r1 for fd00:0:11::/64
173+
174+
on r8: ip -6 route add fd00:0:11::/64 encap seg6 mode encap segs fcff:4::1,fcff:1::100 dev r8-h83
175+
176+
on r1: ip -6 route add fcff:1::100 encap seg6local action End.DT6 table 254 dev r1-h11
177+
178+
table 254 corresponds to the "main" routing table, using recent version of ip command
179+
we can use table name instead of table id, for example
180+
on r8: ip -6 route add fcff:8::100 encap seg6local action End.DT6 table main dev r8-h83
181+
182+
183+
184+
------ISIS CONFIGURATION-------------
185+
186+
Install guide and How to get FRR
187+
188+
The official FRR website is located at https://frrouting.org/ and contains further information, as well as links to additional resources.
189+
190+
Several distributions provide packages for FRR. Check your distribution’s repositories to find out if a suitable version is available.
191+
192+
Daemons Configuration File
193+
194+
After a fresh install, starting FRR will do nothing. This is because daemons must be explicitly enabled by editing a file in your configuration directory. This file is usually located at /etc/frr/ daemons and determines which daemons are activated when issuing a service start / stop command via init or systemd. The file initially looks like this:
195+
196+
zebra=no
197+
bgpd=no
198+
ospfd=no
199+
ospf6d=no
200+
ripd=no
201+
ripngd=no
202+
isisd=yes
203+
pimd=no
204+
ldpd=no
205+
nhrpd=no
206+
eigrpd=no
207+
babeld=no
208+
sharpd=no
209+
staticd=no
210+
pbrd=no
211+
bfdd=no
212+
fabricd=no
213+
214+
....
215+
216+
We have to enable the deamon, so modify the word "isis=no" with "isisd=yes"
217+
218+
219+
----ISIS Configuration----
220+
221+
Common options can be specified (Common Invocation Options) to isisd. isisd needs to acquire interface information from zebra in order to function. Therefore zebra must be running before invoking isisd. Also, if zebra is restarted then isisd must be too.
222+
223+
224+
Each routers contains the files "isisd.conf" "start.sh" "zebra.conf"
225+
226+
227+
The configuration of "zebra.conf" of each routers is for example:
228+
!
229+
hostname r1
230+
log file nodeconf/r1/zebra.log
231+
!
232+
debug zebra events
233+
debug zebra rib
234+
!
235+
interface r1-h11
236+
ipv6 address fd00:0:11::1/64
237+
!
238+
interface r1-h12
239+
ipv6 address fd00:0:12::1/64
240+
!
241+
interface r1-h13
242+
ipv6 address fd00:0:13::1/64
243+
!
244+
interface r1-r2
245+
ipv6 address fcf0:0:1:2::1/64
246+
!
247+
interface lo
248+
ipv6 address fcff:1::1/128
249+
!
250+
ipv6 forwarding
251+
!
252+
line vty
253+
!
254+
255+
256+
In this file we define the interface between the links of router r1 and the hosts that are linked, in particular we also define the interface "lo" of the router
257+
With the command "ipv6 forwarding" we explicitly enable the ipv6 forwarding
258+
259+
260+
261+
The configuration of "isisd.conf" of each routers is for example:
262+
263+
hostname rx
264+
password XXXX
265+
log file nodeconf/r1/isisd.log
266+
!
267+
interface lo
268+
ipv6 router isis XX
269+
ip router isis XX
270+
isis hello-interval 5
271+
!
272+
interface r1-h1
273+
ipv6 router isis XX
274+
ip router isis XX
275+
isis hello-interval 5
276+
!
277+
interface r1-r2
278+
ipv6 router isis XX
279+
ip router isis XX
280+
isis hello-interval 5
281+
!
282+
interface r1-r3
283+
ipv6 router isis XX
284+
ip router isis XX
285+
isis hello-interval 5
286+
!
287+
router isis XX
288+
net 49.000X.XXXX.XXXX.XXXX.00
289+
is-type level-2-only
290+
metric-style wide
291+
!
292+
line vty
293+
294+
we use the command "ipv6 router isis XX" to use ipv6
295+
the command "isis hello-interval (1-600)
296+
" configure the level 1 hello interval
297+
298+
The command
299+
net XX.XXXX. ... .XXX.XX
300+
Set/Unset network entity title (NET) provided in ISO format.
301+
NETs take several forms, depending on your network requirements. NET addresses are hexadecimal and range from 8 octets to 20 octets in length. Generally, the format consists of an authority and format Identifier (AFI), a domain ID, an area ID, a system identifier, and a selector. The simplest format omits the domain ID and is 10 octets long. For example, the NET address 49.0001.1921.6800.1001.00 consists of the following parts:
302+
303+
49—AFI
304+
0001—Area ID
305+
1921.6800.1001—System identifier
306+
00—Selector
307+
308+
The system identifier must be unique within the network.
309+
The first portion of the address is the area number, which is a variable number from 1 through 13 bytes. The first byte of the area number (49) is the authority and format indicator (AFI). The next bytes are the assigned domain (area) identifier, which can be from 0 through 12 bytes. In the examples above, the area identifier is 0001.
310+
The next six bytes form the system identifier. The system identifier can be any six bytes that are unique throughout the entire domain. The system identifier commonly is the media access control (MAC) address.
311+
The last byte (00) is the n-selector.
312+
313+
314+
315+
The command
316+
is-type level-2-only
317+
318+
Level 1 systems route within an area; when the destination is outside an area, they route toward a Level 2 system. Level 2 intermediate systems route between areas and toward other ASs. No IS-IS area functions strictly as a backbone.
319+
Level 1 routers share intra-area routing information, and Level 2 routers share interarea information about IP addresses available within each area. Uniquely, IS-IS routers can act as both Level 1 and Level 2 routers, sharing intra-area routes with other Level 1 routers and interarea routes with other Level 2 routers.
320+
321+
We can choose level 1 or level 2, but its a good idea use level 2 beacause we can route packet out of the networks
322+
323+
----Configuration of Hosts----
324+
325+
each host has a configuration file called start.sh
326+
Currently IPv6 forwarding is not explicitly enabled in start.sh, we have to configure ipv6 addresses for each hosts
327+
328+
Example of configuration of start.sh
329+
330+
NODE_NAME=h11
331+
GW_NAME=r1
332+
IF_NAME=$NODE_NAME-$GW_NAME
333+
IP_ADDR=fd00:0:11::2/64
334+
GW_ADDR=fd00:0:11::1
335+
336+
ip -6 addr add $IP_ADDR dev $IF_NAME
337+
ip -6 route add default via $GW_ADDR dev $IF_NAME
338+
339+
----Configuration of the Controller----
340+
341+
The controller has a configuration file called start.sh in which we set the IP address. Since the controller is connected to the other nodes through a switch, the gateway is not required.
342+
343+
NODE_NAME=controller
344+
SW_NAME=sw
345+
IF_NAME=$NODE_NAME-$SW_NAME
346+
IP_ADDR=fcfd:0:0:fd::1/48
347+
348+
ip -6 addr add $IP_ADDR dev $IF_NAME
349+
350+
----Addressing----
351+
352+
the addressing on the links between the hosts hxy and the router x can be
353+
Router interface rx-hxy fd00:0:xy::1/64
354+
Host interface hxy-ry fd00:0:xy::2/64
355+
356+
```
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#! /bin/bash
2+
3+
rm IPv6-Reflector
142 KB
Loading

0 commit comments

Comments
 (0)