Difference between revisions of "Cisco-n1kv-neutron"
m (→Devstack) |
m (→Devstack) |
||
Line 161: | Line 161: | ||
[[Category: Neutron]] | [[Category: Neutron]] | ||
− |
Latest revision as of 16:49, 11 February 2015
Contents
Nexus1000v Neutron Plugin
Overview
Nexus1000v Neutron Plugin v2 implements the Neutron v2.0 API.
Requirements
- Cisco Nexus1000v for KVM Release 5.2(1)SK(2.2) (or higher)
Configuration
Nexus1000v Neutron Plugin Configuration
- MySQL should be installed on the host. Initialize MySQL as follows (where $PASS = mysql password):
$ mysql -u root -p$PASS -e 'DROP DATABASE IF EXISTS cisco_neutron;' $ mysql -u root -p$PASS -e 'CREATE DATABASE IF NOT EXISTS cisco_neutron;' $ mysql -u root -p$PASS -e 'GRANT ALL ON cisco_neutron.* TO '$Neutron_User'@'%' IDENTIFIED BY '$Neutron_Pass';
- Edit /etc/neutron/neutron.conf and set provider as:
[DEFAULT] core_plugin = neutron.plugins.cisco.network_plugin.PluginV2 [DATABASE] sql_connection = mysql://<username>:<password>@<database_ip>:3306/cisco_neutron
- Edit the file /etc/neutron/plugins/cisco/cisco_plugins.ini and comment out as need it:
[CISCO_PLUGINS] # (StrOpt) Period-separated module path to the plugin class to use for # the Cisco Nexus switches. # #nexus_plugin = neutron.plugins.cisco.nexus.cisco_nexus_plugin_v2.NexusPlugin # (StrOpt) Period-separated module path to the plugin class to use for # the virtual switches on compute nodes. # vswitch_plugin = neutron.plugins.cisco.n1kv.n1kv_neutron_plugin.N1kvNeutronPluginV2 [cisco] # Cisco Nexus Switch configurations. # Each switch to be managed by Openstack Neutron must be configured here. # # Cisco Nexus Switch Format. # [NEXUS_SWITCH:<IP address of switch>] # <hostname>=<port> (1) # ssh_port=<ssh port> (2) # username=<credential username> (3) # password=<credential password> (4) # # (1) For each host connected to a port on the switch, specify the hostname # and the Nexus physical port (interface) it is connected to. # (2) The TCP port for connecting via SSH to manage the switch. This is # port number 22 unless the switch has been configured otherwise. # (3) The username for logging into the switch to manage it. # (4) The password for logging into the switch to manage it. # # Example: # [NEXUS_SWITCH:1.1.1.1] # compute1=1/1 # compute2=1/2 # ssh_port=22 # username=admin # password=mySecretPassword # [N1KV:<IP address of VSM>] # username=<credential username> # password=<credential password> # # Example: # [N1KV:2.2.2.2] # username=admin # password=mySecretPassword [cisco_n1k] # (StrOpt) Specify the name of the integration bridge to which the VIFs are # attached. # # Example: integration_bridge = br-int # (StrOpt) Name of the policy profile to be associated with a port when no # policy profile is specified during port creates. # # Example: default_policy_profile = service_profile # (StrOpt) Name of the policy profile to be associated with a port owned by # network node (dhcp, router). # # Example: network_node_policy_profile = dhcp_pp # (StrOpt) Name of the network profile to be associated with a network when no # network profile is specified during network creates. Admin should pre-create # a network profile with this name. # # Example: default_network_profile = network_pool # (StrOpt) Time in seconds for which the plugin polls the VSM for updates in # policy profiles. # # Example: poll_duration = 180 [database] # (StrOpt) Connection to the neutron_l2network database # # connection = mysql://<credential username>:<credential password>@127.0.0.1/cisco_neutron?charset=utf8 # Example: connection = mysql://root:mySecretPassword@127.0.0.1/cisco_neutron?charset=utf8
Configuration Example
[CISCO_PLUGINS] vswitch_plugin = neutron.plugins.cisco.n1kv.n1kv_neutron_plugin.N1kvNeutronPluginV2 [CISCO] [N1KV:10.10.10.10] username = admin password = mySecretPassword [CISCO_N1K] integration_bridge = br-int default_policy_profile = service_pp network_node_policy_profile = dhcp_pp poll_duration = 10 [DATABASE] connection = mysql://root:cisco@127.0.0.1/cisco_neutron?charset=utf8 Start the neutron service by providing the relevant configuration files: cd <neutron_path> && python <neutron_path>/bin/neutron-server --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/plugins/cisco/cisco_plugins.ini
Devstack
Include in "localrc/local.conf" file the following variables:
Q_PLUGIN=cisco