Changes between Version 3 and Version 4 of Tutorials/Optical/Mininet Optical Tutorial1


Ignore:
Timestamp:
Jul 27, 2022, 12:39:37 AM (22 months ago)
Author:
lantz
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Tutorials/Optical/Mininet Optical Tutorial1

    v3 v4  
    88Please refer to [wiki:Tutorials/Optical/Tutorial1] to compare the hardware and software testbed environments.
    99
    10 Author: Bob Lantz
    11 
    12 Original Authors:
     10Converted by: Bob Lantz
     11
     12Original (hardware) tutorial Authors:
    1313
    1414Artur Minakhmetov, Telecom Paris : artur.minakhmetov[at]telecom-paris.fr\\
     
    102102}}}
    103103
     104
     105----
     106= Prerequisites: Installing Mininet-Optical =
     107
     108Before starting this tutorial, you will need to have Mininet-Optical installed. If it isn't installed already, you can follow the Installation and Walkthrough instructions at https://mininet-optical.org.
     109
     110The tutorial topology and a sample configuration script should be found in ~/mininet-optical/examples/cosmostutorial.py and ~/mininet-optical/examples/config-cosmostutorial.sh. If they are not there, you may need to fetch and check out the appropriate branch from github and install it using make install.
    104111
    105112----
     
    318325(TBD)
    319326
    320 === Configuring ToR1<->ToR2 Connection 1 ===
    321 
    322 * ROADM 4:
    323 1. Enable MUX port 4102 “From ToR 1”
    324 2. Add Connection “Exp1-FromTor1” with Input/ Output Port 4102/4201 with bandwidth [192.95;193.05] (python add_connection.py 10.104.1.4 1 10 in-service false 4102 4201 192950 193050 5 Exp1-FromTor1)
    325 3. Enable DEMUX port 5202 “Towards ToR 1”
    326 4. Add Connection “Exp1-TorwardTor1” with I/O Port 5101/5202 (python add_connection.py 10.104.1.4 2 10 in-service false 5101 5202 192950 193050 5 Exp1-TorwardTor1)
    327 * ROADM 1:
    328 5. Enable MUX port 4102 “From ToR 2”
    329 6. Add Connection “From ToR 2” with I/O Port 4102/4201 with bandwidth [192.95;193.05]
    330 7. Enable DEMUX port 5202 “Towards ToR 2”
    331 8. Add Connection “Towards ToR 2” with I/O Port 5101/5202
    332 
    333 === Configuting ToR1<->ToR3 Connection 2 ===
    334 
    335 * ROADM 4 (Same As For Connection 1):
    336 1. Enable MUX port 4102 “From ToR 1”
    337 2. Add Connection “From ToR 1” with I/O Port 4102/4201 with bandwidth [192.95;193.05]
    338 3. Enable DEMUX port 5202 “Towards ToR 1”
    339 4. Add Connection “Towards ToR 1” with I/O Port 5101/5202 with bandwidth [192.95;193.05]
    340 * ROADM 1 <Not Same!>:
    341 5. Enable MUX port 4101 “Through Port” (enabled for Snake)
    342 6. Add Connection “Through In” with I/O Port 4101/4201 with bandwidth [192.95;193.05]
    343 7. Enable DEMUX port 5201 “Through Port” (enabled for Snake)
    344 8. Add Connection “Through Out” with I/O Port 5101/5201 with bandwidth [192.95;193.05]
    345 * ROADM 2 (Same As For ROADM1):
    346 9. Enable MUX port 4101 “Through Port” (enabled for Snake)
    347 10. Add Connection “Through In” with I/O Port 4101/4201 with bandwidth [192.95;193.05]
    348 11. Enable DEMUX port 5201 “Through Port” (enabled for Snake)
    349 12. Add Connection “Through Out” with I/O Port 5101/5201 with bandwidth [192.95;193.05]
    350 * ROADM 3 (Same As For ROADM4):
    351 13. Enable MUX port 4102 “From ToR 3”
    352 14. Add Connection “From ToR 3” with I/O Port 4102/4201 with bandwidth [192.95;193.05]
    353 15. Enable DEMUX port 5202 “Towards ToR 3”
    354 16. Add Connection “Towards ToR 3” with I/O Port 5101/5202 with bandwidth [192.95;193.05]
    355 
    356327----
    357328
    358329= Network Interfaces Configuration for Experiment_1 =
    359 == Setting Up ToR switch with 3 logical ToR switches ==
    360 1. Preparing the interfaces to be set as VLAN switch ports:
    361 
    362 {{{
    363 sw-tor-lg1#configure
    364 sw-tor-lg1(conf)#interface twentyFiveGigE 1/1/1
    365 sw-tor-lg1(conf-if-tf-1/1/1)#switchport
    366 sw-tor-lg1(conf-if-tf-1/1/1)#no shutdown
    367 sw-tor-lg1(conf-if-tf-1/1/1)#exit
    368 sw-tor-lg1(conf)#interface twentyFiveGigE 1/1/2
    369 sw-tor-lg1(conf-if-tf-1/1/2)#switchport
    370 sw-tor-lg1(conf-if-tf-1/1/2)#no shutdown
    371 sw-tor-lg1(conf-if-tf-1/1/2)#exit
    372 sw-tor-lg1(conf)#interface twentyFiveGigE 1/1/3
    373 sw-tor-lg1(conf-if-tf-1/1/3)#switchport
    374 sw-tor-lg1(conf-if-tf-1/1/3)#no shutdown
    375 sw-tor-lg1(conf-if-tf-1/1/3)#exit
    376 sw-tor-lg1(conf)#interface tengigabitethernet 1/31/1
    377 sw-tor-lg1(conf-if-te-1/31/1)#switchport
    378 sw-tor-lg1(conf-if-te-1/31/1)#no shutdown
    379 sw-tor-lg1(conf-if-te-1/31/1)#exit
    380 sw-tor-lg1(conf)#interface tengigabitethernet 1/29/1
    381 sw-tor-lg1(conf-if-te-1/29/1)#switchport
    382 sw-tor-lg1(conf-if-te-1/29/1)#no shutdown
    383 sw-tor-lg1(conf-if-te-1/29/1)#exit
    384 sw-tor-lg1(conf)#interface tengigabitethernet 1/32/1
    385 sw-tor-lg1(conf-if-te-1/32/1)#switchport
    386 sw-tor-lg1(conf-if-te-1/32/1)#no shutdown
    387 sw-tor-lg1(conf-if-te-1/32/1)#exit
    388 }}}
    389 
    390 2. Assigning interfaces to VLANs
    391 
    392 {{{
    393 sw-tor-lg1#configure
    394 sw-tor-lg1(conf)#interface vlan 121
    395 sw-tor-lg1(conf-if-vl-121)#untagged twentyFiveGigE 1/1/1
    396 sw-tor-lg1(conf-if-vl-121)#untagged tengigabitethernet 1/32/1
    397 sw-tor-lg1(conf-if-vl-121)#exit
    398 sw-tor-lg1(conf)#interface vlan 122
    399 sw-tor-lg1(conf-if-vl-122)#untagged twentyFiveGigE 1/1/2
    400 sw-tor-lg1(conf-if-vl-122)#untagged tengigabitethernet 1/29/1
    401 sw-tor-lg1(conf-if-vl-122)#exit
    402 sw-tor-lg1(conf)#interface vlan 123
    403 sw-tor-lg1(conf-if-vl-123)#untagged twentyFiveGigE 1/1/3
    404 sw-tor-lg1(conf-if-vl-123)#untagged tengigabitethernet 1/31/1
    405 sw-tor-lg1(conf-if-vl-123)#exit
    406 sw-tor-lg1(conf)#exit
    407 }}}
    408 
    409 3. Assigning a wavelength to transceivers:
    410 
    411 {{{
    412 sw-tor-lg1#configure
    413 sw-tor-lg1(conf)#interface tengigabitethernet 1/32/1
    414 sw-tor-lg1(conf-if-te-1/32/1)#wavelength 1553.3
    415 sw-tor-lg1(conf-if-te-1/32/1)#exit
    416 sw-tor-lg1(conf)#interface tengigabitethernet 1/29/1
    417 sw-tor-lg1(conf-if-te-1/29/1)#wavelength 1553.3
    418 sw-tor-lg1(conf-if-te-1/29/1)#exit
    419 sw-tor-lg1(conf)#interface tengigabitethernet 1/32/1
    420 sw-tor-lg1(conf-if-te-1/32/1)#wavelength 1553.3
    421 sw-tor-lg1(conf-if-te-1/32/1)#exit
    422 sw-tor-lg1(conf)#exit
    423 }}}
    424 
    425 4. Verify VLANs:
    426 
    427 {{{
    428 sw-tor-lg1#show vlan
    429 
    430 Codes: * - Default VLAN, G - GVRP VLANs, R - Remote Port Mirroring VLANs, P - Primary, C - Community, I - Isolated
    431        O - Openflow, Vx - Vxlan
    432 Q: U - Untagged, T - Tagged
    433    x - Dot1x untagged, X - Dot1x tagged
    434    o - OpenFlow untagged, O - OpenFlow tagged
    435    G - GVRP tagged, M - Vlan-stack
    436    i - Internal untagged, I - Internal tagged, v - VLT untagged, V - VLT tagged
    437 
    438     NUM    Status    Description                     Q Ports
    439     121    Active                                    U Te 1/32/1
    440                                                      U Tf 1/1/1
    441     122    Active                                    U Te 1/29/1
    442                                                      U Tf 1/1/2
    443     123    Active                                    U Te 1/31/1
    444                                                      U Tf 1/1/3
    445 
    446 }}}
    447 
    448 == Configuring Compute Nodes (Servers srv1..3-lg1) ==
    449 
    450 1. Install net-tools:
    451 
    452 {{{#!shell-session
    453 sudo apt install net-tools
    454 }}}
    455 
    456 2. Configure interfaces eo1 and assign IP addresses:
    457 
    458 {{{#!shell-session
    459 native@srv1-lg1:~$ sudo ifconfig eno1 192.168.1.1 netmask 255.255.255.0
    460 native@srv2-lg1:~$ sudo ifconfig eno1 192.168.1.2 netmask 255.255.255.0
    461 native@srv3-lg1:~$ sudo ifconfig eno1 192.168.1.3 netmask 255.255.255.0
    462 }}}
    463 
    464 
    465 ----
    466 = Perform Experiment_1 =
     330== Setting Up ToR switches and configuring transceivers ==
     331
     332Mininet-Optical's Terminal is the equivalent of the ToR switch
     333which contains Ethernet interfaces as well as WDM transceivers.
     334
     335Instead of using a Cisco-style CLI to configure it, we use its
     336default REST API.
     337
     3381. Connecting Ethernet interfaces to Transceivers and set channel
     339
     340{{{
     341curl "localhost:8080/connect?node=tor1&ethPort=1&wdmPort=320&wdmInPort=321&channel=33"
     342curl "localhost:8080/connect?node=tor2&ethPort=2&wdmPort=290&wdmInPort=291&channel=33"
     343curl "localhost:8080/connect?node=tor3&ethPort=3&wdmPort=310&wdmInPort=311&channel=33"
     344}}}
     345
     3462. Turn on all transceivers
     347
     348{{{
     349curl "localhost:8080/turn_on?node=tor1"
     350curl "localhost:8080/turn_on?node=tor2"
     351curl "localhost:8080/turn_on?node=tor3"
     352}}}
     353
     354== Configuring Compute Nodes (server1, server2, server3) ==
     355
     3561. Configure Ethernet interfaces and assign IP addresses:
     357
     358This may be performed in at the mininet-optical CLI prompt:
     359{{{
     360mininet-optical> server1 ifconfig server1-eth0 192.168.1.1/24
     361mininet-optical> server2 ifconfig server2-eth0 192.168.1.2/24
     362minient-optical> server3 ifconfig server3-eth0 192.168.1.3/24
     363}}}
     364
     365Or it can be done remotely from a shell prompt in the VM using the
     366~/mininet/util/m script:
     367
     368{{{
     369~/mininet/util/m server1 ifconfig server1-eth0 192.168.1.1/24
     370~/mininet/util/m server2 ifconfig server2-eth0 192.168.1.2/24
     371~/mininet/util/m server3 ifconfig server3-eth0 192.168.1.3/24
     372}}}
     373
     374
     375----
     376= Perform Experiment =
    467377
    4683781. Establish Connection ToR1<->ToR2.
     
    470380
    471381{{{#!shell-session
    472 native@srv1-lg1:~$ ping 192.168.1.3
    473 PING 192.168.1.3 (192.168.1.3) 56(84) bytes of data.
    474 64 bytes from 192.168.1.3: icmp_seq=1 ttl=64 time=0.460 ms
    475 64 bytes from 192.168.1.3: icmp_seq=2 ttl=64 time=0.423 ms
    476 }}}
    477 
    478 3. Establish Connection ToR1<->ToR2.
    479 4. Try Ping from Srv1 to Srv3.
     382mininet-optical> server1 ping 192.168.1.3
     383
     384}}}
     385
     3863. Establish Connection ToR1<->ToR3.
     3874. Try Ping from server1 to server3.