尝试基于 trusty:kilo charms 设置 3 节点 openstack Kilo。在一个节点上,控制器,将以下内容添加为 LXC:
glance heat juju-gui keystone mongodb mysql openstack-dashboard cinder nova-cloud-controller rabiitmq-server ceilometer
在网络节点上添加了量子网关和中子 API 作为 LXC。(并使用单个节点作为计算节点。)问题是,在访问“访问和安全”选项卡或创建实例时,我在仪表板上收到“错误:无法检索安全组”消息。以下是实例创建期间 /var/log/nova/nova-api-os-compute.log 的摘录
2015-05-25 19:22:58.952 1077 ERROR nova.network.security_group.neutron_driver [req-8a6c2a46-7e17-4312-b72b-122b2e52f93a 74ff6546fe7c4ed9b2c33e1197139e07 becc45b8e31c49908241385888171754 - - -] Neutron Error getting security groups
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver Traceback (most recent call last):
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/nova/network/security_group/neutron_driver.py", line 161, in list
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver security_groups = neutron.list_security_groups(**search_opts).get(
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 99, in with_params
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver ret = self.function(instance, *args, **kwargs)
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 665, in list_security_groups
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver retrieve_all, **_params)
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 304, in list
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver for r in self._pagination(collection, path, **params):
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 317, in _pagination
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver res = self.get(path, params=params)
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 290, in get
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver headers=headers, params=params)
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 267, in retry_request
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver headers=headers, params=params)
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 208, in do_request
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver self._handle_fault_response(status_code, replybody)
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 182, in _handle_fault_response
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver exception_handler_v20(status_code, des_error_body)
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 80, in exception_handler_v20
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver message=message)
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver NeutronClientException: 404 Not Found
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver The resource could not be found.
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver
2015-05-25 19:22:58.952 1077 TRACE nova.network.security_group.neutron_driver
2015-05-25 19:22:58.955 1077 ERROR nova.api.openstack [req-8a6c2a46-7e17-4312-b72b-122b2e52f93a 74ff6546fe7c4ed9b2c33e1197139e07 becc45b8e31c49908241385888171754 - - -] Caught error: 404 Not Found
The resource could not be found.
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack Traceback (most recent call last):
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/__init__.py", line 125, in __call__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack return req.get_response(self.application)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1320, in send
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack application, catch_exc_info=False)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1284, in call_application
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack app_iter = application(self.environ, start_response)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack return resp(environ, start_response)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/keystonemiddleware/auth_token/__init__.py", line 634, in __call__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack return self._call_app(env, start_response)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/keystonemiddleware/auth_token/__init__.py", line 554, in _call_app
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack return self._app(env, _fake_start_response)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack return resp(environ, start_response)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack return resp(environ, start_response)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/routes/middleware.py", line 131, in __call__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack response = self.app(environ, start_response)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack return resp(environ, start_response)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 130, in __call__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack resp = self.call_func(req, *args, **self.kwargs)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 195, in call_func
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack return self.func(req, *args, **kwargs)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/wsgi.py", line 756, in __call__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack content_type, body, accept)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/wsgi.py", line 821, in _process_stack
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack action_result = self.dispatch(meth, request, action_args)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/wsgi.py", line 911, in dispatch
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack return method(req=request, **action_args)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/compute/contrib/security_groups.py", line 180, in index
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack search_opts=search_opts)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/network/security_group/neutron_driver.py", line 165, in list
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack LOG.exception(_LE("Neutron Error getting security groups"))
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/oslo_utils/excutils.py", line 85, in __exit__
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack six.reraise(self.type_, self.value, self.tb)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/network/security_group/neutron_driver.py", line 161, in list
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack security_groups = neutron.list_security_groups(**search_opts).get(
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 99, in with_params
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack ret = self.function(instance, *args, **kwargs)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 665, in list_security_groups
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack retrieve_all, **_params)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 304, in list
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack for r in self._pagination(collection, path, **params):
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 317, in _pagination
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack res = self.get(path, params=params)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 290, in get
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack headers=headers, params=params)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 267, in retry_request
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack headers=headers, params=params)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 208, in do_request
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack self._handle_fault_response(status_code, replybody)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 182, in _handle_fault_response
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack exception_handler_v20(status_code, des_error_body)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 80, in exception_handler_v20
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack message=message)
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack NeutronClientException: 404 Not Found
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack The resource could not be found.
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack
2015-05-25 19:22:58.955 1077 TRACE nova.api.openstack
问题是,虽然创建了实例,但是无法访问元服务器。以下是创建日志:
Sending discover...
Sending select for 192.168.100.3...
Lease of 192.168.100.3 obtained, lease time 86400
cirros-ds 'net' up at 1.13
checking http://169.254.169.254/2009-04-04/instance-id
failed 1/20: up 1.13. request failed
failed 2/20: up 6.22. request failed
failed 3/20: up 9.22. request failed
有什么想法吗?
干杯,
答案1
确保在 neutron-api charm 中,“neutron-security-groups”设置为 True。