$ceilometer alarm-list
报错
HTTPConnectionPool(host='25.0.0.2', port=8777): Max retries exceeded with url: /v2/alarms (Caused by <class 'httplib.BadStatusLine'>: '')
ceilometer --debug alarm-list
DEBUG (session) REQ: curl -i -X GET http://172.16.101.2:5000/v2.0/ -H "Accept: application/json" -H "User-Agent: python-keystoneclient"
DEBUG (session) RESP: [200] {'date': 'Mon, 13 Jul 2015 03:07:59 GMT', 'content-type': 'application/json', 'content-length': '422', 'vary': 'X-Auth-Token', 'connection': 'close'}
RESP BODY: {"version": {"status": "stable", "updated": "2014-04-17T00:00:00Z", "media-types": [{"base": "application/json", "type": "application/vnd.openstack.identity-v2.0+json"}, {"base": "application/xml", "type": "application/vnd.openstack.identity-v2.0+xml"}], "id": "v2.0", "links": [{"href": "http://172.16.101.2:5000/v2.0/", "rel": "self"}, {"href": "http://docs.openstack.org/", "type": "text/html", "rel": "describedby"}]}}
DEBUG (v2) Making authentication request to http://172.16.101.2:5000/v2.0/tokens
DEBUG (client) REQ: curl -i -X 'GET' 'http://25.0.0.2:8777/v2/alarms' -H 'User-Agent: ceilometerclient.openstack.common.apiclient' -H 'X-Auth-Token: 1dc045340f614d0ebc15bfc3c4dd8543'
Traceback (most recent call last):
File "/usr/bin/ceilometer", line 10, in <module>
sys.exit(main())
File "/usr/lib/python2.7/site-packages/ceilometerclient/shell.py", line 275, in main
CeilometerShell().main(args)
File "/usr/lib/python2.7/site-packages/ceilometerclient/shell.py", line 224, in main
args.func(client, args)
File "/usr/lib/python2.7/site-packages/ceilometerclient/v2/shell.py", line 309, in do_alarm_list
alarms = cc.alarms.list(q=options.cli_to_array(args.query))
File "/usr/lib/python2.7/site-packages/ceilometerclient/v2/alarms.py", line 80, in list
return self._list(options.build_url(self._path(), q))
File "/usr/lib/python2.7/site-packages/ceilometerclient/common/base.py", line 59, in _list
resp = self.api.get(url)
File "/usr/lib/python2.7/site-packages/ceilometerclient/openstack/common/apiclient/client.py", line 334, in get
return self.client_request("GET", url, **kwargs)
File "/usr/lib/python2.7/site-packages/ceilometerclient/openstack/common/apiclient/client.py", line 328, in client_request
self, method, url, **kwargs)
File "/usr/lib/python2.7/site-packages/ceilometerclient/openstack/common/apiclient/client.py", line 244, in client_request
method, self.concat_url(endpoint, url), **kwargs)
File "/usr/lib/python2.7/site-packages/ceilometerclient/openstack/common/apiclient/client.py", line 174, in request
resp = self.http.request(method, url, **kwargs)
File "/usr/lib/python2.7/site-packages/requests/sessions.py", line 456, in request
resp = self.send(prep, **send_kwargs)
File "/usr/lib/python2.7/site-packages/requests/sessions.py", line 559, in send
r = adapter.send(request, **kwargs)
File "/usr/lib/python2.7/site-packages/requests/adapters.py", line 375, in send
raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPConnectionPool(host='25.0.0.2', port=8777): Max retries exceeded with url: /v2/alarms (Caused by <class 'httplib.BadStatusLine'>: '')
pip install --upgrade requests
升级之后重启ceilometer-api即可