分享

openstack 使用nova命令报错

445433045 发表于 2016-6-17 13:52:15 [显示全部楼层] 回帖奖励 阅读模式 关闭右栏 3 10835
#可以使用nova-manage
[root@c1 ~]# nova-manage service list
Binary           Host                                 Zone             Status     State Updated_At
nova-consoleauth c1                                   internal         enabled    :-)   2016-06-17 05:51:58
nova-conductor   c1                                   internal         enabled    :-)   2016-06-17 05:52:04
nova-scheduler   c1                                   internal         enabled    :-)   2016-06-17 05:52:04
nova-cert        c1                                   internal         enabled    :-)   2016-06-17 05:51:58
nova-compute     n1                                   nova             enabled    :-)   2016-06-17 05:51:59
nova-network     n1                                   internal         enabled    :-)   2016-06-17 05:52:07

#但是使用nova service-list报错
[root@c1 ~]# nova --debug service-list
DEBUG (session:195) REQ: curl -g -i -X GET http://172.16.12.250:35357/v3 -H "Accept: application/json" -H "User-Agent: python-keystoneclient"
INFO (connectionpool:213) Starting new HTTP connection (1): 172.16.12.250
DEBUG (connectionpool:393) "GET /v3 HTTP/1.1" 200 253
DEBUG (session:224) RESP: [200] Content-Length: 253 Vary: X-Auth-Token Keep-Alive: timeout=5, max=100 Server: Apache/2.4.6 (CentOS) mod_wsgi/3.4 Python/2.7.5 Connection: Keep-Alive Date: Fri, 17 Jun 2016 05:52:45 GMT Content-Type: application/json x-openstack-request-id: req-0dc3b188-3023-45d6-868e-3368ccbb256a
RESP BODY: {"version": {"status": "stable", "updated": "2015-03-30T00:00:00Z", "media-types": [{"base": "application/json", "type": "application/vnd.openstack.identity-v3+json"}], "id": "v3.4", "links": [{"href": "http://172.16.12.250:35357/v3/", "rel": "self"}]}}

DEBUG (base:171) Making authentication request to http://172.16.12.250:35357/v3/auth/tokens
DEBUG (connectionpool:393) "POST /v3/auth/tokens HTTP/1.1" 500 143
DEBUG (session:396) Request returned failure status: 500
DEBUG (shell:914) An unexpected error prevented the server from fulfilling your request. (HTTP 500) (Request-ID: req-55599cce-e616-4b0e-9d6f-5ac99534ba0d)
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/novaclient/shell.py", line 911, in main
    OpenStackComputeShell().main(argv)
  File "/usr/lib/python2.7/site-packages/novaclient/shell.py", line 838, in main
    args.func(self.cs, args)
  File "/usr/lib/python2.7/site-packages/novaclient/v2/shell.py", line 3442, in do_service_list
    result = cs.services.list(host=args.host, binary=args.binary)
  File "/usr/lib/python2.7/site-packages/novaclient/v2/services.py", line 49, in list
    return self._list(url, "services")
  File "/usr/lib/python2.7/site-packages/novaclient/base.py", line 64, in _list
    _resp, body = self.api.client.get(url)
  File "/usr/lib/python2.7/site-packages/keystoneclient/adapter.py", line 170, in get
    return self.request(url, 'GET', **kwargs)
  File "/usr/lib/python2.7/site-packages/novaclient/client.py", line 89, in request
    **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/adapter.py", line 206, in request
    resp = super(LegacyJsonAdapter, self).request(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/adapter.py", line 95, in request
    return self.session.request(url, method, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/utils.py", line 318, in inner
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 313, in request
    auth_headers = self.get_auth_headers(auth)
  File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 598, in get_auth_headers
    return auth.get_headers(self, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/auth/base.py", line 114, in get_headers
    token = self.get_token(session)
  File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/base.py", line 104, in get_token
    return self.get_access(session).auth_token
  File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/base.py", line 144, in get_access
    self.auth_ref = self.get_auth_ref(session)
  File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/generic/base.py", line 176, in get_auth_ref
    return self._plugin.get_auth_ref(session, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/v3/base.py", line 173, in get_auth_ref
    authenticated=False, log=False, **rkwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 497, in post
    return self.request(url, 'POST', **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/utils.py", line 318, in inner
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 397, in request
    raise exceptions.from_response(resp, method, url)
InternalServerError: An unexpected error prevented the server from fulfilling your request. (HTTP 500) (Request-ID: req-55599cce-e616-4b0e-9d6f-5ac99534ba0d)
ERROR (InternalServerError): An unexpected error prevented the server from fulfilling your request. (HTTP 500) (Request-ID: req-55599cce-e616-4b0e-9d6f-5ac99534ba0d)

已有(3)人评论

跳转到指定楼层
445433045 发表于 2016-6-18 01:34:08
这个是数据库的问题连接的问题,如果把数据库连接写成:connection = mysql://nova:NOVA_DBPASS@controller/nova会报这个错误,如果写成localhost就不会报这个错误了。我也不知道是为什么,远程访问的权限也添加了。
回复

使用道具 举报

445433045 发表于 2016-6-17 14:03:18
求解,为什么keystone会认证错误?
回复

使用道具 举报

nextuser 发表于 2016-6-17 18:41:50
445433045 发表于 2016-6-17 14:03
求解,为什么keystone会认证错误?

检测下keystone各个服务是否正常
回复

使用道具 举报

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

本版积分规则

关闭

推荐上一条 /2 下一条