[[PageOutline]] = Appendix - Move to HW switches = '''Notes about this tutorial''' * This is '''not''' a standalone tutorial. Please refer to the [wiki:GENIExperimenter/Tutorials/OpenFlowOVS Intro to OpenFlow using OVS] for background. * The topology used in this experiment is the same as the one used in the [wiki:GENIExperimenter/Tutorials/OpenFlowOVS Intro to OpenFlow using OVS] tutorial: Three virtual machines (VMs) connected by an !OpenFLow switch. However this tutorial uses the hardware !OpenFlow switch on the rack instead of a software OVS switch. * If you have not reserved a controller yet, make sure you to create a slice that will run the !OpenFlow controller: Reserve a VM running the controller using the request RSpec [http://www.gpolab.bbn.com/exp/OpenFlowOVS/pox-controller.rspec]. This RSpec is available at the Portal and is called "XEN VM POX Ctrl" '''About GENI !OpenFlow switches''' [[BR]] GENI offers access to hardware !OpenFlow switches. Each !OpenFlow switch, in most cases, can support only one controller. There are two ways of slicing the controller flowspace: 1. By VLAN id. This is used when each slice has its own VLANs. 2. By IP addresses or by Ethernet type. This is used when multiple slices share the same VLAN. For example, the Mesoscale VLAN 1750 that has been set up as a shared VLAN on all GENI racks. Both approaches to slicing are covered in this tutorial. To force the links between the VMs to go through the rack !OpenFlow switch, the three VMs must be on separate physical hosts on the rack. Since each InstaGENI rack has two hosts with Xen VMs and one with OpenVZ VMs, our experiment will: * Use 2 Xen VMs and 1 OpenVZ VM * Bind the Xen VMs to different physical hosts. == 1. !Design/Setup == The RSpecs for this tutorial are site specific. If you are attending a tutorial, use the site and IP network that was given to you on your worksheet. If you are doing this at home, choose a site from : `clemson, cornell, gatech, gpo, illinois, kansas, sky, kettering, max, missouri, northwestern, nysernet, nyu, sox, stanford, wisconsin`. === 1.1 Find your RSPecs === ''In the URLs below, replace with the name of the site you are using (clemson, cornell, kansas, uky, kettering, max, northwestern, nysernet, stanford or wisconsin). '' '''If you are using a private VLAN:''' The RSpecs you need is at: * {{{http://www.gpolab.bbn.com/experiment-support/OpenFlowHW/pvtVlan/ig-.rspec}}}. (Reserves compute resources and specifies location of your controller.) '''If you are using a shared VLAN:''' You will need two RSpecs, one to reserve the compute nodes and one to reserve your flowspace using the !OpenFlow aggregate manager on the rack. The !OpenFlow aggregate manager is called FOAM. The RSPecs are at: * {{{http://www.gpolab.bbn.com/experiment-support/OpenFlowHW/sharedVlan/ig-AGGREGATE-NAME>.rspec}}} (Reserves compute resources.) * {{{http://www.gpolab.bbn.com/experiment-support/OpenFlowHW/sharedVlan/ig-of-AGGREGATE-NAME>.rspec}}} (Reserves flowspace resources.) === 1.2 Edit your RSpecs === Open your RSpec in a text editor to make the following changes: '''If you are using a private VLAN:''' [[BR]] * Replace the string (at the bottom of the RSpec) with the IP address of your controller. '''If you are using a shared VLAN:''' [[BR]] * In the RSpec for flowspace resources, replace: - SITE with the site you are using - NETWORK with the one in your worksheet. If you are doing this at home, use a network between 10.20.30 - 10.20.49. === 1.3 Reserve Resources === '''If you are using a private VLAN:''' [[BR]] * Use your favorite resource reservation tool (Omni, jFed, Portal) to reserve your resources. For example, if you are using Omni and the MAX aggregate: {{{ omni -a max-ig createsliver ig-max.rspec }}} '''If you are using a shared VLAN:''' [[BR]] * You will need to reserve your compute and flowspace resources separately using your favorite resource reservation tool (Omni, jFed, Portal). For example, [[BR]] {{{ omni -a max-ig createsliver ig-max.rspec }}} (to reserve compute resources) [[BR]] {{{ omni -a max-ig-of createsliver ig-max.rspec }}} (to reserve flowspace resources) == Useful tips == === Which port is connected to which host === Run the learning pox controller with debug ''(--verbose)'' on (use the command from the OVS tutorial) and start a ping from host1 to host2 and host3. Notice that the printout of pox will have lines like: {{{ DEBUG:forwarding.l2_learning:installing flow for 02:b4:88:6d:83:f7.1 -> 02:36:8d:c2:b0:14.8 }}} The format after `for` and `->` is . so this way you know which port is connected to which host. To figure out the name for each port then it is simply `A` so if host 1 is out of port 8, then the name is `A8`. === Configuration files of controllers === For the proxy and the port_forwarding controllers you will need to modify the config files (port_forward.config, proxy.config) to use the appropriate IP dataplane IP addresses of your hosts to correctly configure your controllers. {{{ #!comment == Design/Setup == The [wiki:GENIExperimenter/Tutorials/OpenFlowOVS topology] for this experiment is very similar to the one that uses OVS, the main difference is that instead of the OVS we are going to connect the compute resources to a hardware OpenFlow switch. When working with hardware switches the reservation usually happens in two steps: 1. Reserve all your hosts (including the host that will be the controller) 2. Reserve the OpenFlow resources (for this you will need the controller public IP from the previous step). }}} {{{ #!comment === 2. Reserve Network Resources === While your compute resources are being reserved and configured. The first thing we need to do is use the manifest information to figure out the IP of our controller. i. Wait for the manifest to be returned, once this is done the jfed screen will change to look like the folling image: [[Image(jfed_manifest.png,50%)]] ii. Open a terminal and run: `nslookup HOSTNAME` In the following instructions replace: * CONTROLLER_IP with the IP you just learned Do the following steps: i. In JFed go back to the general view i. Load URL: `http://www.gpolab.bbn.com/exp/OpenFlowHW/rspecs/ig-of-SITE.rspec` in jfed i. Use the search and replace functionality of the rspec editor in jFed to replace "NETWORK" with your network i. Use the search and replace functionality of the rspec editor in jFed to replace "CONTROLLER_IP" with your controller ip i,. Save the rspec i. Use omni to reserve the resources using as your am SITE-of-ig and the same slice you created for your compute resources If you get no error you are all set. Once your compute resources are reserved you can go back and repeat the same exercises now running on a hw switch. '''NOTE''': You might get some errors when loading POX, just ignore them. }}}