OpenStack Commands Fail With "Expecting to Find Domain in User
Problem
While attempting to execute OpenStack commands from a self-service user using the OpenStack CLI, some of the commands fail with the following error.
Expecting to find domain in user. The server could not comply with the request since it is either malformed or otherwise incorrect. The client is assumed to be in error. (HTTP 400)Environment
Platform9 Managed OpenStack - All Versions
Python-OpenstackClient - 4.0.0
Cause
The .rc downloaded for the self-service user from the Management Plane does not have the OS_USER_DOMAIN_NAME parameter defined.
export OS_AUTH_URL=[Management Plane URL]export OS_IDENTITY_API_VERSION=3export OS_REGION_NAME="[region]"export OS_USERNAME="[username]"export OS_PASSWORD="[password]"export OS_PROJECT_NAME="[Project Name]"export OS_PROJECT_DOMAIN_ID=${OS_PROJECT_DOMAIN_ID:-"default"}Resolution
Check for the user Domain using the following command.
# openstack user list --longAdd the parameter export OS_USER_DOMAIN_NAME=[Domain name] to the RC file. It is mostly default in most of the cases. The entry looks as shown below.
# export OS_USER_DOMAIN_NAME=defaultVerify commands which were previously failing now function as expected.
PreviousInstance Reboot Failure as Libvirt Failed to Terminate qemu-kvm Zombie Process
NextGlance Selects Wrong Endpoint
Last updated
