3.1 keystone
安装linux-node1上面
3.2 配置源
http://mirrors.aliyun.com/centos/7.2.1511/cloud/x86_64/openstack-newton/centos-release-openstack-newton-1-1.el7.noarch.rpm yumlocalinstall -y centos-release-openstack-newton-1-1.el7.noarch.rpm
安装:
yuminstall -y openstack-keystone httpd mod_wsgi memcached python-memcached python-openstackclient
3.3 配置认证机制和数据库连接
[[email protected]~]# openssl rand -hex 10 #生成token 0eed56d434cbac30394c [[email protected]~]# grep -E "^[a-Z]" /etc/keystone/keystone.conf #修改如下的位置 admin_token= 0eed56d434cbac30394c connection= mysql://keystone:[email protected]/keystone [[email protected]~]#
3.4 生成keystone的数据表和日志
su -s/bin/sh -c "keystone-manage db_sync" keystone 作用:初始化数据库(keystone)的表结构和生成keystone的日志文件 [[email protected] ~]# ll /var/log/keystone/keystone.log -rw-rw---- 1 keystone keystone 16296 Dec 17 16:39 /var/log/keystone/keystone.log #keystone启动会向这个文件写入东西,所以是keystone用户来生成否则启动不起来
3.5查看keystone初始化的数据库
[[email protected] ~]# mysql -h 192.168.56.11 -ukeystone -pkeystone -e "use keystone;show tables;" +------------------------+ | Tables_in_keystone | +------------------------+ | access_token | | assignment | | config_register | | consumer | | credential | | endpoint | | endpoint_group | | federated_user | | federation_protocol | | group | | id_mapping | | identity_provider | | idp_remote_ids | | implied_role | | local_user | | mapping | | migrate_version | | nonlocal_user | | password | | policy | | policy_association | | project | | project_endpoint | | project_endpoint_group | | region | | request_token | | revocation_event | | role | | sensitive_config | | service | | service_provider | | token | | trust | | trust_role | | user | | user_group_membership | | whitelisted_config |
时间: 2024-10-10 04:32:33