CSS Corp Open Source Services

[OpenStack Beginner’s Guide for Ubuntu 11.04] Network Management

with one comment

In OpenStack, the networking is managed by a component called “nova-network”. This interacts with nova-compute to ensure that the instances have the right kind of networking setup for them to communicate among themselves as well as with the outside world. Just as in Eucalyptus or AWS, each OpenStack instance can have 2 IP addresses attached to it. One is the private IP address and the other called Public IP address. The private IP address is typically used for communication between instances and the public IP is used for communication of instances with the outside world. The so called public IP address need not be a public IP address routable on the Internet ; it can even be an address on the corporate LAN.

The network configuration inside the instance is done with the private IP address in view. The association between the private IP and the public IP and necessary routing is handled by nova-network and the instances need not be aware of it.

nova-network provides 3 different network management options. Currently you can only choose one of these 3 options for your network management.

  • Flat Network
  • Flat DHCP Network
  • VLAN Network

VLAN Network is the most feature rich and is the idea choice for a production deployment, while the other modes can be used while getting familiar with OpenStack and when you do not have VLAN Enabled switches to connect different components of the OpenStack infrastructure.

The network type is chosen by using one of the following configuration options in nova.conf file. If no network manager is specified explicitly, the default network manager, VLANManager is used.

 --network_manager = nova.network.manager.FlatManager
 --network_manager = nova.network.manager.FlatDHCPManager
 --network_manager = nova.network.manager.VlanManager

In each of these cases, run the following commands to set up private and public IP addresses for use by the instances:


sudo nova-manage network create 192.168.3.0/24 1 255
sudo nova-manage floating create 10.10.10.2 10.10.10.224/27

The public IP which you are going to associate with an instance needs to be allocated first by using “euca-allocate-address” command:

euca-allocate-address 10.10.2.225

You can then associate a public IP to a running instance by using “euca-associate-address” command:

euca-associate-address -i i-0000008 10.10.2.225

Please refer to http://docs.openstack.org/openstack-compute/admin/content/ch04.html for more details about each of the networking types.

Advertisements

One Response

Subscribe to comments with RSS.

  1. I’m trying to set up a Flat Network, but not sure how to configure /etc/network/interfaces and /etc/nova/nova.conf

    server1 is at 192.168.0.99, server2 at 192.168.0.97, and I have the IP range 192.168.0.90-192.168.0.96 for guests.

    Here’s how I have it configured now:

    /etc/network/interfaces:
    auto lo
    iface lo inet loopback

    auto br100
    iface br100 inet static
    bridge_ports eth0
    bridge_stp off
    bridge_maxwait 0
    bridge_fd 0
    address 192.168.0.99
    netmask 255.255.255.0
    network 192.168.0.0
    broadcast 192.168.0.255
    gateway 192.168.0.1

    /etc/nova/nova.conf:
    –dhcpbridge_flagfile=/etc/nova/nova.conf
    –dhcpbridge=/usr/bin/nova-dhcpbridge
    –logdir=/var/log/nova
    –state_path=/var/lib/nova
    –lock_path=/var/lock/nova
    –verbose
    –s3_host=192.168.0.99
    –rabbit_host=192.168.0.99
    –cc_host=192.168.0.99
    –ec2_url=http://192.168.0.99:8773/services/Cloud
    –network_manager=nova.network.manager.FlatManager
    –fixed_range=10.10.0.0/12
    –network_size=7
    –routing_source_ip=192.168.0.99
    –sql_connection=mysql://root:[password]@192.168.0.99/nova
    –glance_host=192.168.0.99
    –image_service=nova.image.glance.GlanceImageService
    –iscsi_ip_prefix=192.168.

    brian

    May 1, 2011 at 8:45 am


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: