• OpenStack


    'NoneType' object has no attribute 'service_catalog' 报错

    编辑:/etc/keystone/keystone-paste.ini
    在[pipeline:public_api], [pipeline:admin_api], and [pipeline:api_v3] 三个地方
    移走:admin_token_auth

    为了安全设置,需要移除认证中的 token相关的认证,可以移除之后,使用admin进行验证的时候报错:

    [root@controller01 ~]# openstack --os-auth-url http://controller01:35357/v3 --os-project-domain-name default --os-user-domain-name default --os-project-name admin --os-username admin token 
    issue'NoneType' object has no attribute 'service_catalog'
    

    研究后发现是之前在使用token的时候,定义了系统的环境变量,移除后再试就好了:
    操作如下:

    [root@controller01 ~]# unset OS_TOKEN
    [root@controller01 ~]# unset OS_URL
    [root@controller01 ~]# unset OS_IDENTITY_API_VERSION
    [root@controller01 ~]# echo ${OS_TOKEN}
    
    [root@controller01 ~]# openstack --os-auth-url http://controller01:35357/v3 --os-project-domain-name default --os-user-domain-name default --os-project-name admin --os-username admin token 
    issuePassword: 
    +------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
    | Field      | Value                                                                                                                                                                        |
    +------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
    | expires    | 2018-09-20T05:56:24.000000Z                                                                                                                                                  |
    | id         | gAAAAABboyh4wJ_l0suMnuQCThCwAF2xLWD5Yl5_HjhHuAa5lkTC5JK8eC8-Hli4olfo3XIlR0AulIbC46r-                                                                                         |
    |            | tsq6WgRjpa65RrD_6rtCL_gigsIXRRUEBFR1apJiiE8SE_KSIInLqd9SCui4lje2s9i__RcnTA6JPGwkN9BXYjcfpjAkZHgNHtY                                                                          |
    | project_id | cec3ca49340b4d15b623edff7234cfe5                                                                                                                                             |
    | user_id    | 217f8594d6574801b7c52a56cf0a9a51                                                                                                                                             |
    +------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
    
  • 相关阅读:
    FileReader:读取本地图片文件并显示
    uploadfy插件结合php案例
    php 生成二维码,图片上传到又拍云
    php get/post 请求(可用于请求api)获取手机号码归属地
    php中curl的详细解说
    聊聊Web App、Hybrid App与Native App的设计差异
    我的前端之路
    使用angular.js开发的一个简易todo demo
    在线个人简历(续)
    在线个人简历
  • 原文地址:https://www.cnblogs.com/winstom/p/9680204.html
Copyright © 2020-2023  润新知