Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

nova compute list returning error 404

I know this is a very common question here, so I will say that I have gone through a lot of them and I have not get it fixed. I hope this is all the information you need to debug my problem. I aám setting up small cloud for university research group for testing.

I have Ubuntu 14.04 and I followed the current mitaka manual for Ubuntu 14.04. I have gotten to this stage so far: http://docs.openstack.org/mitaka/install-guide-ubuntu/nova-verify.html - Nova Verification

forseti@controller:~$ openstack compute service list
Not found (HTTP 404) (Request-ID: req-3272e966-9247-473c-891e-c46c4efc784b)

These commands work for example: openstack image list and openstack user list Also:

forseti@controller:~$ curl http://controller:35357/v3
{"version": {"status": "stable", "updated": "2016-04-04T00:00:00Z", "media-types": [{"base": "application/json", "type": "application/vnd.openstack.identity-v3+json"}], "id": "v3.6", "links": [{"href": "http://controller:35357/v3/", "rel": "self"}]}}

Output of /var/log/nova/nova-api.log is:

2016-05-05 11:34:07.988 12152 INFO nova.osapi_compute.wsgi.server [req-94cb41e9-5bda-4449-abfd-c9ac4a068c95 dd8e1ce613ac45e7a7bf8271e7b81ecb 67a42d00ed5d4119b824f8753f9c01d8 - - -] 192.168.2.1 "GET /v2.1/(tenant_id)s/os-services HTTP/1.1" status: 404 len: 264 time: 1.4167972
2016-05-05 11:34:17.694 12150 INFO nova.osapi_compute.wsgi.server [req-f89501a8-f31e-4f87-bdf4-572092bc1162 dd8e1ce613ac45e7a7bf8271e7b81ecb 67a42d00ed5d4119b824f8753f9c01d8 - - -] 192.168.2.1 "GET /v2.1/(tenant_id)s/os-services HTTP/1.1" status: 404 len: 264 time: 1.3741801

My nova conf file /etc/nova/nova.conf look like this:

DEFAULT]
dhcpbridge_flagfile=/etc/nova/nova.conf
dhcpbridge=/usr/bin/nova-dhcpbridge
state_path=/var/lib/nova
lock_path=/var/lock/nova
force_dhcp_release=True
libvirt_use_virtio_for_bridges=True
verbose=True
ec2_private_dns_show_ip=True
api_paste_config=/etc/nova/api-paste.ini

#Admin added configuration
enabled_apis=osapi_compute,metadata
rpc_backend = rabbit
auth_strategy = keystone
my_ip = 192.168.2.1
use_neutron = True
firewall_driver = nova.virt.firewall.NoopFirewallDriver

[api_database]

connection = mysql+pymysql://nova:password@controller/nova_api

[database]
connection = mysql+pymysql://nova:password@controller/nova

[oslo_messaging_rabbit]
rabbit_host = controller
rabbit_userid = openstack
rabbit_password = password

[keystone_authtoken]
auth_uri = http://controller:5000/v3
auth_url = http://controller:35357/v3
auth_version =
memcached_servers = controller:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = nova
password = password

[vnc]
vncserver_listen = $my_ip
vncserver_proxyclient_address = $my_ip

[glance]
api_servers = http://controller:9292
glance_api_servers = http://controller:9292

[oslo_concurrency]
lock_path = /var/lib/nova/tmp

[neutron]
auth_strategy = keystone
admin_auth_url = http://controller:35357/v3

My admin_openrc file contents are:

export OS_PROJECT_DOMAIN_NAME=default
export OS_USER_DOMAIN_NAME=default
export OS_PROJECT_NAME=admin
export OS_USERNAME=admin
export OS_PASSWORD=password
export OS_AUTH_URL=http://controller:35357/v3
export OS_IDENTITY_API_VERSION=3
export OS_IMAGE_API_VERSION=2
export OS_AUTH_VERSION=3

Output of openstack image service list is:

START with options: ['--debug', 'compute', 'service', 'list']
options: Namespace(access_token_endpoint='', auth_type='', auth_url='http://controller:35357/v3', cacert='', client_id='', client_secret='***', cloud='', debug=True, default_domain='default', deferred_help=False, domain_id='', domain_name='', endpoint='', identity_provider='', identity_provider_url='', insecure=None, interface='', log_file=None, os_compute_api_version='', os_identity_api_version='3', os_image_api_version='2', os_network_api_version='', os_object_api_version='', os_project_id=None, os_project_name=None, os_volume_api_version='', password='***', profile=None, project_domain_id='', project_domain_name='default', project_id='', project_name='admin', protocol='', region_name='', scope='', service_provider_endpoint='', timing=False, token='***', trust_id='', url='', user_domain_id='', user_domain_name='default', user_id='', username='admin', verbose_level=3, verify=None)
defaults: {u'auth_type': 'password', u'compute_api_version': u'2', 'key': None, u'database_api_version': u'1.0', 'api_timeout': None, u'baremetal_api_version': u'1', u'image_api_version': u'2', 'cacert': None, u'image_api_use_tasks': False, u'floating_ip_source': u'neutron', u'orchestration_api_version': u'1', u'interface': None, u'network_api_version': u'2', u'image_format': u'qcow2', u'key_manager_api_version': u'v1', u'metering_api_version': u'2', 'verify': True, u'identity_api_version': u'2.0', u'volume_api_version': u'2', 'cert': None, u'secgroup_source': u'neutron', u'container_api_version': u'1', u'dns_api_version': u'2', u'object_store_api_version': u'1', u'disable_vendor_agent': {}}
cloud cfg: {'auth_type': 'password', u'compute_api_version': u'2', 'key': None, u'database_api_version': u'1.0', 'timing': False, u'network_api_version': u'2', u'image_format': u'qcow2', u'image_api_version': '2', 'verify': True, u'dns_api_version': u'2', u'object_store_api_version': u'1', 'verbose_level': 3, 'region_name': '', 'api_timeout': None, u'baremetal_api_version': u'1', 'auth': {'username': 'admin', 'project_name': 'admin', 'user_domain_name': 'default', 'auth_url': 'http://controller:35357/v3', 'password': '***', 'project_domain_name': 'default'}, 'default_domain': 'default', u'container_api_version': u'1', u'image_api_use_tasks': False, u'floating_ip_source': u'neutron', u'orchestration_api_version': u'1', u'interface': None, 'cacert': None, u'key_manager_api_version': u'v1', u'metering_api_version': u'2', 'deferred_help': False, u'identity_api_version': '3', u'volume_api_version': u'2', 'cert': None, u'secgroup_source': u'neutron', 'debug': True, u'disable_vendor_agent': {}}
compute API version 2, cmd group openstack.compute.v2
network API version 2, cmd group openstack.network.v2
image API version 2, cmd group openstack.image.v2
volume API version 2, cmd group openstack.volume.v2
identity API version 3, cmd group openstack.identity.v3
object_store API version 1, cmd group openstack.object_store.v1
command: compute service list -> openstackclient.compute.v2.service.ListService
Auth plugin password selected
auth_type: password
Using auth plugin: password
Using parameters {'username': 'admin', 'project_name': 'admin', 'auth_url': 'http://controller:35357/v3', 'user_domain_name': 'default', 'password': '***', 'project_domain_name': 'default'}
Get auth_ref
REQ: curl -g -i -X GET http://controller:35357/v3 -H "Accept: application/json" -H "User-Agent: python-openstackclient keystoneauth1/2.4.0 python-requests/2.9.1 CPython/2.7.6"
Starting new HTTP connection (1): controller
"GET /v3 HTTP/1.1" 200 250
RESP: [200] Content-Length: 250 Vary: X-Auth-Token Keep-Alive: timeout=5, max=100 Server: Apache/2.4.7 (Ubuntu) Connection: Keep-Alive Date: Thu, 05 May 2016 07:55:47 GMT x-openstack-request-id: req-a0cbcbcd-ea31-4fcb-ba5a-81859038ca72 Content-Type: application/json X-Distribution: Ubuntu 
RESP BODY: {"version": {"status": "stable", "updated": "2016-04-04T00:00:00Z", "media-types": [{"base": "application/json", "type": "application/vnd.openstack.identity-v3+json"}], "id": "v3.6", "links": [{"href": "http://controller:35357/v3/", "rel": "self"}]}}

Making authentication request to http://controller:35357/v3/auth/tokens
"POST /v3/auth/tokens HTTP/1.1" 201 2233
run(Namespace(columns=[], formatter='table', host=None, max_width=0, noindent=False, quote_mode='nonnumeric', service=None))
Instantiating compute client for VAPI Version Major: 2, Minor: 0
Making authentication request to http://controller:35357/v3/auth/tokens
"POST /v3/auth/tokens HTTP/1.1" 201 2233
REQ: curl -g -i -X GET http://controller:8774/v2.1/(tenant_id)s/os-services -H "User-Agent: python-novaclient" -H "Accept: application/json" -H "X-Auth-Token: {SHA1}9520867f205b2804379d2c07407f6669ef259088"
Starting new HTTP connection (1): controller
"GET /v2.1/(tenant_id)s/os-services HTTP/1.1" 404 52
RESP: [404] Date: Thu, 05 May 2016 07:55:49 GMT Connection: keep-alive Content-Type: text/plain; charset=UTF-8 Content-Length: 52 X-Compute-Request-Id: req-0eab3deb-ccca-41df-a872-8e1cb701833a 
RESP BODY: 404 Not Found

The resource could not be found.



Not found (HTTP 404) (Request-ID: req-0eab3deb-ccca-41df-a872-8e1cb701833a)
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/cliff/app.py", line 374, in run_subcommand
    result = cmd.run(parsed_args)
  File "/usr/lib/python2.7/dist-packages/openstackclient/common/command.py", line 38, in run
    return super(Command, self).run(parsed_args)
  File "/usr/lib/python2.7/dist-packages/cliff/display.py", line 92, in run
    column_names, data = self.take_action(parsed_args)
  File "/usr/lib/python2.7/dist-packages/openstackclient/compute/v2/service.py", line 66, in take_action
    parsed_args.service)
  File "/usr/lib/python2.7/dist-packages/novaclient/v2/services.py", line 52, in list
    return self._list(url, "services")
  File "/usr/lib/python2.7/dist-packages/novaclient/base.py", line 242, in _list
    resp, body = self.api.client.get(url)
  File "/usr/lib/python2.7/dist-packages/keystoneauth1/adapter.py", line 173, in get
    return self.request(url, 'GET', **kwargs)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 94, in request
    raise exceptions.from_response(resp, body, url, method)
NotFound: Not found (HTTP 404) (Request-ID: req-0eab3deb-ccca-41df-a872-8e1cb701833a)
clean_up ListService: Not found (HTTP 404) (Request-ID: req-0eab3deb-ccca-41df-a872-8e1cb701833a)
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/openstackclient/shell.py", line 118, in run
    ret_val = super(OpenStackShell, self).run(argv)
  File "/usr/lib/python2.7/dist-packages/cliff/app.py", line 255, in run
    result = self.run_subcommand(remainder)
  File "/usr/lib/python2.7/dist-packages/openstackclient/shell.py", line 153, in run_subcommand
    ret_value = super(OpenStackShell, self).run_subcommand(argv)
  File "/usr/lib/python2.7/dist-packages/cliff/app.py", line 374, in run_subcommand
    result = cmd.run(parsed_args)
  File "/usr/lib/python2.7/dist-packages/openstackclient/common/command.py", line 38, in run
    return super(Command, self).run(parsed_args)
  File "/usr/lib/python2.7/dist-packages/cliff/display.py", line 92, in run
    column_names, data = self.take_action(parsed_args)
  File "/usr/lib/python2.7/dist-packages/openstackclient/compute/v2/service.py", line 66, in take_action
    parsed_args.service)
  File "/usr/lib/python2.7/dist-packages/novaclient/v2/services.py", line 52, in list
    return self._list(url, "services")
  File "/usr/lib/python2.7/dist-packages/novaclient/base.py", line 242, in _list
    resp, body = self.api.client.get(url)
  File "/usr/lib/python2.7/dist-packages/keystoneauth1/adapter.py", line 173, in get
    return self.request(url, 'GET', **kwargs)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 94, in request
    raise exceptions.from_response(resp, body, url, method)
NotFound: Not found (HTTP 404) (Request-ID: req-0eab3deb-ccca-41df-a872-8e1cb701833a)

END return value: 1