To understand how networking should initially be configured on each host, refer to the following diagram:
In the preceding diagram, three interfaces are cabled to each host. The eth0 interface will serve as the management interface for OpenStack services and API access. The eth1 interface will be used for overlay network traffic between hosts. On the controller node, eth2 will be used for external network traffic to instances through Neutron routers. If VLAN tenant networks are used in lieu of overlay networks such as VXLAN and GRE, then eth2 will be configured on the compute nodes to support those networks.
At a minimum, the management interface should be configured with an IP address that has outbound access to the Internet. Internet access is required to download OpenStack packages from the Ubuntu package repository. Inbound access to the management address of the servers from a trusted network via SSH (TCP port 22
) is recommended.
Throughout the book, there will be examples on configuring and using various OpenStack services. The following table provides the VLANs and associated networks used for those services:
VLAN name |
VLAN ID |
Network |
---|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The following tables provide IP addresses and VLAN IDs recommended for each host interface, should you choose to follow along with the examples:
controller01.learningneutron.com
Interface |
IP address |
Switchport |
VLAN ID |
---|---|---|---|
|
|
Access port |
VLAN 10 (Untagged) |
|
|
Access port |
VLAN 20 (Untagged) |
|
None |
Trunk port |
VLAN 30-33,50 (Tagged) |
compute01.learningneutron.com
Interface |
IP address |
Switchport |
VLAN ID |
---|---|---|---|
|
|
Access port |
VLAN 10 (Untagged) |
|
|
Access port |
VLAN 20 (Untagged) |
|
None |
Trunk port |
VLAN 30-33,50 (Tagged) |
compute02.learningneutron.com
Interface |
IP address |
Switchport |
VLAN ID |
---|---|---|---|
|
|
Access port |
VLAN 10 (Untagged) |
|
|
Access port |
VLAN 20 (Untagged) |
|
None |
Trunk port |
VLAN 30-33,50 (Tagged) |
In the event of connectivity loss, out-of-band management access to the servers via DRAC, iLo, or some other IPMI mechanism is highly recommended.
Ubuntu uses a configuration file found at /etc/network/interfaces
that describes how network interfaces should be configured.
Using a text editor, update the network interface file on each host as follows:
For controller01:
auto eth0 iface eth0 inet static address 10.254.254.100 netmask 255.255.255.0 gateway 10.254.254.1 dns-nameserver 8.8.8.8 auto eth1 iface eth1 inet static address 172.18.0.100 netmask 255.255.255.0 auto eth2 iface eth2 inet manual
For compute01:
auto eth0 iface eth0 inet static address 10.254.254.101 netmask 255.255.255.0 gateway 10.254.254.1 dns-nameserver 8.8.8.8 auto eth1 iface eth1 inet static address 172.18.0.101 netmask 255.255.255.0 auto eth2 iface eth2 inet manual
For compute02:
auto eth0 iface eth0 inet static address 10.254.254.102 netmask 255.255.255.0 gateway 10.254.254.1 dns-nameserver 8.8.8.8 auto eth1 iface eth1 inet static address 172.18.0.102 netmask 255.255.255.0 auto eth2 iface eth2 inet manual
Downloading the example code
You can download the example code files for all Packt books you have purchased from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.
The eth2
interface will be used in a network bridge described in further detail in Chapter 4, Building a Virtual Switching Infrastructure. To activate the changes, cycle the interfaces using the ifdown
and ifup
commands on each node:
# ifdown --all; ifup --all
For more information on configuring network interfaces, refer to the Ubuntu man page found at http://manpages.ubuntu.com/manpages/trusty/man5/interfaces.5.html.