Changes between Version 26 and Version 27 of GENIExperimenter/Tutorials/OpenFlowOVS/Execute

09/20/13 14:29:10 (6 years ago)



  • GENIExperimenter/Tutorials/OpenFlowOVS/Execute

    v26 v27  
    6464=== 2c. Point your switch to a controller ===
    6566An !OpenFlow switch will not forward any packet, unless instructed by a controller. Basically the forwarding table is empty, until an external controller inserts forwarding rules. The !OpenFlow controller communicates with the switch over the control network and it can be anywhere in the! Internet as long as it is reachable by the OVS host. For the purpose of this tutorial and in order to minimize the resources we have reserved we are going to run OpenFlow controller at the same host as the OVS switch. This is '''merely''' for convenience reasons, the controller could have been anywhere on the Internet.
    119120DEBUG:forwarding.l2_learning:installing flow for 02:c7:e8:a7:40:65.1 -> 02:f1:ae:bb:e3:a8.2
    120 ^C
     121 ^C
    121122INFO:core:Going down...
    122123INFO:openflow.of_01:[3a-51-a1-ab-c3-43 1] disconnected
    202203=== 3d. Run a port forward Controller ===
    203205Now let's do a slightly more complicated controller. OpenFlow gives you the power to overwrite fields of your packets at the switch, for example the TCP source or destination port and do port forwarding. You can have clients trying to contact a server at port 5000, and the OpenFlow switch can redirect your traffic to a service listening on port 6000.
    205207Under the `/loca/pox/ext` directory there are two files ! and that are similar like the previous exercise. Both of these controller are configured by a configuration file at `ext/port_forward.config`. Use to write your own port forwarding controller.
    207 To run the controller do (while at /local/pox directory)
    208 {{{
    209 ./ --verbose myPortForwarding
    210 }}}
    212209To test your controller we are going to use netcat. Go to the two terminals of host2. In one terminal run:
    222 Now first start the simple layer 2 forwarding controller:
     219Now, first start the simple layer 2 forwarding controller:
    224221./ --verbose forwarding.l2_learning
    232229Type something and you should see it at the the terminal of host2 at port 5000.
    234 Start your controller and do the same, now your text should appear on the other terminal of host2.
     231Now stop the simple layer 2 forwarding controller:
     233DEBUG:forwarding.l2_learning:installing flow for 02:d4:15:ed:07:4e.3 -> 02:ff:be:1d:19:ea.2
     234 ^C
     235INFO:core:Going down...
     236INFO:openflow.of_01:[36-63-8b-d7-16-4b 1] disconnected
     241Now start your port forwarding controller:
     243./ --verbose myPortForwarding
     246Repeat the netcat scenario described above. Now, your text should appear on the other terminal of host2.
     249Stop your port forwarding controller:
     251DEBUG:myPortForwarding:Got a packet : [02:aa:a3:e8:6c:db>33:33:ff:e8:6c:db IPV6]
     252 ^C
     253INFO:core:Going down...
     254INFO:openflow.of_01:[36-63-8b-d7-16-4b 1] disconnected
    236259=== 3e. Run a server proxy Controller ===
    237261As our last exercise, instead of diverging the traffic to a different server running on the same host, we will diverge the traffic to a server running on a different host and on a different port.
    251275  ./ --verbose myProxy
    252276  }}}
    253   6. Go back to the terminal of `host1` and try to connect to `host2` port 5000
     277  4. Go back to the terminal of `host1` and try to connect to `host2` port 5000
    254278  {{{
    255279  nc 5000