Failed to discover available identity versions when contacting http://192.168.1.225:5000/v3. Attempting to parse version from URL. Unable to establish connection to http://192.168.1.225:5000/v3/auth/tokens

asked 2020-02-25 20:37:03 -0600

vincent.see gravatar image

updated 2020-02-27 23:32:20 -0600

Hi,

I had just tried to installed openstack Train version on Ubuntu 18.04.4 on a virtualbox. I can login into horizon dashboard with the admin user on my host machine, as well as SSH into it with stack user. however when i try to issue any openstack CLI commands, i am faced with the above-mentioned error.

Details of admin-openrc file: Export OS_USERNAME=admin Export OS_PASSWORD=** Export OS_PROJECT_NAME=admin Export OS_USER_DOMAIN_NAME=Default Export OS_PROJECT_DOMAIN_NAME=Default Export OS_AUTH_URL=http://192.168.1.225:5000/v3 Export OS_IDENTITY_API_VERSION=3 Export OS_IMAGE_API-VERSION=2

i have sourced from the admin-openrc file. and below are the steps that I had performed with output.

stack@controller:~$ keystone-manage --version
16.1.0

stack@controller:~$ sudo lsof -i -P -n | grep LISTEN
systemd-r  719 systemd-resolve   13u  IPv4  15337      0t0  TCP 127.0.0.53:53 (LISTEN)
uwsgi      802           stack    4u  IPv4  21142      0t0  TCP 127.0.0.1:37789 (LISTEN)
uwsgi      802           stack    5u  IPv4  21143      0t0  TCP *:8775 (LISTEN)
/usr/bin/  803           stack    5u  IPv4  32358      0t0  TCP *:9696 (LISTEN)
/usr/bin/  816           stack    7u  IPv4  32818      0t0  TCP 127.0.0.1:6633 (LISTEN)
uwsgi      900           stack    4u  IPv4  21737      0t0  TCP 127.0.0.1:60999 (LISTEN)
nova-novn  913           stack    3u  IPv4  31689      0t0  TCP *:6080 (LISTEN)
ovsdb-ser 1041            root   19u  IPv4  21645      0t0  TCP 127.0.0.1:6640 (LISTEN)
etcd      1220            root    5u  IPv6  27191      0t0  TCP *:2380 (LISTEN)
etcd      1220            root    6u  IPv4  27192      0t0  TCP 192.168.1.225:2379 (LISTEN)
memcached 1230        memcache   26u  IPv4  25114      0t0  TCP 127.0.0.1:11211 (LISTEN)
tgtd      1253            root    6u  IPv4  24941      0t0  TCP *:3260 (LISTEN)
tgtd      1253            root    7u  IPv6  24942      0t0  TCP *:3260 (LISTEN)
sshd      1254            root    3u  IPv4  24924      0t0  TCP *:22 (LISTEN)
sshd      1254            root    4u  IPv6  24929      0t0  TCP *:22 (LISTEN)
apache2   1578            root    4u  IPv6  25355      0t0  TCP *:80 (LISTEN)
apache2   1582        www-data    4u  IPv6  25355      0t0  TCP *:80 (LISTEN)
apache2   1583        www-data    4u  IPv6  25355      0t0  TCP *:80 (LISTEN)
epmd      1597        rabbitmq    3u  IPv4  26004      0t0  TCP *:4369 (LISTEN)
epmd      1597        rabbitmq    4u  IPv6  26005      0t0  TCP *:4369 (LISTEN)
mysqld    1604           mysql   20u  IPv4  27146      0t0  TCP *:3306 (LISTEN)
uwsgi     1844           stack    4u  IPv4  21142      0t0  TCP 127.0.0.1:37789 (LISTEN)
uwsgi     1845           stack    4u  IPv4  21142      0t0  TCP 127.0.0.1:37789 (LISTEN)
uwsgi     1846           stack    5u  IPv4  21143      0t0  TCP *:8775 (LISTEN)
uwsgi     1847           stack    4u  IPv4  21737      0t0  TCP 127.0.0.1:60999 (LISTEN)
uwsgi     1848           stack    4u  IPv4  21737      0t0  TCP 127.0.0.1:60999 (LISTEN)
beam.smp  2033        rabbitmq   44u  IPv4  28241      0t0  TCP *:25672 (LISTEN)
beam.smp  2033        rabbitmq   54u  IPv6  28688      0t0  TCP *:5672 (LISTEN)
dnsmasq   2086 libvirt-dnsmasq    6u  IPv4  28051      0t0  TCP 192.168.122.1:53 (LISTEN)
/usr/bin/ 2811           stack    5u  IPv4  32358      0t0  TCP *:9696 (LISTEN)
/usr/bin/ 2811           stack    7u  IPv4  32358      0t0  TCP *:9696 (LISTEN)
/usr/bin/ 2812           stack    5u  IPv4  32358      0t0  TCP *:9696 (LISTEN ...
(more)
edit retag flag offensive close merge delete

Comments

Check if Keystone is running. Look for Apache errors relative to Keystone. Check if anything (VirtualBox, firewall, ...) blocks traffic to 192.168.1.225:35357.

Bernd Bausch gravatar imageBernd Bausch ( 2020-02-26 17:21:25 -0600 )edit

I have tried to check if keystone is running, but are stuck. below are the steps that I tried to perform and the output: stack@controller:~$ keystone-manage --version 16.1.0 stack@controller:~$ sudo lsof -i -P -n | grep LISTEN --no ports listening on 5000 and 35357 -output too long, unable to paste

vincent.see gravatar imagevincent.see ( 2020-02-26 20:15:36 -0600 )edit

The openstack server are not listening to either port 5000 nor 35357. stack@controller:~$ sudo service keystone status Unit keystone.service could not be found. stack@controller:~$ ps -ef | grep keystone stack 916 1 0 02:08 ? 00:00:00 keystoneuWSGI master stack 1924 916 0 02

vincent.see gravatar imagevincent.see ( 2020-02-26 20:16:16 -0600 )edit

But my analyse is that since I am able to login into horizon dashboard as admin and demo user, shouldn't keystone identity service already have been running to support my login authentication via the http apache2 service??

vincent.see gravatar imagevincent.see ( 2020-02-26 20:21:46 -0600 )edit

I had also tried to go into the keystone database to add privileges and restarted the keystone service. However still not able to get it working on CLI. mysql> grant all privileges on keystone.* TO 'admin'@'192.168.1.225' identified by 'password';

vincent.see gravatar imagevincent.see ( 2020-02-26 20:27:07 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2020-02-28 02:42:40 -0600

vincent.see gravatar image

Log in as admin using horizon, and go to the right top counter to download the admin-openrc.sh file. ssh into the controller as stack and create a new openrc file, and duplicate the content of the downloaded file into it. then source from this openrc, and you will get authenticated.

Sample of my admin-openrc.sh file (Your's might differs slightly from mine due to different project ID and IP address used)

export OS_AUTH_URL=http://192.168.1.31/identity
export OS_PROJECT_ID=5e387bf21b4d4bddb1790829f576a91f
export OS_PROJECT_NAME="admin"
export OS_USER_DOMAIN_NAME="Default"
if [ -z "$OS_USER_DOMAIN_NAME" ]; then unset OS_USER_DOMAIN_NAME; fi
export OS_PROJECT_DOMAIN_ID="default"
if [ -z "$OS_PROJECT_DOMAIN_ID" ]; then unset OS_PROJECT_DOMAIN_ID; fi
unset OS_TENANT_ID
unset OS_TENANT_NAME
export OS_USERNAME="admin"
echo "Please enter your OpenStack Password for project $OS_PROJECT_NAME as user $OS_USERNAME: "
read -sr OS_PASSWORD_INPUT
export OS_PASSWORD=$OS_PASSWORD_INPUT
export OS_REGION_NAME="RegionOne"
if [ -z "$OS_REGION_NAME" ]; then unset OS_REGION_NAME; fi
export OS_INTERFACE=public
export OS_IDENTITY_API_VERSION=3
edit flag offensive delete link more

Comments

I see two different ip's http://192.168.1.225:5000/v3 and http://192.168.1.31/identity , Can you update the following param in admin-openrc.sh file export OS_AUTH_URL=http://192.168.1.31/identity to export OS_AUTH_URL=http://192.168.1.225:5000/v3

Mohit gravatar imageMohit ( 2020-02-28 09:13:49 -0600 )edit

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2020-02-25 20:35:27 -0600

Seen: 319 times

Last updated: Feb 28