Running neutron commands against RHEL-OSP4 while using neutronclient-2.3.9 fails with error "Unable to establish connection to http://localhost:35357/v2.0/tokens"
Issue
- I have Mac OS or Fedora client system where I have installed the latest version of neutronclient package (python-neutronclient-2.3.9). Running neutron commands against an RHEL-OSP4 system fails with below error.
# neutron net-list
Unable to establish connection to http://localhost:35357/v2.0/tokens
- Debug output is given below.
# neutron -v net-list
DEBUG: keystoneclient.session REQ: curl -i -X GET http://10.65.216.20:35357/v2.0/ -H "Accept: application/json" -H "User-Agent: python-keystoneclient"
DEBUG: keystoneclient.session RESP: [200] CaseInsensitiveDict({'date': 'Fri, 31 Oct 2014 13:19:03 GMT', 'content-type': 'application/json', 'content-length': '613', 'vary': 'X-Auth-Token'})
RESP BODY: {"version": {"status": "stable", "updated": "2013-03-06T00: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://localhost:35357/v2.0/", "rel": "self"}, {"href": "http://docs.openstack.org/api/openstack-identity-service/2.0/content/", "type": "text/html", "rel": "describedby"}, {"href": "http://docs.openstack.org/api/openstack-identity-service/2.0/identity-dev-guide-2.0.pdf", "type": "application/pdf", "rel": "describedby"}]}}
DEBUG: stevedore.extension found extension EntryPoint.parse('table = cliff.formatters.table:TableFormatter')
DEBUG: stevedore.extension found extension EntryPoint.parse('csv = cliff.formatters.commaseparated:CSVLister')
DEBUG: neutronclient.neutron.v2_0.network.ListNetwork get_data(Namespace(columns=[], fields=[], formatter='table', max_width=0, page_size=None, quote_mode='nonnumeric', request_format='json', show_details=False, sort_dir=[], sort_key=[]))
DEBUG: keystoneclient.auth.identity.v2 Making authentication request to http://localhost:35357/v2.0/tokens
ERROR: neutronclient.shell Unable to establish connection to http://localhost:35357/v2.0/tokens
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/neutronclient/shell.py", line 691, in run_subcommand
return run_command(cmd, cmd_parser, sub_argv)
File "/usr/lib/python2.7/site-packages/neutronclient/shell.py", line 90, in run_command
return cmd.run(known_args)
File "/usr/lib/python2.7/site-packages/neutronclient/common/command.py", line 29, in run
return super(OpenStackCommand, self).run(parsed_args)
File "/usr/lib/python2.7/site-packages/cliff/display.py", line 91, in run
column_names, data = self.take_action(parsed_args)
File "/usr/lib/python2.7/site-packages/neutronclient/common/command.py", line 35, in take_action
return self.get_data(parsed_args)
File "/usr/lib/python2.7/site-packages/neutronclient/neutron/v2_0/__init__.py", line 669, in get_data
data = self.retrieve_list(parsed_args)
File "/usr/lib/python2.7/site-packages/neutronclient/neutron/v2_0/__init__.py", line 615, in retrieve_list
neutron_client = self.get_client()
File "/usr/lib/python2.7/site-packages/neutronclient/neutron/v2_0/__init__.py", line 398, in get_client
return self.app.client_manager.neutron
File "/usr/lib/python2.7/site-packages/neutronclient/common/clientmanager.py", line 39, in __get__
self._handle = self.factory(instance)
File "/usr/lib/python2.7/site-packages/neutronclient/neutron/client.py", line 35, in make_client
instance.initialize()
File "/usr/lib/python2.7/site-packages/neutronclient/common/clientmanager.py", line 113, in initialize
httpclient.authenticate()
File "/usr/lib/python2.7/site-packages/neutronclient/client.py", line 328, in authenticate
interface=self.interface)
File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 529, in get_endpoint
return auth.get_endpoint(self, **kwargs)
File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/base.py", line 192, in get_endpoint
service_catalog = self.get_access(session).service_catalog
File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/base.py", line 126, in get_access
self.auth_ref = self.get_auth_ref(session)
File "/usr/lib/python2.7/site-packages/keystoneclient/auth/identity/v2.py", line 79, in get_auth_ref
authenticated=False, log=False)
File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 430, 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 332, in request
resp = send(**kwargs)
File "/usr/lib/python2.7/site-packages/keystoneclient/session.py", line 374, in _send_request
raise exceptions.ConnectionRefused(msg)
ConnectionRefused: Unable to establish connection to http://localhost:35357/v2.0/tokens
Unable to establish connection to http://localhost:35357/v2.0/tokens
- The same command against the same environment works if I use neutronclient-2.3.5. How can I resolve this?
Environment
- Red Hat Enterprise Linux Openstack Platform v4
- A client system that uses python-neutronclient-2.3.9
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
