1. Home
  2. Linux
  3. [OpenStack]: from keystoneclient.shell import main ImportError: No module named shell
  1. Home
  2. OpenStack
  3. [OpenStack]: from keystoneclient.shell import main ImportError: No module named shell

[OpenStack]: from keystoneclient.shell import main ImportError: No module named shell

During one node installation of OpenStack Kilo, I tried creating a tenant and the keystone service failed with an error as shown below:

root@cloudsec1:/usr/share/openstack/cloudgear# keystone tenant-create --name admin --description 'Admin Tenant' --enabled true |grep ' id '|awk '{print $4}'
Traceback (most recent call last):
  File "/usr/bin/keystone", line 6, in 
    from keystoneclient.shell import main
ImportError: No module named shell

It seems to be a Python error. I am uninstalling Kilo on Ubuntu 16.04 LTS. Please suggest any solution.

Solution: Keystone CLI is deprecated in favor of openstackclient. So open the file /usr/bin/keystone and replace keystoneclient with openstackclient as shown below:

from keystoneclient.shell import main

to

from openstackclient.shell import main

You might also love to download this ebook on OpenStack Installation.


Related Content
Updated on September 2, 2017

Was this article helpful?

Related Articles

Add A Comment