美文网首页
5 Placement(Rocky)

5 Placement(Rocky)

作者: 找呀找提莫 | 来源:发表于2020-07-19 19:51 被阅读0次

    5.1 说明(略)

    Queen版本之后,Nova不连接这个,起不来;

    5.2 部署Placement

    Controller节点部署

    5.2.1 创建Placement用户

    加载 admin 凭证,来获取管理员命令的执行权限

    source admin-openrc
    

    创建placement用户

    openstack user create --domain default --password-prompt placement
    User Password:placement
    Repeat User Password:placement
    +---------------------+----------------------------------+
    | Field               | Value                            |
    +---------------------+----------------------------------+
    | domain_id           | default                          |
    | enabled             | True                             |
    | id                  | c66b45246ff54d539033869ade06be74 |
    | name                | placement                        |
    | options             | {}                               |
    | password_expires_at | None                             |
    +---------------------+----------------------------------+
    

    placement用户分配 admin 角色,并加入到 service 项目

    openstack role add --project service --user placement admin
    

    创建 placement服务

    openstack service create --name placement --description "Placement API" placement
    +-------------+----------------------------------+
    | Field       | Value                            |
    +-------------+----------------------------------+
    | description | Placement API                    |
    | enabled     | True                             |
    | id          | e74dcfc92bb14d8ca73d67b16f716060 |
    | name        | placement                        |
    | type        | placement                        |
    +-------------+----------------------------------+
    

    创建 placementAPI 端点

    openstack endpoint create --region RegionOne placement public http://controller:8778
    +--------------+----------------------------------+
    | Field        | Value                            |
    +--------------+----------------------------------+
    | enabled      | True                             |
    | id           | 74722a8921ba41e7bf84f924dd7c407e |
    | interface    | public                           |
    | region       | RegionOne                        |
    | region_id    | RegionOne                        |
    | service_id   | e74dcfc92bb14d8ca73d67b16f716060 |
    | service_name | placement                        |
    | service_type | placement                        |
    | url          | http://controller:8778           |
    +--------------+----------------------------------+
    
    openstack endpoint create --region RegionOne placement internal http://controller:8778
    +--------------+----------------------------------+
    | Field        | Value                            |
    +--------------+----------------------------------+
    | enabled      | True                             |
    | id           | 5c4d97c24db749179eeb4e0da964307b |
    | interface    | internal                         |
    | region       | RegionOne                        |
    | region_id    | RegionOne                        |
    | service_id   | e74dcfc92bb14d8ca73d67b16f716060 |
    | service_name | placement                        |
    | service_type | placement                        |
    | url          | http://controller:8778           |
    +--------------+----------------------------------+
    
    openstack endpoint create --region RegionOne placement admin http://controller:8778
    +--------------+----------------------------------+
    | Field        | Value                            |
    +--------------+----------------------------------+
    | enabled      | True                             |
    | id           | 0afc2baea05d433488d20d5b31374bcd |
    | interface    | admin                            |
    | region       | RegionOne                        |
    | region_id    | RegionOne                        |
    | service_id   | e74dcfc92bb14d8ca73d67b16f716060 |
    | service_name | placement                        |
    | service_type | placement                        |
    | url          | http://controller:8778           |
    +--------------+----------------------------------+
    

    5.2.2 安装配置Placement

    yum install -y openstack-nova-placement-api
    

    5.2.3 添加权限

    vim /etc/httpd/conf.d/00-nova-placement-api.conf 
    # 追加
    <Directory /usr/bin>
       <IfVersion >= 2.4>
          Require all granted
       </IfVersion>
       <IfVersion < 2.4>
          Order allow,deny
          Allow from all
       </IfVersion>
    </Directory>
    

    5.3 启动服务

    systemctl restart httpd
    

    相关文章

      网友评论

          本文标题:5 Placement(Rocky)

          本文链接:https://www.haomeiwen.com/subject/okprkktx.html