Setting up the network interfaces is something that seems to give people a hard time (clearly visible here: http://docs.openstack.org/grizzly/basic-install/apt/content/basic-install_network.html). If you follow that guide, one of the most confusing points is how the Open vSwitch fits into the existing architecture.

Assuming you are following the guide, you have 2 networks:
10.10.10.0/24 -> private
10.0.0.0/24 -> public

Your Network Controller, again per the guide, will have an internal-network interface of “10.10.10.9” and an external-network interface of “10.0.0.9”

Your starting network config (/etc/network/interfaces) file will look like this:

Now, you will first install the packages needed:

Then you will start the Open vSwitch:

At this point, you will create the Open vSwitch bridges and ports:

and finally, the part that gives everyone the hardest time, the resulting network config (/etc/network/interfaces) file should look like this after you are done:

The last piece is the firewall. Essentially, you are turning your 10.10.10.9 IP (interface) into a gateway for all of the other systems on the 10.10.10.0/24 network (specifically, the compute nodes which are only on that network). They will tunnel though the 10.10.10.9 interface out the br-ex (vSwitch bridge) to your “public” (in this case, again, 10.0.0.9 is public) network.

The firewall should look like this:

and one of the best ways to hook this into Ubuntu so that it auto loads on start up is to run the above to “create” the firewall. Then, save the existing rules to a file:

and then, create a small bash script (iptablesload) that loads it from: /etc/network/if-pre-up.d, which looks like this:

That’s it. You are done!

2 Thoughts on “OpenStack – Network Controller – Open vSwitch – Network Interfaces Config

  1. ibrahim on December 25, 2015 at 9:57 am said:

    Hi,
    Many thanks that helped me a lot.
    Best regards

Leave a Reply

Your email address will not be published. Required fields are marked *

>> NOTE: Please use <code>...</code> to post code/configs in your comment.

Post Navigation