[root@controller ~]# openstack service create --name keystone identity
(http://controller:35357/v3/OS-KSADM/services): The resource could not be found. (HTTP 404) (Request-ID: req-0b95528e-2f7c-4b19-872d-a7bde0cb1142)
404报错是找不到请求的网页
先检查wsgi文件是否正确,在查看export变量
我这里是变量写错了是用expot -n 把原来变量删除了在输入一下
export OS_TOKEN=$ADMIN_TOKEN
export OS_URL=http://controller:35357/v3
export OS_IDENTITY_API_VERSION=3
注意大小写!!!
再去创建,成功!
[root@controller conf.d]# openstack service create --name keystone identity
+---------+----------------------------------+
| Field | Value |
+---------+----------------------------------+
| enabled | True |
| id | 079ce7ae7bdd4804ad0f4e75a0aefed9 |
| name | keystone |
| type | identity |
+---------+----------------------------------+