码迷,mamicode.com
首页 > Windows程序 > 详细

keystone的兼容API

时间:2018-05-20 14:23:36      阅读:1576      评论:0      收藏:0      [点我收藏+]

标签:domain   使用   com   mil   details   3.0   不同   http   error   

来源自 https://blog.csdn.net/milankaka22/article/details/50913406

Error:

Expecting to find domain in project. 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) (Request-ID: req-84bd7283-6fd4-4623-9480-5f3c74177820)

keystone服务在启动的时候,会加载v2.0与v3的API,v3 API增加了domain的概念,两个版本可以同时存在

在使用client的时候,也有不同了,在CLI client里,keystone命令,只能支持V2.0版本API的访问,而openstack cli可以同时支持v2.0与v3.0。

我的环境变量文件如下:

export OS_AUTH_URL=http://192.168.57.3:35357/v3
export OS_USERNAME=admin
export OS_PASSWORD=openstack
export OS_PROJECT_NAME=admin

使用keystone cli会出错,但如果OS_AUTH_URL是v2.0,那就没问题了。

但是使用openstack cli访问时,也出错,错误信息如下:

Expecting to find domain in project - 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) (Request-ID: req-b100e261-a02a-4dc0-9dbf-d7ee20a215cc)

那是V3的一个特点,需要再设置以下的环境变量才可以:

export OS_USER_DOMAIN_NAME=Default

export OS_PROJECT_DOMAIN_NAME=Default

keystone的兼容API

标签:domain   使用   com   mil   details   3.0   不同   http   error   

原文地址:https://www.cnblogs.com/dragonfy/p/9063126.html

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