4,控制节点安装Keystone

4.1 创建Keystone相关数据库

mysql -uroot -pabc-123
---
create database keystone;
grant all privileges on keystone.* to 'keystone'@'localhost' identified by 'keystone';
grant all privileges on keystone.* to 'keystone'@'%' identified by 'keystone';
flush privileges;
exit

4.2 安装配置Keystone

4.2.1 安装Keystone

yum install httpd mod_wsgi openstack-keystone python-keystoneclient openstack-utils python-openstackclient openstack-selinux -y

4.2.2 配置Keystone

openstack-config --set /etc/keystone/keystone.conf database connection mysql+pymysql://keystone:keystone@controller/keystone
openstack-config --set /etc/keystone/keystone.conf token provider fernet
---
grep '^[a-z]' /etc/keystone/keystone.conf

4.3 初始化Keystone数据库

4.3.1 同步Keystone数据库

su -s /bin/sh -c "keystone-manage db_sync" keystone

4.3.2 验证数据库

mysql -h127.0.0.1 -ukeystone -pkeystone -e "use keystone;show tables;"

4.4 初始化Fernet令牌库

keystone-manage fernet_setup --keystone-user keystone --keystone-group keystone
keystone-manage credential_setup --keystone-user keystone --keystone-group keystone

4.5 配置启动Apache

4.5.1 修改Apache配置文件

sed  -i  "s/#ServerName www.example.com:80/ServerName controller/" /etc/httpd/conf/httpd.conf

4.5.2 配置虚拟主机

ln -s /usr/share/keystone/wsgi-keystone.conf /etc/httpd/conf.d/

4.5.3 启动并且配置自启动

systemctl start httpd.service
systemctl status httpd.service
systemctl enable httpd.service

4.6 初始化Keystone认证服务

4.6.1 创建Keystone用户

keystone-manage bootstrap --bootstrap-password abc-123 --bootstrap-admin-url http://controller:5000/v3/  --bootstrap-internal-url http://controller:5000/v3/  --bootstrap-public-url http://contro
  • 1
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值