Adventures in OpenStack – Tenant Networks

Tenant networks are the networks that instances directly attach to, and the network that instances will generally connect to each other on. Public attachment is handled by floating IP addresses, which are external network addresses usually NATed to instances via routers.

Here, I demonstrate how to set up a tenant network and a router, setting the stage for us to launch an instance and attach a floating IP address to it.

The Tenant Network

This is best set up under the appropriate tenant, under Project -> Network -> Networks. Click Create Network:

OpenStack Tenant Network 1

OpenStack Tenant Network 2

OpenStack Tenant Network 3

Note that I check Enable DHCP and also populate the DNS Name Servers this time. This will ensure that new instances get IPs without having to statically assign them, and they will also get a name server (in this case, Google’s).

Adding Routers and Attaching Networks

Head to Project -> Network -> Routers. Click Create Router:

OpenStack Router Creation

Next attach the public network. Click Set Gateway:

OpenStack Routers - Add Gateway

When this is done, a port is visible within the router details:

OpenStack Routers - Ports 1

Next, attach the tenant network. Click Add Interface:

OpenStack Routers - Add InterfaceThe IP can be left blank, and it will assign the first one in the network (should be 10.0.0.1 in this case).

Now both ports are visible and I can proceed to creating an instance!

OpenStack Routers - Ports 2

Advertisement