how to setup provider network openstack
Hi all,
I am new to openstack and trying to deploy a 2 nodes openstack queens architecture. The document, I'm following https://docs.openstack.org/install-guide/environment-networking.html (https://docs.openstack.org/install-gu...).
My current setup consists of 2 VMs running Ubuntu 16.04 each with 3 NICS ens160, ens192 adn ens224.
I configured static IP addresses for ens160 NICs on both VM and this is the management interface
** Controller: ens160 - CIDR: 10.204.16.150/24 and gateway: 10.204.16.1
** Compute: ens160 - CIDR: 10.204.16.151/24 and gateway: 10.204.16.1
The default gateway provides internet access for the VMs to install packages. My /etc/network/interfaces on controller node:
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
source /etc/network/interfaces.d/*
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
auto ens160
iface ens160 inet static
address 10.204.16.150
netmask 255.255.255.0
network 10.204.16.0
broadcast 10.204.16.255
gateway 10.204.16.1
# dns-* options are implemented by the resolvconf package, if installed
dns-nameservers 8.8.8.8 8.8.4.4
auto ens192
iface ens192 inet manual
up ip link set dev $IFACE up
down ip link set dev $IFACE down
Now, I am trying to setup a "provider network" for Openstack so that VM instances within the Openstack Cloud can have internet access. I am using the ens192 NIC to achieve this:
My understanding is that, the provider network should be mapped to a different subnet to the management network. Hence, I intend to configure the provider network as followed:
** Provider network: CIDR: 10.204.36.0/24,
Pool: 10.204.36.100 -> 10.204.36.120
Default Gateway: 10.204.36.1
DNS: 8.8.8.8
Now if I want openstack instances to have internet access I need to configure the default gateway for this provider network which is 10.204.36.1. But the problem is I can only have 1 default gateway configure across all network cards (at least this is what I read).
QUESTIONS:
1.Does this mean I need to remove the default gateway from the first NIC ens160?
2.If so will the openstack nodes still have internet access from the "provider network"?
Thanks in advance, your time is much appreciated. j
Update:
So I ended up create the flat provider network through the dashboard.
Name provider
ID bb73e844-e6b3-41d5-a00d-442269362500
Network Name provider
Network ID 05ae4d05-9ae1-42e3-8435-118b24391a35
Subnet Pool None
IP Version IPv4
CIDR 10.204.36.0/24
IP Allocation Pools Start 10.204.36.100 - End 10.204.36.120
Gateway IP 10.204.36.1
DHCP Enabled Yes
Additional Routes None
DNS Name Servers 8.8.8.8
AND then create a Virtual Router connecting 2 openstack private_networks to the provider network. "neutron router-port-list Router" gave output:
+--------------------------------------+------+----------------------------------+-------------------+--------------------------------------------------------------------------------------+
| id | name | tenant_id | mac_address | fixed_ips |
+--------------------------------------+------+----------------------------------+-------------------+--------------------------------------------------------------------------------------+
| 4d4b36e5-1cde-472c-b25b-f73e71cef823 | | acfbef4dcfc742d0bed99c2a448a2b98 | fa ...