分享

centos7搭建L版本,实例创建问题

shenadam 发表于 2016-1-17 22:32:49 [显示全部楼层] 回帖奖励 阅读模式 关闭右栏 7 56673
centos7.1安装openstack L版本,参照官网RDO方式一步一步搭建,未遇见过程中问题。但是最后新建立实例时确报如下:请问有参照官网上部署成功的吗?是如何解决这类问题的?谢谢!



[root@controller ~]#  nova boot --flavor m1.tiny --image cirros --nic net-id=a0bde269-d320-4853-9045-e2e90ba14031 \
>   --security-group default --key-name mykey public-instance
ERROR (ClientException): Unexpected API Error. Please report this at http://bugs.launchpad.net/nova/ and attach the Nova API log if possible.
<class 'keystoneclient.exceptions.BadRequest'> (HTTP 500) (Request-ID: req-c0467d40-2fff-42b4-915a-d5ff3f1a7ff0)
[root@controller ~]#  nova list
+----+------+--------+------------+-------------+----------+
| ID | Name | Status | Task State | Power State | Networks |
+----+------+--------+------------+-------------+----------+
+----+------+--------+------------+-------------+----------+


[root@controller nova]# tail -f nova-api.log
2016-01-17 21:33:02.244 62036 ERROR nova.api.openstack.extensions     return self.request(url, 'POST', **kwargs)
2016-01-17 21:33:02.244 62036 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/keystoneclient/utils.py", line 337, in inner
2016-01-17 21:33:02.244 62036 ERROR nova.api.openstack.extensions     return func(*args, **kwargs)
2016-01-17 21:33:02.244 62036 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 401, in request
2016-01-17 21:33:02.244 62036 ERROR nova.api.openstack.extensions     raise exceptions.from_response(resp, method, url)
2016-01-17 21:33:02.244 62036 ERROR nova.api.openstack.extensions BadRequest: Expecting to find username or userId in passwordCredentials - the server could not comply with the request since it is either malformed or otherwise incorrect. The client is assumed to be in error. (HTTP 400) (Request-ID: req-64775b3f-189b-402d-81c1-c2a0ab142bbc)
2016-01-17 21:33:02.244 62036 ERROR nova.api.openstack.extensions
2016-01-17 21:33:02.245 62036 INFO nova.api.openstack.wsgi [req-c0467d40-2fff-42b4-915a-d5ff3f1a7ff0 8068f6d77937442fbf6cf5f38ef4e590 a57f6656f9b544fbb449996a6069bda2 - - -] HTTP exception thrown: Unexpected API Error. Please report this at http://bugs.launchpad.net/nova/ and attach the Nova API log if possible.
<class 'keystoneclient.exceptions.BadRequest'>


已有(7)人评论

跳转到指定楼层
Alkaloid0515 发表于 2016-1-18 11:33:18
跟这个有点像,楼主检测下组件是否正常
求援助:创建实例时报错,急!!!
http://www.aboutyun.com/thread-16049-1-1.html



回复

使用道具 举报

shenadam 发表于 2016-1-18 13:24:26
Alkaloid0515 发表于 2016-1-18 11:33
跟这个有点像,楼主检测下组件是否正常
求援助:创建实例时报错,急!!!
http://www.aboutyun.com/thre ...

这个帖子之前也看到了,检查keystone组件及其它组件都未发现异常。   现在真不知从哪方面着手了
回复

使用道具 举报

Alkaloid0515 发表于 2016-1-18 13:55:40
shenadam 发表于 2016-1-18 13:24
这个帖子之前也看到了,检查keystone组件及其它组件都未发现异常。   现在真不知从哪方面着手了

计算节点和服务节点的各个组件的服务都检测下。截图上传下,然后看下两个节点的日志
回复

使用道具 举报

shenadam 发表于 2016-1-18 14:59:20
Alkaloid0515 发表于 2016-1-18 13:55
计算节点和服务节点的各个组件的服务都检测下。截图上传下,然后看下两个节点的日志

谢谢您,日志有点多,请帮忙分析分析。

computer节点没见到日志报错,如下是在controller节点上的。

[root@controller ~]# openstack-status
== Nova services ==
openstack-nova-api:                     active
openstack-nova-cert:                    active
openstack-nova-compute:                 inactive  (disabled on boot)
openstack-nova-network:                 inactive  (disabled on boot)
openstack-nova-scheduler:               active
openstack-nova-conductor:               active
== Glance services ==
openstack-glance-api:                   active
openstack-glance-registry:              active
== Keystone service ==
openstack-keystone:                     inactive  (disabled on boot)
== Horizon service ==
openstack-dashboard:                    active
== neutron services ==
neutron-server:                         active
neutron-dhcp-agent:                     active
neutron-l3-agent:                       failed
neutron-metadata-agent:                 active
neutron-linuxbridge-agent:              active
== Support services ==
mysqld:                                 inactive  (disabled on boot)
dbus:                                   active
rabbitmq-server:                        active    (disabled on boot)
memcached:                              active
== Keystone users ==
/usr/lib/python2.7/site-packages/keystoneclient/shell.py:64: DeprecationWarning: The keystone CLI is deprecated in favor of python-openstackclient. For a Python library, continue using python-keystoneclient.
  'python-keystoneclient.', DeprecationWarning)
WARNING: unsupported identity-api-version 3, falling back to 2.0
/usr/lib/python2.7/site-packages/keystoneclient/v2_0/client.py:145: DeprecationWarning: Constructing an instance of the keystoneclient.v2_0.client.Client class without a session is deprecated as of the 1.7.0 release and may be removed in the 2.0.0 release.
  'the 2.0.0 release.', DeprecationWarning)
/usr/lib/python2.7/site-packages/keystoneclient/v2_0/client.py:147: DeprecationWarning: Using the 'tenant_name' argument is deprecated in version '1.7.0' and will be removed in version '2.0.0', please use the 'project_name' argument instead
  super(Client, self).__init__(**kwargs)
/usr/lib/python2.7/site-packages/debtcollector/renames.py:43: DeprecationWarning: Using the 'tenant_id' argument is deprecated in version '1.7.0' and will be removed in version '2.0.0', please use the 'project_id' argument instead
  return f(*args, **kwargs)
/usr/lib/python2.7/site-packages/keystoneclient/httpclient.py:376: DeprecationWarning: Constructing an HTTPClient instance without using a session is deprecated as of the 1.7.0 release and may be removed in the 2.0.0 release.
  'the 2.0.0 release.', DeprecationWarning)
Authorization Failed: The resource could not be found. (HTTP 404) (Request-ID: req-cf651f61-ed67-4c3e-9a50-257554834014)
== Glance images ==
+--------------------------------------+--------+
| ID                                   | Name   |
+--------------------------------------+--------+
| 58cc8b26-05f6-4976-9788-3467f5649069 | cirros |
+--------------------------------------+--------+
== Nova managed services ==
+----+------------------+------------+----------+---------+-------+----------------------------+-----------------+
| Id | Binary           | Host       | Zone     | Status  | State | Updated_at                 | Disabled Reason |
+----+------------------+------------+----------+---------+-------+----------------------------+-----------------+
| 1  | nova-cert        | controller | internal | enabled | up    | 2016-01-18T06:51:05.000000 | -               |
| 2  | nova-consoleauth | controller | internal | enabled | up    | 2016-01-18T06:51:05.000000 | -               |
| 3  | nova-conductor   | controller | internal | enabled | up    | 2016-01-18T06:51:04.000000 | -               |
| 5  | nova-scheduler   | controller | internal | enabled | up    | 2016-01-18T06:51:05.000000 | -               |
| 6  | nova-compute     | computer1  | nova     | enabled | up    | 2016-01-18T06:50:58.000000 | -               |
+----+------------------+------------+----------+---------+-------+----------------------------+-----------------+
== Nova networks ==
+--------------------------------------+--------+------+
| ID                                   | Label  | Cidr |
+--------------------------------------+--------+------+
| a0bde269-d320-4853-9045-e2e90ba14031 | public | -    |
+--------------------------------------+--------+------+
== Nova instance flavors ==
+----+-----------+-----------+------+-----------+------+-------+-------------+-----------+
| ID | Name      | Memory_MB | Disk | Ephemeral | Swap | VCPUs | RXTX_Factor | Is_Public |
+----+-----------+-----------+------+-----------+------+-------+-------------+-----------+
| 1  | m1.tiny   | 512       | 1    | 0         |      | 1     | 1.0         | True      |
| 2  | m1.small  | 2048      | 20   | 0         |      | 1     | 1.0         | True      |
| 3  | m1.medium | 4096      | 40   | 0         |      | 2     | 1.0         | True      |
| 4  | m1.large  | 8192      | 80   | 0         |      | 4     | 1.0         | True      |
| 5  | m1.xlarge | 16384     | 160  | 0         |      | 8     | 1.0         | True      |
+----+-----------+-----------+------+-----------+------+-------+-------------+-----------+
== Nova instances ==
+----+------+--------+------------+-------------+----------+
| ID | Name | Status | Task State | Power State | Networks |
+----+------+--------+------------+-------------+----------+
+----+------+--------+------------+-------------+----------+
[root@controller ~]# nova service-list
+----+------------------+------------+----------+---------+-------+----------------------------+-----------------+
| Id | Binary           | Host       | Zone     | Status  | State | Updated_at                 | Disabled Reason |
+----+------------------+------------+----------+---------+-------+----------------------------+-----------------+
| 1  | nova-cert        | controller | internal | enabled | up    | 2016-01-18T06:51:15.000000 | -               |
| 2  | nova-consoleauth | controller | internal | enabled | up    | 2016-01-18T06:51:15.000000 | -               |
| 3  | nova-conductor   | controller | internal | enabled | up    | 2016-01-18T06:51:14.000000 | -               |
| 5  | nova-scheduler   | controller | internal | enabled | up    | 2016-01-18T06:51:15.000000 | -               |
| 6  | nova-compute     | computer1  | nova     | enabled | up    | 2016-01-18T06:51:18.000000 | -               |
+----+------------------+------------+----------+---------+-------+----------------------------+-----------------+

#[root@controller keystone]# tail -100 keystone.log
2016-01-18 14:51:50.472 4371 INFO keystone.common.wsgi [req-5e792ba7-4b66-4bd0-a96d-2735fe4535e1 - - - - -] GET http://controller:35357/
2016-01-18 14:51:50.480 4374 INFO keystone.common.wsgi [req-b787678c-7dd2-4d1e-9e30-5d0d3a876003 - - - - -] POST http://controller:35357/v3/auth/tokens
2016-01-18 14:51:50.547 4372 INFO keystone.common.wsgi [req-867f218c-0273-4212-89c1-badf668848af - - - - -] GET http://controller:35357/
2016-01-18 14:51:50.561 4371 INFO keystone.common.wsgi [req-4ea89a76-2ba0-4832-ae20-3990aefd9f48 - - - - -] GET http://controller:35357/v3/auth/tokens
2016-01-18 14:51:50.848 4370 INFO keystone.common.wsgi [req-1414aef8-e365-40d8-ae59-9db308896e7e - - - - -] POST http://localhost:5000/v2.0/tokens
2016-01-18 14:51:50.849 4370 WARNING keystone.common.wsgi [req-1414aef8-e365-40d8-ae59-9db308896e7e - - - - -] Expecting to find username or userId in passwordCredentials - the server could not comply with the request since it is either malformed or otherwise incorrect. The client is assumed to be in error.

[root@controller nova]# tail -100 nova-api.log
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions     self.auth_ref = self.get_auth_ref(session)
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/v2.py", line 88, in get_auth_ref
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions     authenticated=False, log=False)
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 501, in post
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions     return self.request(url, 'POST', **kwargs)
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/keystoneclient/utils.py", line 337, in inner
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions     return func(*args, **kwargs)
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions   File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 401, in request
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions     raise exceptions.from_response(resp, method, url)
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions BadRequest: Expecting to find username or userId in passwordCredentials - the server could not comply with the request since it is either malformed or otherwise incorrect. The client is assumed to be in error. (HTTP 400) (Request-ID: req-1414aef8-e365-40d8-ae59-9db308896e7e)
2016-01-18 14:51:50.851 3592 ERROR nova.api.openstack.extensions
2016-01-18 14:51:50.984 3592 INFO nova.api.openstack.wsgi [req-f577550f-adc2-4be6-a90a-569162f7fa97 859afdfb5ee44e92b1b879c75a71c43f ab434fde66ea4dc391e9c423822b5ddf - - -] HTTP exception thrown: Unexpected API Error. Please report this at http://bugs.launchpad.net/nova/ and attach the Nova API log if possible.
<class 'keystoneclient.exceptions.BadRequest'>

[root@controller nova]# tail -100 nova-scheduler.log
2016-01-18 14:50:28.385 1288 ERROR oslo.messaging._drivers.impl_rabbit [req-c6758fd5-a80e-4e9d-b6d3-e14c80d9837f - - - - -] AMQP server on controller:5672 is unreachable: [Errno 111] ECONNREFUSED. Trying again in 2 seconds.
2016-01-18 14:50:29.402 1288 ERROR oslo.messaging._drivers.impl_rabbit [req-c6758fd5-a80e-4e9d-b6d3-e14c80d9837f - - - - -] AMQP server on controller:5672 is unreachable: [Errno 111] ECONNREFUSED. Trying again in 2 seconds.
2016-01-18 14:50:30.452 1288 INFO oslo.messaging._drivers.impl_rabbit [req-c6758fd5-a80e-4e9d-b6d3-e14c80d9837f - - - - -] Reconnected to AMQP server on controller:5672

回复

使用道具 举报

bob007 发表于 2016-1-18 19:25:02
shenadam 发表于 2016-1-18 14:59
谢谢您,日志有点多,请帮忙分析分析。

computer节点没见到日志报错,如下是在controller节点上的。

检查下 nova.conf  是否落下什么配置了

[DEFAULT]
...
network_api_class = nova.network.neutronv2.api.API
security_group_api = neutron
linuxnet_interface_driver = nova.network.linux_net.NeutronLinuxBridgeInterfaceDriver
firewall_driver = nova.virt.firewall.NoopFirewallDriver

回复

使用道具 举报

shenadam 发表于 2016-1-18 23:04:55
bob007 发表于 2016-1-18 19:25
检查下 nova.conf  是否落下什么配置了

[DEFAULT]

配置都核对过了,并没有啥异常!折腾死了都
回复

使用道具 举报

bob007 发表于 2016-1-19 17:39:46
shenadam 发表于 2016-1-18 23:04
配置都核对过了,并没有啥异常!折腾死了都

openstack比较复杂的,一次成功不可能的。
最好先手工安装,了解原理。
然后在自动化
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

关闭

推荐上一条 /2 下一条