ERROR (ClientException) nova image-list
nova image-list
ERROR (ClientException): The server has either erred or is incapable of performi9e-6cdca5eee7b2)
Ask Your Question |
glance image-list is fine but, nova image-list error
36 ●2 ●2 ●7
I am installing liberty release on centos7 with one controller and one compute node.
nova service-list and nova endpoints work fine. But, nova image-list returns the following error.
ERROR(ClientException) : Unexpected API Error. Please report this at http://bugs.launchpad.net/nova and attach the Nova API log if possible.
<class 'glanceclient.exc.HTTPInternalServerError'> (HTTP 500) (Request-ID: ...)
glance image-list works fine. Pls, help me out.
the nova-api.log is following.
2015-12-14 16:29:56.071 9986 INFO nova.osapi_compute.wsgi.server [req-496b5df0-e28f-486b-8386-96f704433daf 504f2af1b9044a3e97bc69e80daf5809 8de4c51458804564b79932efa364524b - - -] 192.168.219.11 "GET /v2/ HTTP/1.1" status: 200 len: 572 time: 0.0285130
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions [req-e65f8242-8d2c-43f1-af66-362f3161b655 504f2af1b9044a3e97bc69e80daf5809 8de4c51458804564b79932efa364524b - - -] Unexpected exception in API method
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions Traceback (most recent call last):
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions File "/usr/lib/python2.7/site-packages/nova/api/openstack/extensions.py", line 478, in wrapped
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions return f(*args, **kwargs)
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions File "/usr/lib/python2.7/site-packages/nova/api/openstack/compute/images.py", line 145, in detail
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions **page_params)
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions File "/usr/lib/python2.7/site-packages/nova/image/api.py", line 68, in get_all
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions return session.detail(context, **kwargs)
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions File "/usr/lib/python2.7/site-packages/nova/image/glance.py", line 284, in detail
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions for image in images:
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions File "/usr/lib/python2.7/site-packages/glanceclient/v1/images.py", line 254, in list
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions for image in paginate(params, return_request_id):
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions File "/usr/lib/python2.7/site-packages/glanceclient/v1/images.py", line 238, in paginate
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions images, resp = self._list(url, "images")
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions File "/usr/lib/python2.7/site-packages/glanceclient/v1/images.py", line 63, in _list
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions resp, body = self.client.get(url)
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions File "/usr/lib/python2.7/site-packages/glanceclient/common/http.py", line 280, in get
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions return self._request('GET', url, **kwargs)
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions File "/usr/lib/python2.7/site-packages/glanceclient/common/http.py", line 272, in _request
2015-12-14 16:30:01.676 9986 ERROR nova.api.openstack.extensions ...
2 answers
36 ●2 ●2 ●7
I solved this problem.
It's because keystone version is set as v2.0. You should change it as v3.
In "openstack endpoint list", it should be like this.
public & internal : http://controller:5000/v2.0 --> http://controller:5000/v3
admin : http://controller:5000/v2.0 --> http://controller:35357/v3
I refered to this site to change keystone db.
http://www.cloudkb.net/how-to-change-keystone-api-v2-v3/
You don't have to change "policy.json" file as instructed in the above site. After change the db, reboot your system. And all the CLI commands work well.
Thanks. recital.
Comments
I have the same problem and they same set up like you, but changing version didn't do the trick for me
still got the error after I rebooted the box, is this a bug and is there already a bug report?
okay found my problem. Password was not the same in glance-registry.conf and glance-api.conf https://bugs.launchpad.net/nova/+bug/1514480 (https://bugs.launchpad.net/nova/+bug/...)
341 ●1 ●5 ●9
You might have missed this configuration in nova.conf
[glance]
api_servers = http:://<controllerip>:9292
Comments
I inserted "api_servers=http://controller:9292" in glance section on the controller node.
After that, "su -s /bin/sh -c "nova-manage db sync" nova" and restart all the nova services.
But, same problem happens when executing "nova image-list" on the controller node.
OK ... try this and see if it works now:---
[glance]
host = controller
I used the configuration at the first time. It didn't work...
ok... now it is becoming interesting... can you run the following command and paste the output here :-
nova --debug image-list
I posted the logs for "nova --debug image-list" on the above.
How to change keystone API V2 to V3
Posted on November , by Gopalakrishnan S Comments The Keystone Identity Service allows clients to obtain tokens that can be used to access OpenStack cloud services. This document is intended for software developers interested in developing applications that utilize the Keystone Identity Service API for authentication. The OpenStack Identity API is implemented using a RESTful web service interface. All requests to authenticate and operate against the OpenStack Identity API should be performed using SSL over HTTP (HTTPS) on TCP port .
keystone V3 Advantages ) Authentication is totally pluggable. You can write our own custom auth method. Beause of this extensible auth method, now keystone supports oauth1, federation ( federation is not fully done) ) Authorization : V2 is either “admin” or none. In v3 you can control who can call each method. ( Provided you define your own policy file ) ) Separate drivers for assignments and identity ) Rich set of APIs. There are lot more API available than v2.. Also there are no vendor specic extension. If you check v2., most of the role apis are Rackspace extensions
Before proceed to migrate keystone v2 to v3, you must check previous services are working fine. Use the following commands to verify the list of services works. How to change keystone API V2 to V3? [root@localhost ~(keystone_admin)]# keystone user-list
WARNING: Bypassing authentication using a token & endpoint (authentication credentials are being ignored).
+———————————-+————+———+———————-+
| id | name | enabled | email |
+———————————-+————+———+———————-+
| ed03407c56054729bee58be7f7710786 | admin | True | root@localhost |
| 3b52f88a70f149a791e295b1859ae8f4 | ceilometer | True | ceilometer@localhost | [root@localhost ~(keystone_admin)]# nova service-list
+——————+———–+———-+———+——-+—————————-+—————–+
| Binary | Host | Zone | Status | State | Updated_at | Disabled Reason |
+——————+———–+———-+———+——-+—————————-+—————–+
| nova-consoleauth | packstack | internal | enabled | up | --13T10::52.000000 | – |
| nova-scheduler | packstack | internal | enabled | up | --13T10::50.000000 | – |
| nova-conductor | packstack | internal | enabled | up | --13T10::54.000000 | – |
| nova-compute | packstack | nova | enabled | up | --13T10::51.000000 | – |
| nova-cert | packstack | internal | enabled | up | --13T10::52.000000 | – |
| nova-console | packstack | internal | enabled | up | --13T10::51.000000 | – |
+——————+———–+———-+———+——-+—————————-+—————–+
[root@localhost ~(keystone_admin)]# glance image-list
+————————————–+——–+————-+——————+———-+——–+
| ID | Name | Disk Format | Container Format | Size | Status |
+————————————–+——–+————-+——————+———-+——–+
| f4c137ca-8dd8-47f3-be70-106eac2f241f | cirros | qcow2 | bare | | active |
+————————————–+——–+————-+——————+———-+——–+ If all the services are working fine then proceed to migrate endpoint urls to V3 in your keystone databases. Login your mysql server and change endpoint URLs.
mysql> use keystone;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A Database changed mysql> select interface, url from endpoint e, service s where s.id=e.service_id and s.type=”identity”;
+———–+———————————-+
| interface | url |
+———–+———————————-+
| admin | http://192.168.1.133:35357/v2.0 |
| internal | http://192.168.1.133:5000/v2.0 |
| public | http://192.168.1.133:5000/v2.0 |
+———–+———————————-+
rows in set (0.01 sec) Get the identity service ID mysql> select id from service where type=”identity”;
+———————————-+
| id |
+———————————-+
| e32101fdfe4145d1a6a22351b41d88e5 |
+———————————-+
row in set (0.00 sec)
Use this query to replace URLs as per service id where ports
mysql> update endpoint set url=”http://192.168.1.196:5000/v3″ where url=”http://192.168.1.196:5000/v2.0″ and service_id=”76e23f322c2a48d18293db89dbca9e70″;
Query OK, rows affected (0.00 sec)
Rows matched: Changed: Warnings: Use this query to replace ports mysql> update endpoint set url=”http://192.168.1.196:35357/v3″ where url=”http://192.168.1.196:35357/v2.0″ and service_id=”76e23f322c2a48d18293db89dbca9e70″;
Query OK, row affected (0.00 sec)
Rows matched: Changed: Warnings: Thats all, you can verify the changed URLs. mysql> select interface, url from endpoint e, service s where s.id=e.service_id and s.type=”identity”;
+———–+——————————–+
| interface | url |
+———–+——————————–+
| admin | http://192.168.1.133:35357/v3 |
| internal | http://192.168.1.133:5000/v3 |
| public | http://192.168.1.133:5000/v3 |
+———–+——————————–+
rows in set (0.00 sec) mysql> upgrade Keystone Policy File Policy is just a set of rules combined by or/and logic. It should become more readable in future releases, The Openstack Identity v3 API, provided by Keystone, offers features that were lacking in the previous version. Among these features, it introduces the concept of domains, allowing isolation of projects and users. For instance, an administrator allowed to create projects and users in a given domain, may not have any right in another one. While these features look very exciting, some configuration needs to be done to have a working identity v3 service with domains properly set. Download policy.v3cloudsample.json file wget https://github.com/openstack/keystone/blob/master/etc/policy.v3cloudsample.json
mv /etc/keystone/policy.json /etc/keystone/policy.json.V2 mv policy.v3cloudsample.json /etc/keystone/policy.json chown keystone.keystone policy.json Update Keystone Endpoint Environment. export OS_USERNAME=admin
export OS_TENANT_NAME=admin
export OS_PASSWORD=<password>
export OS_AUTH_URL=http://192.168.1.133:5000/v3
export SERVICE_ENDPOINT=http://192.168.1.133:35357/v3 export SERVICE_TOKEN=c50f58a02dde43f286517af102786be0 Restart OpenStack Services /etc/init.d/openstack-keystone restart
Troubleshooting If you received “horizon unauthorized (http )” errors, you can revert back policy.json v2 file and try to restart services. How to Enable Multi Domains on openstack horizon Horizon supports multi domains as well. You need to add only a few changes to local_setting. Apply the correct policy.json file for keystone.
vi /etc/openstack-dashboard/local_settings uncommand the following settings. OPENSTACK_API_VERSIONS = {
“identity”:
}
OPENSTACK_KEYSTONE_MULTIDOMAIN_SUPPORT = True
OPENSTACK_KEYSTONE_URL = “http://192.168.1.133:5000/v3”
Save local_settings and restart openstack-dashboard. /etc/init.d/httpd restart
ERROR (ClientException) nova image-list的更多相关文章
- ERROR (ClientException)
aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAABPwAAABCCAIAAABM0F+3AAAgAElEQVR4nO2d+29d13Xn7y+xyMvLty
- ERROR (ClientException): Unexpected API Error
- [Nova ERROR] InternalError: Nova requires QEMU version 2.5.0 or greater.
目录 文章目录 目录 问题 调查 解决 问题 nova-compute service 启动失败 InternalError: Nova requires QEMU version 2.5.0 or ...
- nova --debug image-list
nova --debug image-list DEBUG (session:) REQ: curl -g -i -X GET http://liberty-aio:35357/v3 -H " ...
- [原]openstack-kilo--issue(十)ERROR: openstack Unable to establish connection to http://controller:35357/v3/auth/tokens
====环境== openstack :kilo CentOS : 7 ====问题=== 在没有关vm的情况下,重启了controller. 问题一: 在使用nova service-list 或者 ...
- OpenStack nova VM migration (live and cold) call flow
OpenStack nova compute supports two flavors of Virtual Machine (VM) migration: Cold migration -- mig ...
- nova instance出错:"message": "Proxy error: 502 Read from server failed
执行 $ nova resize instance1 时候出错: {, "details": " File \"/opt/stack/nova/nova/com ...
- Unexpected API Error. Please report this at http://bugs.launchpad.net/nova/ and attach the Nova API log if possible. <class 'sqlalchemy.exc.OperationalError'> (HTTP 500) (Request-ID: req-6ac88345-ce5a
Unexpected API Error. Please report this at http://bugs.launchpad.net/nova/ and attach the Nova API ...
- 1898 ERROR nova.compute.manager
2018-06-10 21:03:54.045 1898 ERROR nova.compute.manager [instance: 15a6c26f-b8af-4a3e-a3df-8552c16e0 ...
随机推荐
- window-messager(消息框)
所有的消息框都是异步的.用户可以在交互消息之后使用回调函数去处理结果或做一些自己需要处理的事情. 一.alert(警告框) <script type="text/javascript& ...
- core--进程
前面我们说了线程是一系列的指令,那么进程是什么呢?进程就是装下这些指令的容器.该容器除了线程,还包含资源等内容.一个进程至少要有一个线程.没有线程的进程就不叫进程 "进程和程序的区别:进程必 ...
- Spring MVC的UrlBasedViewResolver和InternalResourceViewResolver
Spring MVC使用ViewResolver来根据controller中返回的view名关联到具体的View对象.使用View对象来渲染返回值以生成最终的视图,如html,json或pdf等. S ...
- UVa 10420 List of Conquests
题意就是有N个pl妹子,然后每行第一个单词是妹子的国籍,后面是妹子的名字. 你的任务就是统计相同国籍妹子的个数,然后按字母表顺序输出. 我首先把所有的国籍都读入,然后用qsort()按字母表顺序排序. ...
- 51nod1406 与查询
这题卡I/O...dp一下... #include<cstdio> #include<cstring> #include<cctype> #include<a ...
- HDU 4006 The kth great number【优先队列】
题意:输入n行,k,如果一行以I开头,那么插入x,如果以Q开头,则输出第k大的数 用优先队列来做,将队列的大小维护在k这么大,然后每次取队首元素就可以了 另外这个维护队列只有k个元素的时候需要注意一下 ...
- 02.C语言关于指针的学习笔记
指针是一个特殊的变量,它里面存储的数值被解释成为内存里的一个地址. 要搞清一个指针需要搞清指针的四方面的内容: 指针的类型,指针所指向的 类型,指针的值或者叫指针所指向的内存区,还有指针本身所占据的内 ...
- SQL语句方法语法总结(三)
1.时间相关的操作 月份.星期.日期.时间格式转换.第几周 ,'2014-4-1') as '时间间隔', --在所给时间上加上时间间隔,转换成DATETIME DATEDIFF(DAY,'2014- ...
- NoSQL架构实践(一)——以NoSQL为辅
前面<为什么要使用NoSQL>和<关系数据库还是NoSQL数据库>两篇从大体上介绍了为什么要用NoSQL,何时该用NoSQL.经常有朋友遇到困惑,看到NoSQL的介绍,觉得很好 ...
- Spring3.0将全面支持REST
Rod Johnson上个月底说,Spring 3.0全面支持REST风格的Web服务. "We're really seeing extensive interest and growth ...