通过在 OpenStack 中创建实例,IP 被注入到实例中,而不是像主机名和密钥对中的其他元数据。nova 和 neutron 日志文件中没有错误。
问题:
...
checking http://169.254.169.254/2009-04-04/instance-id
failed 1/20: up 5.45. request failed
failed 2/20: up 7.47. request failed
...
failed 19/20: up 746.84. request failed
failed 20/20: up 795.86. request failed
failed to read iid from metadata. tried 20
failed to get instance-id of datasource
Top of dropbear init script
Starting dropbear sshd: failed to get instance-id of datasource
OK
...
上面的代码片段是 Cirros 实例创建日志的一部分。(创建过程的完整日志在这里发布)
日志中的另一个错误是这一行:
acpi PNP0A03:00: fail to add MMCONFIG information, can't access extended PCI configuration space under this bridge
。这与问题有关吗?
一些配置文件:
# /etc/neutron/dhcp_agent.ini
[DEFAULT]
interface_driver = openvswitch
dhcp_driver = neutron.agent.linux.dhcp.Dnsmasq
enable_isolated_metadata = true
force_metadata = true
#/etc/neutron/plugins/ml2/ml2_conf.ini
[ml2]
type_drivers = vxlan,vlan,flat
tenant_network_types = vxlan
mechanism_drivers = openvswitch,l2population
extension_drivers = port_security
[ml2_type_flat]
flat_networks = provider
[ml2_type_vxlan]
vni_ranges = 1:1000
#/etc/neutron/plugins/ml2/openvswitch_agent.ini
[agent]
tunnel_types = vxlan
l2_population = True
[dhcp]
[network_log]
[ovs]
local_ip = 10.0.0.1
bridge_mappings = provider:br-provider
[securitygroup]
firewall_driver = iptables_hybrid
计算节点配置:https ://p.teknik.io/Ck1Ae
以下是来自cloud-init.log
实例的错误:
ip netns exec qdhcp-3b5bbc53-7638-4480-9349-407944933413 ip a
77: tap588fefad-6c: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc noqueue state UNKNOWN group default qlen 1000
link/ether fa:16:3e:df:33:e1 brd ff:ff:ff:ff:ff:ff
inet 169.254.169.254/32 brd 169.254.169.254 scope global tap588fefad-6c
valid_lft forever preferred_lft forever
inet 10.0.1.1/24 brd 10.0.1.255 scope global tap588fefad-6c
valid_lft forever preferred_lft forever
inet6 fe80::f816:3eff:fedf:33e1/64 scope link
valid_lft forever preferred_lft forever
自创建实例以来,
- neutron-metadata-agent.log:空!
- 中子服务器日志:http: //sprunge.us/a27LHT
- nova-compute.log:http ://sprunge.us/sl8eu7
+ 我已按照此说明通过 OVS 实施自助服务网络。
将元数据注入实例的一种方法是配置驱动器。如果使用命令行,它可以作为选项添加到
openstack server create
命令中:您还可以强制 nova 始终使用配置驱动器,为此将这一行添加到
/etc/nova/nova.conf
:Nova 将一个虚拟驱动器附加到它存储元数据的实例,该驱动器由 cloud-init 挂载并应用所需的配置参数。在您的情况下,元数据服务似乎无法正常工作,我在您的输出中没有看到 metadata_agent.ini 部分,您是否配置了它?您可以在安装指南中找到更多详细信息。