OpenStack 实例部署失败,错误为“无法绑定端口”

OpenStack 实例部署失败,错误为“无法绑定端口”

我最近一直在努力在我们的 OpenStack 环境上部署实例。每当我尝试从 Horizo​​n 部署新实例时,我都会收到以下错误消息:

Error: Failed to perform requested operation on instance "testinstance", the instance has an error status: Please try again later [Error: Exceeded maximum number of retries. Exceeded max scheduling attempts 3 for instance d0ea4854-e2ab-4f1f-ac11-fc28b8444011. Last exception: Binding failed for port c4a851e7-7ad2-4149-92c7-6116d8965ab2, please check neutron logs for more information.].

我尝试了 ask.openstack.org 和此处提供的多种解决方案,但均无效。错误消息始终保持不变。我还多次查看文档以验证配置文件是否正确。它们是正确的。但我一直收到此错误。以下错误消息可在/var/log/neutron/neutron-server.log在控制器上:

ERROR neutron.plugins.ml2.managers [req-dd158cae-eef9-47c3-9010-ec0f8b16ae59 ee8cee6074064601bc7dc2ce3683faac 716d6d0c0224429eafbf712fc0fe580d - default default] Failed to bind port c4a851e7-7ad2-4149-92c7-6116d8965ab2 on host CoDER-N2 for vnic_type normal using segments [{'id': 'eeaf41d1-b05a-4711-9b5f-86dc0e338391', 'network_type': 'vxlan', 'physical_network': None, 'segmentation_id': 3, 'network_id': '3c92802e-0dc9-4f16-8865-7ee5cfc4d953'}]

以下是控制器上的相关配置文件:

/etc/neutron/neutron.conf

[database]
connection = mysql+pymysql:<redactedbecauseofspamfilter>

[DEFAULT]
core_plugin = ml2
service_plugins = router
allow_overlapping_ips = true

transport_url = rabbit:<redactedbecauseofspamfilter>

auth_strategy = keystone

notify_nova_on_port_status_changes = true
notify_nova_on_port_data_changes = true

[keystone_authtoken]
www_authenticate_uri = <redactedbecauseofspamfilter>
auth_url = <redactedbecauseofspamfilter>
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = neutron
password = neutron

[nova]
auth_url = <redactedbecauseofspamfilter>
auth_type = password
project_domain_name = default
user_domain_name = default
region_name = RegionOne
project_name = service
username = nova
password = nova

[oslo_concurrency]

lock_path = /var/lib/neutron/tmp

/etc/nova/nova.conf

[DEFAULT]
enabled_apis = osapi_compute,metadata
transport_url = rabbit:<redactedbecauseofspamfilter>
my_ip = 10.70.17.14

[api_database]
connection = mysql+pymysql:<redactedbecauseofspamfilter>

[database]
connection = mysql+pymysql:<redactedbecauseofspamfilter>

[api]
auth_strategy = keystone

[keystone_authtoken]
www_authenticate_uri = <redactedbecauseofspamfilter>
auth_url = <redactedbecauseofspamfilter>
memcached_servers = controller:11211
auth_type = password
project_domain_name = Default
user_domain_name = Default
project_name = service
username = nova
password = nova

[neutron]
auth_url = <redactedbecauseofspamfilter>
auth_type = password
project_domain_name = default
user_domain_name = default
region_name = RegionOne
project_name = service
username = neutron
password = neutron
service_metadata_proxy = true
metadata_proxy_shared_secret = metadata_secret

[vnc]
enabled = true
server_listen = $my_ip
server_proxyclient_address = $my_ip

[glance]
api_servers = <redactedbecauseofspamfilter>

[oslo_concurrency]
lock_path = /var/lib/nova/tmp

[placement]
region_name = RegionOne
project_domain_name = Default
project_name = service
auth_type = password
user_domain_name = Default
auth_url = http://controller:5000/v3
username = placement
password = placement

[scheduler]
discover_hosts_in_cells_interval = 300

以下是计算节点上的文件: /etc/neutron/neutron.conf

[DEFAULT]
transport_url = rabbit:<redactedbecauseofspamfilter>

auth_strategy = keystone

[keystone_authtoken]
www_authenticate_uri = <redactedbecauseofspamfilter>
auth_url = <redactedbecauseofspamfilter>
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = neutron
password = neutron


[oslo_concurrency]
lock_path = /var/lib/neutron/tmp

/etc/neutron/plugins/ml2/linuxbridge_agent.ini

[linux_bridge]
physical_interface_mappings = provider:enp4s0

[vxlan]
enable_vxlan = true
local_ip = <redactedbecauseofspamfilter>
l2_population = true

[securitygroup]
enable_security_group = true
firewall_driver = neutron.agent.linux.iptables_firewall.IptablesFirewallDriver

我还得到了/var/log/nova/nova-server.log来自此处的计算节点:

2020-11-20 08:28:12.070 332012 ERROR nova.compute.manager [instance: d0ea4854-e2ab-4f1f-ac11-fc28b8444011] nova.exception.PortBindingFailed: Binding failed for port c4a851e7-7ad2-4149-92c7-6116d8965ab2, please check neutron logs for more information.

不幸的是,计算节点上的两个 neutron-logs 都是空的。那里根本没有任何条目。所有服务都已启动并运行。我不知道出了什么问题。我怀疑控制器上的 neutron-server.log 中存在“物理网络:无”这一事实表明存在问题,但我不知道该怎么做。任何帮助都值得感激。

答案1

我也遇到过这个问题。你找到解决办法了吗?我猜问题的原因是网络配置错误。

相关内容