Ask Your Question
0

Creation of service project in keystone fails with error 'The request you have made requires authentication. (HTTP 401)'

asked 2017-06-07 04:13:05 -0600

amant gravatar image

I am following Ocata install guide (https://docs.openstack.org/ocata/install-guide-rdo/InstallGuide.pdf (https://docs.openstack.org/ocata/inst...)) At step 'Create a domain, projects, users, and roles' in Identity service, while executing the command I am getting error:-

[root@controller2 ~]# openstack project create --domain default --description "Service Project" service The request you have made requires authentication. (HTTP 401) (Request-ID: req-003f9830-c505-4f36-838b-44419b00693f)

------Relevant logs---------

[root@controller2 ~]# export | grep OS_ declare -x OS_AUTH_URL="http://controller2:35357/v3"
declare -x OS_IDENTITY_API_VERSION="3"
declare -x OS_PASSWORD="ADMIN_PASS"
declare -x OS_PROJECT_DOMAIN_NAME="Default"
declare -x OS_PROJECT_NAME="admin"
declare -x OS_USERNAME="admin"
declare -x OS_USER_DOMAIN_NAME="Default"


2017-06-07 05:05:04.024 5593 INFO keystone.common.wsgi [req-69ea5e16-9d0a-4a22-887f-a4266a92a61d - - - - -] GET http://controller2:35357/v3/
2017-06-07 05:05:04.053 5596 INFO keystone.common.wsgi [req-003f9830-c505-4f36-838b-44419b00693f - - - - -] POST http://controller2:35357/v3/auth/tokens
2017-06-07 05:05:04.262 5596 WARNING keystone.common.wsgi [req-003f9830-c505-4f36-838b-44419b00693f - - - - -] Authorization failed. The request you have made requires authentication. from 127.0.0.1

-----------------------

Debug logs

Get auth_ref REQ: curl -g -i -X GET http://controller2:35357/v3 -H "Accept: application/json" -H "User-Agent: osc-lib/1.3.0 keystoneauth1/2.18.0 python-requests/2.11.1 CPython/2.7.5" Starting new HTTP connection (1): controller2 "GET /v3 HTTP/1.1" 200 251 RESP: [200] Date: Wed, 07 Jun 2017 09:08:39 GMT Server: Apache/2.4.6 () mod_wsgi/3.4 Python/2.7.5 Vary: X-Auth-Token x-openstack-request-id: req-52c7f40c-6e54-446c-8da6-06a16f6aa2d7 Content-Length: 251 Keep-Alive: timeout=5, max=100 Connection: Keep-Alive Content-Type: application/json RESP BODY: {"version": {"status": "stable", "updated": "2017-02-22T00:00:00Z", "media-types": [{"base": "application/json", "type": "application/vnd.openstack.identity-v3+json"}], "id": "v3.8", "links": [{"href": "http://controller2:35357/v3/", "rel": "self"}]}}

GET call to None for http://controller2:35357/v3 used request id req-52c7f40c-6e54-446c-8da6-06a16f6aa2d7 Making authentication request to http://controller2:35357/v3/auth/tokens "POST /v3/auth/tokens HTTP/1.1" 401 114 Request returned failure status: 401 The request you have made requires authentication. (HTTP 401) (Request-ID: req-cbfeac69-9bb5-41d2-b91a-76e0e5d630e1) Traceback (most recent call last):


The count of failed_auth_count table increases every time the command fails.

MariaDB [keystone]> select * from local_user; +----+----------------------------------+-----------+-------+-------------------+---------------------+ | id | user_id | domain_id | name | failed_auth_count | failed_auth_at | +----+----------------------------------+-----------+-------+-------------------+---------------------+ | 1 | 341b75ccdc8a4d56b85b483d03a3cd64 | default | admin | 4 | 2017-06-07 08:45:43 | +----+----------------------------------+-----------+-------+-------------------+---------------------+ 1 row in set (0.00 sec)


edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2017-06-07 06:07:47 -0600

amant gravatar image

While doing hit and trials to resolve this, I amde following changes and it was resolved.

  1. changed hostname to controller2 in /etc/hostname file
  2. corrected password in export OS_PASSWORD= xxxxxx to actual value.
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2017-06-07 04:13:05 -0600

Seen: 705 times

Last updated: Jun 07 '17