[Starlingx-discuss] 回复: 回复:回复: openstack network creation failure: Flat provider networks are disabled

钱江 qianjiang at baicells.com
Mon Nov 4 09:21:59 UTC 2019


       Ezpeer,

       Thanks for your support such a long time.
       This morning, when I retry creating network just as what I did before, It works. Yes, It works!!! 
       But I completely have no idea what I modified, even I suspect I changed nothing but it goes well now.
       I can not reproduce this issue, I just decided continue my starlingx trip. 
       Anyway, thanks a lot.

       Best Regard 


------------------------------------------------------------------
发件人:Ezpeer Chen <ezpeerchen at gmail.com>
发送时间:2019年11月4日(星期一) 16:15
收件人:钱江 <qianjiang at baicells.com>
抄 送:starlingx-discuss <starlingx-discuss at lists.starlingx.io>
主 题:Re: [Starlingx-discuss] 回复:回复: openstack network creation failure: Flat provider networks are disabled

Dear Qianjiang, 

system host-lock ${COMPUTE} 

#If the interface has been bound to other datanetwork, need to remove the binding.
system interface-datanetwork-list ${COMPUTE}
system interface-datanetwork-remove ${PHYSNETDATA0UUID}

#Create a flat datanetwork and bind it to the interface.
system datanetwork-add phy-flat flat 
system host-if-modify -m 1500 -n data0 -c data ${COMPUTE} ${DATA0IFUUID} 
system interface-datanetwork-assign ${COMPUTE} ${DATA0IFUUID} phy-flat 
system host-unlock ${COMPUTE}
My Example:

[sysadmin at controller-0 ~(keystone_admin)]$ system host-if-list controller-0
+--------------------------------------+-----------+-----------------+----------+------+----------------+------+------+-----------------------+
| uuid                                 | name      | class           | type     | vlan | ports          | uses | used | attributes            |
|                                      |           |                 |          | id   |                | i/f  | by   |                       |
|                                      |           |                 |          |      |                |      | i/f  |                       |
+--------------------------------------+-----------+-----------------+----------+------+----------------+------+------+-----------------------+
| 5e6ab3c1-ff01-4ca9-b8c3-98984c9ab403 | lo        | platform        | virtual  | None | []             | []   | []   | MTU=1500              |
| a68ceee4-77d7-4ec1-a5f1-bf667b7fa7f7 | enp2s0    | platform        | ethernet | None | [u'enp2s0']    | []   | []   | MTU=1500              |
| e0b545f0-dc0d-4c6c-9327-0008191cf3e6 | enp3s0    | data            | ethernet | None | [u'enp3s0']    | []   | []   | MTU=1500,accelerated= |
|                                      |           |                 |          |      |                |      |      | True                  |
|                                      |           |                 |          |      |                |      |      |                       |
| fe0be665-6e66-4113-99b3-164374e40b17 | enp98s0f1 | pci-passthrough | ethernet | None | [u'enp98s0f1'] | []   | []   | MTU=1500              |
| ffb39ada-ef0a-4a19-87df-9998c5a23e11 | enp98s0f0 | pci-sriov       | ethernet | None | [u'enp98s0f0'] | []   | []   | MTU=1500              |
+--------------------------------------+-----------+-----------------+----------+------+----------------+------+------+-----------------------+
[sysadmin at controller-0 ~(keystone_admin)]$


[sysadmin at controller-0 ~(keystone_admin)]$ system datanetwork-list
+--------------------------------------+---------------+--------------+------+
| uuid                                 | name          | network_type | mtu  |
+--------------------------------------+---------------+--------------+------+
| b42f45d1-a474-47cc-b603-8c3b4e50189b | phy-flat      | flat         | 1500 |
| a772f2ee-4f45-4593-9aa2-e9d007b3ebb0 | physnet-pci   | flat         | 1500 |
| 322d1ff6-7446-48b3-810f-47cdde3d8b4a | physnet-sriov | flat         | 1500 |
+--------------------------------------+---------------+--------------+------+

[sysadmin at controller-0 ~(keystone_admin)]$ system interface-datanetwork-list controller-0
+--------------+--------------------------------------+-----------+------------------+
| hostname     | uuid                                 | ifname    | datanetwork_name |
+--------------+--------------------------------------+-----------+------------------+
| controller-0 | 13e47f32-e9a4-4a33-9bc0-63c96e32bfb0 | enp98s0f1 | physnet-pci      |
| controller-0 | 6be1d6c2-01c2-45de-a319-4a6337375f7b | enp3s0    | phy-flat         |
| controller-0 | f4d817b4-97ca-40e2-a1df-7ef8d0640937 | enp98s0f0 | physnet-sriov    |
+--------------+--------------------------------------+-----------+------------------+

=============================================================================


controller-0:~$ export OS_CLOUD=openstack_helm
controller-0:~$ ADMINID=`openstack project list | grep admin | awk '{print $2}'`
controller-0:~$ openstack network create --project ${ADMINID} --provider-network-type=flat --provider-physical-network=phy-flat netflat
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Field                     | Value                                                                                                                                                                                                     |
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| admin_state_up            | UP                                                                                                                                                                                                        |
| availability_zone_hints   |                                                                                                                                                                                                           |
| availability_zones        |                                                                                                                                                                                                           |
| created_at                | 2019-11-04T03:22:36Z                                                                                                                                                                                      |
| description               |                                                                                                                                                                                                           |
| dns_domain                | None                                                                                                                                                                                                      |
| id                        | 4916450b-f018-4065-ac7a-bfd1475afe17                                                                                                                                                                      |
| ipv4_address_scope        | None                                                                                                                                                                                                      |
| ipv6_address_scope        | None                                                                                                                                                                                                      |
| is_default                | False                                                                                                                                                                                                     |
| is_vlan_transparent       | False                                                                                                                                                                                                     |
| location                  | Munch({'project': Munch({'domain_name': 'default', 'domain_id': None, 'name': 'admin', 'id': u'9be757c8e5464416b41cd1bcdaca990e'}), 'cloud': 'openstack_helm', 'region_name': 'RegionOne', 'zone': None}) |
| mtu                       | 1500                                                                                                                                                                                                      |
| name                      | netflat                                                                                                                                                                                                   |
| port_security_enabled     | True                                                                                                                                                                                                      |
| project_id                | 9be757c8e5464416b41cd1bcdaca990e                                                                                                                                                                          |
| provider:network_type     | flat                                                                                                                                                                                                      |
| provider:physical_network | phy-flat                                                                                                                                                                                                  |
| provider:segmentation_id  | None                                                                                                                                                                                                      |
| qos_policy_id             | None                                                                                                                                                                                                      |
| revision_number           | 1                                                                                                                                                                                                         |
| router:external           | Internal                                                                                                                                                                                                  |
| segments                  | None                                                                                                                                                                                                      |
| shared                    | False                                                                                                                                                                                                     |
| status                    | ACTIVE                                                                                                                                                                                                    |
| subnets                   |                                                                                                                                                                                                           |
| tags                      |                                                                                                                                                                                                           |
| updated_at                | 2019-11-04T03:22:36Z                                                                                                                                                                                      |
+---------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
controller-0:~$






-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.starlingx.io/pipermail/starlingx-discuss/attachments/20191104/eccca3f8/attachment-0001.html>


More information about the Starlingx-discuss mailing list