openstack cmd options not working

Bug #1833097 reported by Peng Peng
This bug report is a duplicate of:  Bug #1833099: nova service cmd not working. Edit Remove
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
StarlingX
Fix Released
High
Frank Miller

Bug Description

Brief Description
-----------------
run opentsack cmd with requested option, but not working

Severity
--------
Critical

Steps to Reproduce
------------------
login to system
run openstack cmd with necessary option

TC-name:

Expected Behavior
------------------
cmd runs out without error

Actual Behavior
----------------
cmd failed by
The request you have made requires authentication. (HTTP 401)

Reproducibility
---------------
Reproducible

System Configuration
--------------------
One node system

Lab-name: SM-2

Branch/Pull Time/Commit
-----------------------
stx master as of 20190616T233000Z

Last Pass
---------
20190612T013000Z

Timestamp/Logs
--------------
openstack --os-username 'tenant1' --os-password 'Li69nux*' --os-project-name tenant1 --os-auth-url http://keystone.openstack.svc.cluster.local/v3 --os-user-domain-name Default --os-project-domain-name Default --os-identity-api-version 3 --os-interface internal --os-region-name RegionOne keypair list'
[2019-06-17 08:54:52,343] 387 DEBUG MainThread ssh.expect :: Output:
The request you have made requires authentication. (HTTP 401) (Request-ID: req-6276c797-f572-4d5b-8589-deb513250391)

controller-0:~$ cat ./openrc.tenant1
unset OS_SERVICE_TOKEN

export OS_ENDPOINT_TYPE=internalURL
export CINDER_ENDPOINT_TYPE=internalURL

export OS_USERNAME=tenant1
export OS_PASSWORD=Li69nux*
export OS_AUTH_TYPE=password
export OS_AUTH_URL=http://keystone.openstack.svc.cluster.local/v3

export OS_PROJECT_NAME=tenant1
export OS_USER_DOMAIN_NAME=Default
export OS_PROJECT_DOMAIN_NAME=Default
export OS_IDENTITY_API_VERSION=3
export OS_REGION_NAME=RegionOne
export OS_INTERFACE=internal

if [ ! -z "${OS_PASSWORD}" ]; then
    export PS1='[\u@\h \W(keystone_$OS_USERNAME)]\$ '
else
    echo 'Openstack Admin credentials can only be loaded from the active controller.'
    export PS1='\h:\w\$ '
fi

Test Activity
-------------
Sanity

Revision history for this message
Peng Peng (ppeng) wrote :
Revision history for this message
Yang Liu (yliu12) wrote :

Note that this issue is only present when tenant auth info are provided via cmdline options as opposed to env variable, this is also not seen when admin auth info are provided in cmd.
i.e.,

# Source works:
source ~/openrc.tenant1; openstack image list

# admin via cmdline works:
openstack --os-username 'admin' --os-password 'Li69nux*' --os-project-name admin --os-auth-url http://keystone.openstack.svc.cluster.local/v3 --os-user-domain-name Default --os-project-domain-name Default --os-identity-api-version 3 --os-interface internal --os-region-name RegionOne image list

# tenant via cmdline does not work:
openstack --os-username 'tenant1' --os-password 'Li69nux*' --os-project-name tenant1 --os-auth-url http://keystone.openstack.svc.cluster.local/v3 --os-user-domain-name Default --os-project-domain-name Default --os-identity-api-version 3 --os-interface internal --os-region-name RegionOne image list

Numan Waheed (nwaheed)
tags: added: stx.retestneeded
Revision history for this message
Ghada Khalil (gkhalil) wrote :

This appears to be related to the openstack client containerization. Likely the same underlying issue as https://bugs.launchpad.net/starlingx/+bug/1833099

tags: added: stx.containers
Changed in starlingx:
assignee: nobody → Frank Miller (sensfan22)
Ghada Khalil (gkhalil)
Changed in starlingx:
importance: Undecided → High
tags: added: stx.sanity
Revision history for this message
Frank Miller (sensfan22) wrote :
Changed in starlingx:
status: New → Fix Released
Ghada Khalil (gkhalil)
tags: added: stx.2.0
Peng Peng (ppeng)
tags: removed: stx.retestneeded
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.