[Openstack/Devstack] Cannot reach Internet via Floating IP
by czezz from LinuxQuestions.org on (#548J1)
Hi all,
This is my devstack lab installed on VirtualBox.
Code:stack@vlab:~$ cat /etc/devstack-version
DevStack Version: stein
Change: 669b0c5e4eba1a721dc02650e000fb0ac6bfd11b Merge "Remove crusty old python 3 package version logic" into stable/stein 2019-04-26 09:32:45 +0000
OS Version: Ubuntu 16.04 xenialI have created instance (vm: heat_server), with floating IP/port hoping it will have access to internet.
Code:stack@vlab:~$ openstack server list
+--------------------------------------+-------------+---------+------------------------------------+--------------------------+---------+
| ID | Name | Status | Networks | Image | Flavor |
+--------------------------------------+-------------+---------+------------------------------------+--------------------------+---------+
| 6f8fbc70-dfc5-4840-ba18-cf7869863af6 | heat_server | ACTIVE | heat_network=10.1.1.4, 172.24.4.10 | cirros-0.4.0-x86_64-disk | m1.tiny |
| 0eb31f9d-4524-4382-9868-6bb1df1d84fd | testvm2 | SHUTOFF | fxnet=10.2.0.5 | cirros-0.4.0-x86_64-disk | m1.tiny |
| 4766f91f-b1ec-44f6-96c4-6d1164ba754e | testvm1 | SHUTOFF | fxnet=10.2.0.11 | cirros-0.4.0-x86_64-disk | m1.tiny |
+--------------------------------------+-------------+---------+------------------------------------+--------------------------+---------+Unfortunately it does not reach Internet.
I did a small investigation:
1. I checked for network "public" - OK
2. I checked for subnet "public-subnet" - OK
3. I checked for router "public" and I see - NONE
Questions:
1. Could that be a reason of not reaching internet from my instance (missing public router)?
2. Is this true that connectivity to internet via Floating IP is in fact NATed by Neutron via internal network (in my case 10.1.1.x) ?
Code:openstack floating ip list
+--------------------------------------+---------------------+------------------+--------------------------------------+--------------------------------------+----------------------------------+
| ID | Floating IP Address | Fixed IP Address | Port | Floating Network | Project |
+--------------------------------------+---------------------+------------------+--------------------------------------+--------------------------------------+----------------------------------+
| 54cd81a9-771c-475f-94db-d69fe92bc512 | 172.24.4.10 | 10.1.1.4 | e6681d9c-8456-4cf6-ae07-71abce21a823 | e0ef1d2b-1d8e-42e0-9b3a-ecbe784f24e1 | a5e6e3dbad9f4f4b8810fe0a1246e1f7 |
+--------------------------------------+---------------------+------------------+--------------------------------------+--------------------------------------+----------------------------------+
Listings:
stack@vlab:~$ openstack network show public
+---------------------------+----------------------------------------------------------------------------+
| Field | Value |
+---------------------------+----------------------------------------------------------------------------+
| admin_state_up | UP |
| availability_zone_hints | |
| availability_zones | nova |
| created_at | 2019-05-07T13:47:00Z |
| description | |
| dns_domain | None |
| id | e0ef1d2b-1d8e-42e0-9b3a-ecbe784f24e1 |
| ipv4_address_scope | None |
| ipv6_address_scope | None |
| is_default | True |
| is_vlan_transparent | None |
| location | None |
| mtu | 1500 |
| name | public |
| port_security_enabled | True |
| project_id | 7e31368f4f9a4b31a91257394592fef2 |
| provider:network_type | flat |
| provider:physical_network | public |
| provider:segmentation_id | None |
| qos_policy_id | None |
| revision_number | 3 |
| router:external | External |
| segments | None |
| shared | False |
| status | ACTIVE |
| subnets | 51bd9836-acf8-4369-8f4c-8466307694a7, fec1ef4c-d70d-43d8-8c6e-8ea03325f52f |
| tags | |
| updated_at | 2019-05-07T13:47:52Z |
+---------------------------+----------------------------------------------------------------------------+
stack@vlab:~$ openstack subnet show public-subnet
+-------------------+--------------------------------------+
| Field | Value |
+-------------------+--------------------------------------+
| allocation_pools | 172.24.4.2-172.24.4.254 |
| cidr | 172.24.4.0/24 |
| created_at | 2019-05-07T13:47:14Z |
| description | |
| dns_nameservers | |
| enable_dhcp | False |
| gateway_ip | 172.24.4.1 |
| host_routes | |
| id | fec1ef4c-d70d-43d8-8c6e-8ea03325f52f |
| ip_version | 4 |
| ipv6_address_mode | None |
| ipv6_ra_mode | None |
| location | None |
| name | public-subnet |
| network_id | e0ef1d2b-1d8e-42e0-9b3a-ecbe784f24e1 |
| project_id | 7e31368f4f9a4b31a91257394592fef2 |
| revision_number | 0 |
| segment_id | None |
| service_types | |
| subnetpool_id | None |
| tags | |
| updated_at | 2019-05-07T13:47:14Z |
+-------------------+--------------------------------------+
stack@vlab:~$ openstack router list
+--------------------------------------+-------------+--------+-------+-------------+-------+----------------------------------+
| ID | Name | Status | State | Distributed | HA | Project |
+--------------------------------------+-------------+--------+-------+-------------+-------+----------------------------------+
| 1bb436b3-fe08-4b38-8542-30587a87bc40 | heat_router | ACTIVE | UP | False | False | a5e6e3dbad9f4f4b8810fe0a1246e1f7 |
| a71b95db-d12e-46de-85b5-14d4368186be | router1 | ACTIVE | UP | False | False | a5e6e3dbad9f4f4b8810fe0a1246e1f7 |
| beba3591-e0f2-4f03-a70a-b2022c9aca01 | fxrouter | ACTIVE | UP | False | False | a5e6e3dbad9f4f4b8810fe0a1246e1f7 |
+--------------------------------------+-------------+--------+-------+-------------+-------+----------------------------------+


This is my devstack lab installed on VirtualBox.
Code:stack@vlab:~$ cat /etc/devstack-version
DevStack Version: stein
Change: 669b0c5e4eba1a721dc02650e000fb0ac6bfd11b Merge "Remove crusty old python 3 package version logic" into stable/stein 2019-04-26 09:32:45 +0000
OS Version: Ubuntu 16.04 xenialI have created instance (vm: heat_server), with floating IP/port hoping it will have access to internet.
Code:stack@vlab:~$ openstack server list
+--------------------------------------+-------------+---------+------------------------------------+--------------------------+---------+
| ID | Name | Status | Networks | Image | Flavor |
+--------------------------------------+-------------+---------+------------------------------------+--------------------------+---------+
| 6f8fbc70-dfc5-4840-ba18-cf7869863af6 | heat_server | ACTIVE | heat_network=10.1.1.4, 172.24.4.10 | cirros-0.4.0-x86_64-disk | m1.tiny |
| 0eb31f9d-4524-4382-9868-6bb1df1d84fd | testvm2 | SHUTOFF | fxnet=10.2.0.5 | cirros-0.4.0-x86_64-disk | m1.tiny |
| 4766f91f-b1ec-44f6-96c4-6d1164ba754e | testvm1 | SHUTOFF | fxnet=10.2.0.11 | cirros-0.4.0-x86_64-disk | m1.tiny |
+--------------------------------------+-------------+---------+------------------------------------+--------------------------+---------+Unfortunately it does not reach Internet.
I did a small investigation:
1. I checked for network "public" - OK
2. I checked for subnet "public-subnet" - OK
3. I checked for router "public" and I see - NONE
Questions:
1. Could that be a reason of not reaching internet from my instance (missing public router)?
2. Is this true that connectivity to internet via Floating IP is in fact NATed by Neutron via internal network (in my case 10.1.1.x) ?
Code:openstack floating ip list
+--------------------------------------+---------------------+------------------+--------------------------------------+--------------------------------------+----------------------------------+
| ID | Floating IP Address | Fixed IP Address | Port | Floating Network | Project |
+--------------------------------------+---------------------+------------------+--------------------------------------+--------------------------------------+----------------------------------+
| 54cd81a9-771c-475f-94db-d69fe92bc512 | 172.24.4.10 | 10.1.1.4 | e6681d9c-8456-4cf6-ae07-71abce21a823 | e0ef1d2b-1d8e-42e0-9b3a-ecbe784f24e1 | a5e6e3dbad9f4f4b8810fe0a1246e1f7 |
+--------------------------------------+---------------------+------------------+--------------------------------------+--------------------------------------+----------------------------------+
Listings:
stack@vlab:~$ openstack network show public
+---------------------------+----------------------------------------------------------------------------+
| Field | Value |
+---------------------------+----------------------------------------------------------------------------+
| admin_state_up | UP |
| availability_zone_hints | |
| availability_zones | nova |
| created_at | 2019-05-07T13:47:00Z |
| description | |
| dns_domain | None |
| id | e0ef1d2b-1d8e-42e0-9b3a-ecbe784f24e1 |
| ipv4_address_scope | None |
| ipv6_address_scope | None |
| is_default | True |
| is_vlan_transparent | None |
| location | None |
| mtu | 1500 |
| name | public |
| port_security_enabled | True |
| project_id | 7e31368f4f9a4b31a91257394592fef2 |
| provider:network_type | flat |
| provider:physical_network | public |
| provider:segmentation_id | None |
| qos_policy_id | None |
| revision_number | 3 |
| router:external | External |
| segments | None |
| shared | False |
| status | ACTIVE |
| subnets | 51bd9836-acf8-4369-8f4c-8466307694a7, fec1ef4c-d70d-43d8-8c6e-8ea03325f52f |
| tags | |
| updated_at | 2019-05-07T13:47:52Z |
+---------------------------+----------------------------------------------------------------------------+
stack@vlab:~$ openstack subnet show public-subnet
+-------------------+--------------------------------------+
| Field | Value |
+-------------------+--------------------------------------+
| allocation_pools | 172.24.4.2-172.24.4.254 |
| cidr | 172.24.4.0/24 |
| created_at | 2019-05-07T13:47:14Z |
| description | |
| dns_nameservers | |
| enable_dhcp | False |
| gateway_ip | 172.24.4.1 |
| host_routes | |
| id | fec1ef4c-d70d-43d8-8c6e-8ea03325f52f |
| ip_version | 4 |
| ipv6_address_mode | None |
| ipv6_ra_mode | None |
| location | None |
| name | public-subnet |
| network_id | e0ef1d2b-1d8e-42e0-9b3a-ecbe784f24e1 |
| project_id | 7e31368f4f9a4b31a91257394592fef2 |
| revision_number | 0 |
| segment_id | None |
| service_types | |
| subnetpool_id | None |
| tags | |
| updated_at | 2019-05-07T13:47:14Z |
+-------------------+--------------------------------------+
stack@vlab:~$ openstack router list
+--------------------------------------+-------------+--------+-------+-------------+-------+----------------------------------+
| ID | Name | Status | State | Distributed | HA | Project |
+--------------------------------------+-------------+--------+-------+-------------+-------+----------------------------------+
| 1bb436b3-fe08-4b38-8542-30587a87bc40 | heat_router | ACTIVE | UP | False | False | a5e6e3dbad9f4f4b8810fe0a1246e1f7 |
| a71b95db-d12e-46de-85b5-14d4368186be | router1 | ACTIVE | UP | False | False | a5e6e3dbad9f4f4b8810fe0a1246e1f7 |
| beba3591-e0f2-4f03-a70a-b2022c9aca01 | fxrouter | ACTIVE | UP | False | False | a5e6e3dbad9f4f4b8810fe0a1246e1f7 |
+--------------------------------------+-------------+--------+-------+-------------+-------+----------------------------------+