Review Board 1.7.22


Nicira NVP integration for CloudStack

Review Request #5590 - Created June 26, 2012 and submitted

Hugo Trippaers
Reviewers
cloudstack
cloudstack-git
Patch to add Nicira NVP support to CloudStack. As discussed this patch is related to phase 1, which is basic L2 connectivity. L3 connectivity and integration with the network offering for SNAT will be in phase2.
Simple build check
  clean-all build-all

Testing of all api calls
 * addNiciraNvpDevice
 * deleteNiciraNvpDevice		
 * listNiciraNvpDevices
 * listNiciraNvpDeviceNetwork

Functional testing using the following procedure
* start from clean db and create zone (with guest traffic on a physical network with stt isolation type)
* add NiciraNvp network service provider and enable
* add NiciraNcpDevice to physical network and configure using api
* create guestnetwork
* create instance linked to guest network
* check existence of logical switch and logical ports for routervm and instance
* check connectivity between routervm and instance
* destroy host
* after shutdown of routervm and network check logical switch and ports on nicira (should be gone)

README.NiciraIntegration
New File

    
   
1
Nicira Network Virtualization Platform (NVP) integration code is contributed 

    
   
2
by Nicira and Schuberg Philis and copyright is donated to the Apache Software

    
   
3
Foundation.

    
   
4

   

    
   
5
Authors

    
   
6
	Somik Behera <sbehera@nicira.com>

    
   
7
	Hugo Trippaers <htrippaers@schubergphilis.com>

    
   
8
	

    
   
9
== New API Calls 

    
   
10

   

    
   
11
The following API calls are added to CloudStack to support the integrations with

    
   
12
the Nicira NVP platform. Please see the API documentation of CloudStack for 

    
   
13
parameters and return values.

    
   
14

   

    
   
15
 * addNiciraNvpDevice

    
   
16
 * deleteNiciraNvpDevice		

    
   
17
 * listNiciraNvpDevices

    
   
18
 * listNiciraNvpDeviceNetworks

    
   
19

   

    
   
20
== How to enable the Nicira NVP integration.

    
   
21

   

    
   
22
When configuring a zone create a new physical network for "Guest" traffic and 

    
   
23
select "STT" as the isolation type. Set the Xen traffic label for "Guest" 

    
   
24
traffic to the label of the integration bridge (refer to the Nicira 

    
   
25
Documentation for setting up the integration bridge). Note that this requires 

    
   
26
all traffic types to have their traffic labels set.

    
   
27

   

    
   
28
These steps are specified by the API calls as there is currently no GUI 

    
   
29
available.

    
   
30

   

    
   
31
1. addNetworkServiceProvider

    
   
32
	name="NiciraNvp", physicalnetworkid=<see above>, 

    
   
33
	servicelist="Connectivity"

    
   
34
2. updateNetworkServiceProvider

    
   
35
	id=<id from step1>, state="Enabled"

    
   
36
3. addNiciraNvpDevice

    
   
37
	physicalnetworkid=<see step 1>, 

    
   
38
	hostname=<hostname or IP of the controller>

    
   
39
	username=<admin username>

    
   
40
	password=<admin password>

    
   
41
	transportzoneuuid=<transport zone uuid>

    
   
42

   

    
   
43
== How to use the Nicira integration

    
   
44

   

    
   
45
When creating a guest network make sure it is created in the physical network 

    
   
46
with the isolation type set to "STT". When the first virtual machine is 

    
   
47
launched in this network the NiciraNvpNetworkGuru will configure a logical 

    
   
48
switch on the NVP Controller. During the startup of a virtual machine the 

    
   
49
NiciraNvpElement will create a logical port for any NICs in the guest networks

    
   
50
and attach the port to the existing logical swith.

    
   
51

   

    
   
52
== Debugging/Troubleshooting

    
   
53

   

    
   
54
All elements created on the NVP controller have tags with the name of the 

    
   
55
account, this can be used to search the items using the NVP manager. The NVP 

    
   
56
uuid of the logical switch is also stored in the BroadcastUri of the 

    
   
57
corresponding Guest network in an lswitch uri scheme. The CloudStack uuid of 

    
   
58
the NIC is used to make the Vif attachement on the logical switchport.

    
   
59

   

    
   
60
The following classes should be set to log level debug when troubleshooting.

    
   
61
    com.cloud.network 

    
   
62
        (Most NiciraNvp related objects live in this package and subpackages)

    
   
63
    org.apache.commons.httpclient 

    
   
64
        (used by NiciraNvpApi to make calls to the SDN Controller)

    
   
65
	httpclient.wire

    
   
66
        (wirelevel http tracing of httpclient)

    
   
67
	

    
   
68
Please report any findings to the developer mailing list.
cloud.spec
Revision 773a729 New Change
 
wscript_configure
Revision 0ccf40a New Change
 
api/src/com/cloud/agent/api/CreateLogicalSwitchAnswer.java
New File
 
api/src/com/cloud/agent/api/CreateLogicalSwitchCommand.java
New File
 
api/src/com/cloud/agent/api/CreateLogicalSwitchPortAnswer.java
New File
 
api/src/com/cloud/agent/api/CreateLogicalSwitchPortCommand.java
New File
 
api/src/com/cloud/agent/api/DeleteLogicalSwitchAnswer.java
New File
 
api/src/com/cloud/agent/api/DeleteLogicalSwitchCommand.java
New File
 
api/src/com/cloud/agent/api/DeleteLogicalSwitchPortAnswer.java
New File
 
api/src/com/cloud/agent/api/DeleteLogicalSwitchPortCommand.java
New File
 
api/src/com/cloud/agent/api/StartupNiciraNvpCommand.java
New File
 
api/src/com/cloud/agent/api/to/NicTO.java
Revision b65c61e New Change
 
api/src/com/cloud/agent/api/to/VirtualMachineTO.java
Revision 42d9162 New Change
 
api/src/com/cloud/api/ApiConstants.java
Revision 00ec392 New Change
 
api/src/com/cloud/host/Host.java
Revision 0c9d06d New Change
 
api/src/com/cloud/network/Network.java
Revision 0443a0f New Change
 
api/src/com/cloud/network/Networks.java
Revision 84135b8 New Change
 
api/src/com/cloud/network/PhysicalNetwork.java
Revision e54fe00 New Change
 
build/build-cloud-plugins.xml
Revision 61b0e62 New Change
 
  1. README.NiciraIntegration: Loading...
  2. cloud.spec: Loading...
  3. wscript_configure: Loading...
  4. api/src/com/cloud/agent/api/CreateLogicalSwitchAnswer.java: Loading...
  5. api/src/com/cloud/agent/api/CreateLogicalSwitchCommand.java: Loading...
  6. api/src/com/cloud/agent/api/CreateLogicalSwitchPortAnswer.java: Loading...
  7. api/src/com/cloud/agent/api/CreateLogicalSwitchPortCommand.java: Loading...
  8. api/src/com/cloud/agent/api/DeleteLogicalSwitchAnswer.java: Loading...
  9. api/src/com/cloud/agent/api/DeleteLogicalSwitchCommand.java: Loading...
  10. api/src/com/cloud/agent/api/DeleteLogicalSwitchPortAnswer.java: Loading...
  11. api/src/com/cloud/agent/api/DeleteLogicalSwitchPortCommand.java: Loading...
  12. api/src/com/cloud/agent/api/StartupNiciraNvpCommand.java: Loading...
  13. api/src/com/cloud/agent/api/to/NicTO.java: Loading...
  14. api/src/com/cloud/agent/api/to/VirtualMachineTO.java: Loading...
  15. api/src/com/cloud/api/ApiConstants.java: Loading...
  16. api/src/com/cloud/host/Host.java: Loading...
  17. api/src/com/cloud/network/Network.java: Loading...
  18. api/src/com/cloud/network/Networks.java: Loading...
  19. api/src/com/cloud/network/PhysicalNetwork.java: Loading...
  20. build/build-cloud-plugins.xml: Loading...
This diff has been split across 3 pages: 1 2 3 >