码迷,mamicode.com
首页 > 其他好文 > 详细

openstack kilo 命令行

时间:2019-04-24 17:25:03      阅读:153      评论:0      收藏:0      [点我收藏+]

标签:ror   and   解释   related   version   token   windows   sql   username   

把下面内容放到.bashrc中,或者直接执行也行。

export OS_USERNAME=admin
export OS_PASSWORD=admin              #根据实际密码来设   
export OS_PROJECT_NAME=admin
export OS_AUTH_URL=http://localhost:35357/v2.0
export OS_IDENTITY_API_VERSION=2
export OS_TENANT_ID=06bb27f1c72d46b38fabd62cb1ee6d5c   #这个获取方法见下文

 

通过查询数据库可获得auth_url 与 tenant_id

mysql -u root
show databases;
use keystone;
show tables;
select * from endpoint;

会看到http://10.0.3.41:35357/v2.0

select * from token;

会看到tenant,找到id, 这里是06bb27f1c72d46b38fabd62cb1ee6d5c

 

问题:

如果在导出时导出了

export OS_USER_DOMAIN_NAME=Default
export OS_PROJECT_DOMAIN_NAME=Default

执行nova命令会出现下面错误:

ERROR (DiscoveryFailure): Could not determine a suitable URL for the plugin

详细解释及参考链接:https://ask.openstack.org/en/question/80400/using-nova-client-in-windows-error-discoveryfailure-could-not-determine-a-suitable-url-for-the-plugin/

This error is related to the version of Keystone API you‘re using. As noted in https://bugs.launchpad.net/python-openstackclient/+bug/1447704 (this open bug report), it does not work when using an OS_AUTH_URL ending in "v2.0" and the variables OS_PROJECT_DOMAIN_ID and OS_USER_DOMAIN_ID are set.

The workaround is to remove the variables OS_PROJECT_DOMAIN_ID and OS_USER_DOMAIN_ID if you wish to use v2 of the Keystone API.

openstack kilo 命令行

标签:ror   and   解释   related   version   token   windows   sql   username   

原文地址:https://www.cnblogs.com/longchang/p/10763539.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!