[docs] Add network config example for test and prod

Change-Id: Id390253a9f2e081376b3dab04d6966870bcfff7b
Closes-Bug: #1631321
This commit is contained in:
npraveen35 2016-10-12 10:25:38 +05:30 committed by Jesse Pretorius (odyssey4me)
parent 2252d17c40
commit 5686c70033
5 changed files with 228 additions and 125 deletions

View File

@ -29,7 +29,7 @@ A production environment has the following characteristics:
Network configuration
~~~~~~~~~~~~~~~~~~~~~
.. literalinclude:: ../../../etc/network/interfaces.d/openstack_interface.cfg.example
.. literalinclude:: ../../../etc/network/interfaces.d/openstack_interface.cfg.prod.example
Environment configuration
~~~~~~~~~~~~~~~~~~~~~~~~~

View File

@ -25,7 +25,7 @@ A test environment has the following characteristics:
Network configuration
~~~~~~~~~~~~~~~~~~~~~
.. TBD
.. literalinclude:: ../../../etc/network/interfaces.d/openstack_interface.cfg.test.example
Environment configuration
~~~~~~~~~~~~~~~~~~~~~~~~~

View File

@ -1,123 +0,0 @@
## The default networking requires several bridges. These bridges were named to be informative
## however they can be named what ever you like and is adaptable to any network infrastructure
## environment. This file serves as an example of how to setup basic networking and was ONLY
## built for the purpose of being an example.
# EXAMPLE INTERFACE FILE
# 1293 - HOST_NET (Ignore This. It's the native VLAN.)
# 2176 - CONTAINER_NET
# 1998 - OVERLAY_NET
# 2144 - STORAGE_NET
# 2146 - GATEWAY_NET (VM Provider Network. Ignore this. OpenStack will tag for us.)
## Physical interface, could be bond. This only needs to be set once for the physical device
auto eth0
iface eth0 inet manual
bond-master bond0
bond-primary eth0
auto eth1
iface eth1 inet manual
bond-master bond1
bond-primary eth1
auto eth2
iface eth2 inet manual
bond-master bond0
auto eth3
iface eth3 inet manual
bond-master bond1
auto eth4
iface eth4 inet manual
## Create a bonded interface. Note that the "bond-slaves" is set to none. This is because the
# bond-master has already been set in the raw interfaces for the new bond0.
auto bond0
iface bond0 inet static
bond-slaves none
bond-mode active-backup
bond-miimon 100
bond-downdelay 200
bond-updelay 200
address 10.240.0.100
netmask 255.255.252.0
gateway 10.240.0.1
dns-nameservers 69.20.0.164 69.20.0.196
auto bond1
iface bond1 inet manual
bond-slaves none
bond-mode active-backup
bond-miimon 100
bond-downdelay 250
bond-updelay 250
## Vlan tagged interface, this should be physical interface along with the vlan tag
# The vlan tag number should reflect your already setup vlans.
#STORAGE_NET
iface bond0.2144 inet manual
vlan-raw-device bond0
#CONTAINER_NET
iface bond0.2176 inet manual
vlan-raw-device bond0
#OVERLAY_NET
iface bond1.1998 inet manual
vlan-raw-device bond1
## Required network bridges; br-vlan, br-vxlan, br-mgmt.
# Bridge for management network
auto br-mgmt
iface br-mgmt inet static
bridge_stp off
bridge_waitport 0
bridge_fd 0
# Notice the bridge port is the vlan tagged interface
bridge_ports bond0.2176
address 172.29.236.100
netmask 255.255.252.0
dns-nameservers 69.20.0.164 69.20.0.196
# Bridge for vxlan network
# Only the COMPUTE nodes will have an IP on this bridge!
# When used by infra nodes, IPs exist in the containers and inet should be set to manual.
auto br-vxlan
iface br-vxlan inet static
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports bond1.1998
address 172.29.240.100
netmask 255.255.252.0
# Bridge for vlan network
auto br-vlan
iface br-vlan inet manual
bridge_stp off
bridge_waitport 0
bridge_fd 0
# Notice this bridge port is an Untagged host interface
bridge_ports bond1
# Bridge for storage network
# Only the COMPUTE and STORAGE nodes will have an IP on this bridge!
# When used by infra nodes, IPs exist in the containers and inet should be set to manual.
auto br-storage
iface br-storage inet static
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports bond0.2144
address 172.29.244.100
netmask 255.255.252.0

View File

@ -0,0 +1,132 @@
# This is a multi-NIC bonded configuration to implement the required bridges
# for OpenStack-Ansible. This illustrates the configuration of the first
# Infrastructure host and the IP addresses assigned should be adapted
# for implementation on the other hosts.
#
# After implementing this configuration, the host will need to be
# rebooted.
# Assuming that eth0/1 and eth2/3 are dual port NIC's we pair
# eth0 with eth2 and eth1 with eth3 for increased resiliency
# in the case of one interface card failing.
auto eth0
iface eth0 inet manual
bond-master bond0
bond-primary eth0
auto eth1
iface eth1 inet manual
bond-master bond1
bond-primary eth1
auto eth2
iface eth2 inet manual
bond-master bond0
auto eth3
iface eth3 inet manual
bond-master bond1
# Create a bonded interface. Note that the "bond-slaves" is set to none. This
# is because the bond-master has already been set in the raw interfaces for
# the new bond0.
auto bond0
iface bond0 inet static
bond-slaves none
bond-mode active-backup
bond-miimon 100
bond-downdelay 200
bond-updelay 200
# This bond will carry VLAN and VXLAN traffic to ensure isolation from
# control plane traffic on bond0.
auto bond1
iface bond1 inet manual
bond-slaves none
bond-mode active-backup
bond-miimon 100
bond-downdelay 250
bond-updelay 250
# Container/Host management VLAN interface
auto bond0.10
iface bond0.10 inet manual
vlan-raw-device bond0
# OpenStack Networking VXLAN (tunnel/overlay) VLAN interface
auto bond1.30
iface bond1.30 inet manual
vlan-raw-device bond1
# Storage network VLAN interface (optional)
auto bond0.20
iface bond0.20 inet manual
vlan-raw-device bond0
# Container/Host management bridge
auto br-mgmt
iface br-mgmt inet static
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports bond0.10
address 172.29.236.11
netmask 255.255.252.0
gateway 172.29.236.1
dns-nameservers 8.8.8.8 8.8.4.4
# OpenStack Networking VXLAN (tunnel/overlay) bridge
#
# Only the COMPUTE and NETWORK nodes must have an IP address
# on this bridge. When used by infrastructure nodes, the
# IP addresses are assigned to containers which use this
# bridge.
#
auto br-vxlan
iface br-vxlan inet manual
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports bond1.30
# compute1 VXLAN (tunnel/overlay) bridge config
#auto br-vxlan
#iface br-vxlan inet static
# bridge_stp off
# bridge_waitport 0
# bridge_fd 0
# bridge_ports bond1.30
# address 172.29.240.16
# netmask 255.255.252.0
# OpenStack Networking VLAN bridge
auto br-vlan
iface br-vlan inet manual
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports bond1
# Storage bridge (optional)
#
# Only the COMPUTE and STORAGE nodes must have an IP address
# on this bridge. When used by infrastructure nodes, the
# IP addresses are assigned to containers which use this
# bridge.
#
auto br-storage
iface br-storage inet manual
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports bond0.20
# compute1 Storage bridge
#auto br-storage
#iface br-storage inet static
# bridge_stp off
# bridge_waitport 0
# bridge_fd 0
# bridge_ports bond0.20
# address 172.29.244.16
# netmask 255.255.252.0

View File

@ -0,0 +1,94 @@
# This is a single-NIC configuration to implement the required bridges
# for OpenStack-Ansible. This illustrates the configuration of the first
# Infrastructure host and the IP addresses assigned should be adapted
# for implementation on the other hosts.
#
# After implementing this configuration, the host will need to be
# rebooted.
# Physical interface
auto eth0
iface eth0 inet manual
# Container/Host management VLAN interface
auto eth0.10
iface eth0.10 inet manual
vlan-raw-device eth0
# OpenStack Networking VXLAN (tunnel/overlay) VLAN interface
auto eth0.30
iface eth0.30 inet manual
vlan-raw-device eth0
# Storage network VLAN interface (optional)
auto eth0.20
iface eth0.20 inet manual
vlan-raw-device eth0
# Container/Host management bridge
auto br-mgmt
iface br-mgmt inet static
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports eth0.10
address 172.29.236.11
netmask 255.255.252.0
gateway 172.29.236.1
dns-nameservers 8.8.8.8 8.8.4.4
# OpenStack Networking VXLAN (tunnel/overlay) bridge
#
# Only the COMPUTE and NETWORK nodes must have an IP address
# on this bridge. When used by infrastructure nodes, the
# IP addresses are assigned to containers which use this
# bridge.
#
auto br-vxlan
iface br-vxlan inet manual
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports eth0.30
# compute1 VXLAN (tunnel/overlay) bridge config
#auto br-vxlan
#iface br-vxlan inet static
# bridge_stp off
# bridge_waitport 0
# bridge_fd 0
# bridge_ports eth0.30
# address 172.29.240.12
# netmask 255.255.252.0
# OpenStack Networking VLAN bridge
auto br-vlan
iface br-vlan inet manual
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports none
# Storage bridge (optional)
#
# Only the COMPUTE and STORAGE nodes must have an IP address
# on this bridge. When used by infrastructure nodes, the
# IP addresses are assigned to containers which use this
# bridge.
#
auto br-storage
iface br-storage inet manual
bridge_stp off
bridge_waitport 0
bridge_fd 0
bridge_ports eth0.20
# compute1 Storage bridge
#auto br-storage
#iface br-storage inet static
# bridge_stp off
# bridge_waitport 0
# bridge_fd 0
# bridge_ports eth0.20
# address 172.29.244.12
# netmask 255.255.252.0