From Fedora Project Wiki

(move to OpenStack category)
No edit summary
Line 3: Line 3:
The [http://wiki.openstack.org/Quantum Quantum] project provides "network connectivity as a service". This page tracks [[Cloud SIG|Fedora Cloud SIG]]'s effort to maintain Quantum in Fedora.  
The [http://wiki.openstack.org/Quantum Quantum] project provides "network connectivity as a service". This page tracks [[Cloud SIG|Fedora Cloud SIG]]'s effort to maintain Quantum in Fedora.  


This page will address the installation and configuration of the following:
This page will address the installation and configuration of the following plugins:
* Quantum Server
* Open vSwitch
* Quantum Plugins
* Linux Bridge
 
In addition to this it will address following:
* supported Grizzly plugins


The packaging can be found at:
The packaging can be found at:
* [https://admin.fedoraproject.org/pkgdb/acls/name/openstack-quantum openstack-quantum] [https://bugzilla.redhat.com/buglist.cgi?component=openstack-quantum&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=MODIFIED&bug_status=POST (bugs)]
* [https://admin.fedoraproject.org/pkgdb/acls/name/openstack-quantum openstack-quantum] [https://bugzilla.redhat.com/buglist.cgi?component=openstack-quantum&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=MODIFIED&bug_status=POST (bugs)]


== Quantum Server ==
== Open vSwitch ==
 
=== '''Quantum Service''' ===


=== '''Installation''' ===
The Quantum service is installed as follows:
The Quantum service is installed as follows:
   #> sudo yum install openstack-quantum
   #> sudo yum install openstack-quantum
  #> sudo yum install openstack-quantum-openvswitch


OpenStack has a preview [[OpenStack#Preview repository|repository]], allowing Fedora N-1 users to try out OpenStack packages from the latest Fedora release.
The Quantum service is configured as follows:
 
=== '''Configuration''' ===
The Quantum service requires the installation and configuration of a database. This can be achieved by running the following:
 
   #> sudo quantum-server-setup
   #> sudo quantum-server-setup


The above script makes use of a number of default settings. Make use of the ''--help'' option to see what can be configured. This will ensure that Quantum database is installed, started and configured. In addition to this the user will be requested to supply the relevant plugin. The plugins are discussed below.
'''Note''' the above script will create the database and set the relevant configuration files to work with the open vswitch plugin. Some of the value set are related to keystone.


Once the database has been created an configured the quantum service should be enabled and started.
Once the service has been configured it can be started as follows:
  #> sudo service quantum-server start
  #> sudo chkconfig quantum-server on


  #> sudo systemctl enable quantum-server.service
=== '''Compute Node''' ===
  #> sudo systemctl start quantum-server.service


'''Note''' the Quantum server should always start after the mysqld. This can be addressed by the following command:
A compute node will need the agent to be configured and run.
  #> sudo yum install openstack-quantum-openvswitch


   #> sudo sed -i /usr/lib/systemd/system/quantum-server.service -e 's/^\(After=.*\)/\1 mysqld.service/'
The agent is configured follows:
   #> sudo quantum-node-setup


'''Note''' if using Fedora 16, use /lib/systemd/... instead of /usr/lib/systemd/... in the above command.
Once configured it can be started as follows:
  #> sudo service quantum-openvswitch-agent start
  #> sudo chkconfig quantum-openvswitch-agent on


'''Note''' the Quantum agent also needs to be enabled and started. Please see below.
'''Note''' if the host is rebooted then the openvswitch will create tap devices that existed on the switch prior to the reboot. This may affect the way in which the various quantum agents function. This is addressed by ensuring that the quantum-ovs-cleanup script is run at boot. This is done as follows:
  #> sudo chkconfig quantum-ovs-cleanup on


=== '''OpenStack''' ===
=== '''IPAM''' ===
Please note that the script ''quantum-server-setup'' will update the nova configuration file.


''Keystone'' Integration - TBD
The Quantum DHCP agent enables VM's that are launched on a Quantum network to receive a IP address. The DHCP agent is part of the openstack-quantum package. This is installed as follows:
  #> sudo yum install openstack-quantum


== Quantum Agents ==
The DHCP agent is configured as follows (please select openvswitch for the plugin):
The agent is responsible for the dynamic configuration of the switches. The following plugin agents are supported:
  #> sudo quantum-dhcp-setup
 
* [http://wiki.openstack.org/cisco-quantum Cisco]
* [http://wiki.openstack.org/Quantum-Linux-Bridge-Plugin Linux Bridge]
* [http://nicira.com/en/platform-for-innovation Nicira]
* [http://openvswitch.org/openstack/documentation/ Open vSwitch]
* [http://www.osrg.net/ryu/index.html RYU]


=== '''Installation''' ===
Once the agent has been configured it can be started as follows:
Each agent has its own installation package:
  #> sudo service quantum-dhcp-agent start
  #> sudo chkconfig quantum-dhcp-agent on


* Cisco
'''Note''' if the DHCP agent is not run on a compute node then the same installation for the compute node need to performed.


  #> sudo yum install openstack-quantum-cisco
=== '''Floating IP Support''' ===


* Linux Bridge
The Quantum L3 agent provides floating IP support for VM's that are launched. The L3 agent is part of the openstack-quantum package. This is installed as follows:
  #> sudo yum install openstack-quantum


   #> sudo yum install openstack-quantum-linuxbridge
The L3 agent is configured as follows (please select openvswitch for the plugin):
   #> sudo quantum-l3-setup


* Nicira
Once the agent has been configured it can be started as follows:
  #> sudo service quantum-l3-agent start
  #> sudo chkconfig quantum-l3-agent on


   #> sudo yum install openstack-quantum-nicira
In order for the VM to be able communicate with the Nova meta data service then the quantum-metadata-agent needs to be run.
   #> sudo service quantum-metadata-agent start
  #> sudo chkconfig quantum-metadata-agent on


* Open vSwitch
'''Note''' if the L3 agent is not run on a compute node then the same installation for the compute node need to performed.


  #> sudo yum install openstack-quantum-openvswitch
== Linux Bridge ==


An OVS “integration” bridge must be created. The VMs will connect to this bridge.
=== '''Quantum Service''' ===


   #> sudo ovs-vsctl add-br br-int
The Quantum service is installed as follows:
   #> sudo yum install openstack-quantum
  #> sudo yum install openstack-quantum-linuxbridge


If you wish to connect this to an physical NIC, for example eth0), then do:
The Quantum service is configured as follows:
  #> sudo quantum-server-setup


  #> sudo ovs-vsctl add-port br-int eth0
'''Note''' the above script will create the database and set the relevant configuration files to work with the open vswitch plugin. Some of the value set are related to keystone.


'''Note''' that br-int is defined in the ovs-quantum_plugin.ini file.
Once the service has been configured it can be started as follows:
  #> sudo service quantum-server start
  #> sudo chkconfig quantum-server on


* RYU
=== '''Compute Node''' ===


   #> sudo yum install openstack-quantum-ryu
A compute node will need the agent to be configured and run.
 
   #> sudo yum install openstack-quantum-linuxbridge
The agents need to be installed on all of the compute nodes.
 
=== '''Configuration''' ===
The Quantum plugin must be configured so that it can interface with the Quantum server. This can be achieved by running the following:


The agent is configured follows:
   #> sudo quantum-node-setup
   #> sudo quantum-node-setup


The above script makes use of a number of default settings. Make use of the ''--help'' option to see what can be configured. The Quantum database hostname is very important. Please make sure that this is defined in the hosts file.
Once configured it can be started as follows:
  #> sudo service quantum-linuxbridge-agent start
  #> sudo chkconfig quantum-linuxbridge-agent on


=== '''IPAM and Floating IP support''' ===
This is the same as the openvswitch support. One just needs to select the linux bridge plugin.


Both the linuxbridge and openvswitch plugins use qemu's "ethernet" network device, so to work around the problem described in https://bugzilla.redhat.com/show_bug.cgi?id=770020, do the following if using one of these plugins:
== Quantum Plugins ==
In Grizzly the following plugins are supported:


$> sudo systemctl stop libvirtd.service
* [http://wiki.openstack.org/cisco-quantum Cisco]
$> cat >> /etc/libvirt/qemu.conf <<EOF
* [http://wiki.openstack.org/Quantum-Linux-Bridge-Plugin Linux Bridge]
cgroup_device_acl = [
* [http://nicira.com/en/platform-for-innovation Nicira]
    "/dev/null", "/dev/full", "/dev/zero",
* [http://openvswitch.org/openstack/documentation/ Open vSwitch]
    "/dev/random", "/dev/urandom",
* [http://www.osrg.net/ryu/index.html RYU]
    "/dev/ptmx", "/dev/kvm", "/dev/kqemu",
    "/dev/rtc", "/dev/hpet", "/dev/net/tun",
]
EOF
$> sudo systemctl start libvirtd.service
 
 
Please note that you need to enable and start the relevant plugin agents. These are listed below:
 
* Linux Bridge


  #> sudo systemctl enable quantum-linuxbridge-agent.service
* [http://wiki.openstack.org/wiki/Quantum_NEC_OpenFlow_Plugin NEC]
  #> sudo systemctl start quantum-linuxbridge-agent.service
* [http://www.openflowhub.org/display/floodlightcontroller/Quantum+REST+Proxy+Plugin BigSwitch]
 
* [http://www.cloudbase.it/quantum-hyper-v-plugin/ CoudBase Hyper-V]
* Open vSwitch
* [http://www.midokura.com/ Open MidoNet]
 
* [http://www.brocade.com/ brocade]
  #> sudo systemctl enable quantum-openvswitch-agent.service
* [http://www.plumgrid.com/ PLUMGrid]
  #> sudo systemctl start quantum-openvswitch-agent.service
 
In addition to this make sure that the openvswitch service is enabled and running.
 
  #> sudo systemctl enable openvswitch.service
  #> sudo systemctl start openvswitch.service
 
* RYU
 
  #> sudo systemctl enable quantum-ryu-agent.service
  #> sudo systemctl start quantum-ryu-agent.service
 
=== '''OpenStack''' ===
Please note that the script ''quantum-node-setup'' will update the nova configuration file.
 
''Keystone'' Integration - TBD


== Troubleshooting ==
== Troubleshooting ==
Line 157: Line 145:
     quantum_connection_port=9696
     quantum_connection_port=9696
     quantum_use_dhcp=True
     quantum_use_dhcp=True
* Cisco
    scheduler_driver=quantum.plugins.cisco.nova.quantum_port_aware_scheduler.QuantumPortAwareScheduler
    libvirt_vif_type=802.1Qbh
    libvirt_vif_driver=quantum.plugins.cisco.nova.vifdirect.Libvirt802dot1QbhDriver
* Linux Bridge:
    libvirt_vif_type=ethernet
    libvirt_vif_driver=nova.virt.libvirt.vif.QuantumLinuxBridgeVIFDriver
    linuxnet_interface_driver=nova.network.linux_net.QuantumLinuxBridgeInterfaceDriver
* Open vSwitch:
    libvirt_vif_type=ethernet
    libvirt_vif_driver=nova.virt.libvirt.vif.LibvirtOpenVswitchDriver
    linuxnet_interface_driver=nova.network.linux_net.LinuxOVSInterfaceDriver


== Useful Quantum Links ==
== Useful Quantum Links ==

Revision as of 09:29, 24 March 2013

Quantum

The Quantum project provides "network connectivity as a service". This page tracks Fedora Cloud SIG's effort to maintain Quantum in Fedora.

This page will address the installation and configuration of the following plugins:

  • Open vSwitch
  • Linux Bridge

In addition to this it will address following:

  • supported Grizzly plugins

The packaging can be found at:

Open vSwitch

Quantum Service

The Quantum service is installed as follows:

 #> sudo yum install openstack-quantum
 #> sudo yum install openstack-quantum-openvswitch

The Quantum service is configured as follows:

 #> sudo quantum-server-setup

Note the above script will create the database and set the relevant configuration files to work with the open vswitch plugin. Some of the value set are related to keystone.

Once the service has been configured it can be started as follows:

 #> sudo service quantum-server start
 #> sudo chkconfig quantum-server on

Compute Node

A compute node will need the agent to be configured and run.

 #> sudo yum install openstack-quantum-openvswitch

The agent is configured follows:

 #> sudo quantum-node-setup

Once configured it can be started as follows:

 #> sudo service quantum-openvswitch-agent start
 #> sudo chkconfig quantum-openvswitch-agent on

Note if the host is rebooted then the openvswitch will create tap devices that existed on the switch prior to the reboot. This may affect the way in which the various quantum agents function. This is addressed by ensuring that the quantum-ovs-cleanup script is run at boot. This is done as follows:

 #> sudo chkconfig quantum-ovs-cleanup on

IPAM

The Quantum DHCP agent enables VM's that are launched on a Quantum network to receive a IP address. The DHCP agent is part of the openstack-quantum package. This is installed as follows:

 #> sudo yum install openstack-quantum

The DHCP agent is configured as follows (please select openvswitch for the plugin):

 #> sudo quantum-dhcp-setup

Once the agent has been configured it can be started as follows:

 #> sudo service quantum-dhcp-agent start
 #> sudo chkconfig quantum-dhcp-agent on

Note if the DHCP agent is not run on a compute node then the same installation for the compute node need to performed.

Floating IP Support

The Quantum L3 agent provides floating IP support for VM's that are launched. The L3 agent is part of the openstack-quantum package. This is installed as follows:

 #> sudo yum install openstack-quantum

The L3 agent is configured as follows (please select openvswitch for the plugin):

 #> sudo quantum-l3-setup

Once the agent has been configured it can be started as follows:

 #> sudo service quantum-l3-agent start
 #> sudo chkconfig quantum-l3-agent on

In order for the VM to be able communicate with the Nova meta data service then the quantum-metadata-agent needs to be run.

 #> sudo service quantum-metadata-agent start
 #> sudo chkconfig quantum-metadata-agent on

Note if the L3 agent is not run on a compute node then the same installation for the compute node need to performed.

Linux Bridge

Quantum Service

The Quantum service is installed as follows:

 #> sudo yum install openstack-quantum
 #> sudo yum install openstack-quantum-linuxbridge

The Quantum service is configured as follows:

 #> sudo quantum-server-setup

Note the above script will create the database and set the relevant configuration files to work with the open vswitch plugin. Some of the value set are related to keystone.

Once the service has been configured it can be started as follows:

 #> sudo service quantum-server start
 #> sudo chkconfig quantum-server on

Compute Node

A compute node will need the agent to be configured and run.

 #> sudo yum install openstack-quantum-linuxbridge

The agent is configured follows:

 #> sudo quantum-node-setup

Once configured it can be started as follows:

 #> sudo service quantum-linuxbridge-agent start
 #> sudo chkconfig quantum-linuxbridge-agent on

IPAM and Floating IP support

This is the same as the openvswitch support. One just needs to select the linux bridge plugin.

Quantum Plugins

In Grizzly the following plugins are supported:

Troubleshooting

Quantum Server

  • /etc/quantum/plugins.ini contains the specific plugin module. Check that this matches the intended plugin
  • /etc/quantum/quantum.conf contains information relevant to the server. Check that the server is running and that the bind_port is indeed up.
  • If the Quantum server does not start after reboot, and you are using mysql, then make sure that the Quantum server starts after the mysqld.service.

Quantum Plugin

  • /etc/quantum/plugins.ini contains the specific plugin module. Check that this matches the intended plugin
  • /etc/quantum/quantum.conf contains the specific plugin module. Check that this matches the intended plugin
  • /var/log/messages may contain information regarding the agent

OpenStack

  • It may be useful to look for errors in /var/log/nova/network.log and /var/log/nova/nova-dhcpbridge.log
  • Common configuration: /etc/nova/nova.conf contains the relevant quantum configuration.
   network_manager=nova.network.quantum.manager.QuantumManager
   quantum_connection_host=localhost
   quantum_connection_port=9696
   quantum_use_dhcp=True

Useful Quantum Links