标签:配置 serve 数据库配置 RoCE com def selinux bfd server
1.关闭防火墙和selinux[root@compute ~]# cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
20.0.20.21 controller
20.0.20.22 compute
yum -y install chrony
[root@controller ~]# vim /etc/chrony.conf
allow 20.0.20.0/16
server ntp1.aliyun.com iburst
#compute节点只需同步到controller节点
[root@controller ~]# systemctl enable chronyd.service
[root@controller ~]# systemctl start chronyd.service
[root@controller ~]# yum install centos-release-openstack-pike -y
[root@controller ~]# yum upgrade
[root@controller ~]# yum install python-openstackclient -y
[root@controller ~]# yum install mariadb mariadb-server python2-PyMySQL -y
[root@controller ~]# cat /etc/my.cnf.d/openstack.cnf
[mysqld]
bind-address = 20.0.20.21
default-storage-engine = innodb
innodb_file_per_table
max_connections = 4096
collation-server = utf8_general_ci
character-set-server = utf8
[root@controller ~]# systemctl enable mariadb.service
[root@controller ~]# systemctl start mariadb.service
[root@controller ~]# mysql_secure_installation
mysql -u root -p
create database keystone;
grant all privileges on keystone.* to ‘keystone‘@‘localhost‘ identified by ‘keystone‘;
grant all privileges on keystone.* to ‘keystone‘@‘%‘ identified by ‘keystone‘;
grant all privileges on keystone.* to ‘keystone‘@‘controller‘ identified by ‘keystone‘;
create database glance;
grant all privileges on glance.* to ‘glance‘@‘localhost‘ identified by ‘glance‘;
grant all privileges on glance.* to ‘glance‘@‘%‘ identified by ‘glance‘;
grant all privileges on glance.* to ‘glance‘@‘controller‘ identified by ‘glance‘;
create database nova;
grant all privileges on nova.* to ‘nova‘@‘localhost‘ identified by ‘nova‘;
grant all privileges on nova.* to ‘nova‘@‘%‘ identified by ‘nova‘;
grant all privileges on nova.* to ‘nova‘@‘controller‘ identified by ‘nova‘;
create database nova_api;
grant all privileges on nova_api.* to ‘nova‘@‘localhost‘ identified by ‘nova‘;
grant all privileges on nova_api.* to ‘nova‘@‘%‘ identified by ‘nova‘;
grant all privileges on nova_api.* to ‘nova‘@‘controller‘ identified by ‘nova‘;
create database nova_cell0;
grant all privileges on nova_cell0.* to ‘nova‘@‘localhost‘ identified by ‘nova‘;
grant all privileges on nova_cell0.* to ‘nova‘@‘%‘ identified by ‘nova‘;
grant all privileges on nova_cell0.* to ‘nova‘@‘controller‘ identified by ‘nova‘;
create database neutron;
grant all privileges on neutron.* to ‘neutron‘@‘localhost‘ identified by ‘neutron‘;
grant all privileges on neutron.* to ‘neutron‘@‘%‘ identified by ‘neutron‘;
grant all privileges on neutron.* to ‘neutron‘@‘controller‘ identified by ‘neutron‘;
flush privileges;
MariaDB [(none)]> select user,host from mysql.user;
+----------+------------+
| user | host |
+----------+------------+
| glance | % |
| keystone | % |
| neutron | % |
| nova | % |
| root | 127.0.0.1 |
| root | ::1 |
| glance | controller |
| keystone | controller |
| neutron | controller |
| nova | controller |
| root | controller |
| glance | localhost |
| keystone | localhost |
| neutron | localhost |
| nova | localhost |
| root | localhost |
+----------+------------+
16 rows in set (0.00 sec)
MariaDB [(none)]> show databases;
+--------------------+
| Database |
+--------------------+
| glance |
| information_schema |
| keystone |
| mysql |
| neutron |
| nova |
| nova_api |
| nova_cell0 |
| performance_schema |
+--------------------+
9 rows in set (0.00 sec)
[root@controller ~]# yum install rabbitmq-server -y
[root@controller ~]# systemctl enable rabbitmq-server.service
[root@controller ~]# systemctl start rabbitmq-server.service
[root@controller ~]# rabbitmqctl add_user openstack openstack
Creating user "openstack" ...
[root@controller ~]# rabbitmqctl set_permissions openstack ".*" ".*" ".*"
Setting permissions for user "openstack" in vhost "/" ...
[root@controller ~]# rabbitmq-plugins enable rabbitmq_management
[root@controller ~]# lsof -i:15672
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
beam.smp 3162 rabbitmq 54u IPv4 449707 0t0 TCP *:15672 (LISTEN)
#访问RabbitMQ,访问地址是http://ip:15672
#默认用户名密码都是guest,浏览器添加openstack用户到组并登陆测试
[root@controller ~]# yum install memcached python-memcached -y
[root@controller ~]# systemctl enable memcached.service
[root@controller ~]# systemctl start memcached.service
OpenStack Pike Minimal安装:一、环境准备
标签:配置 serve 数据库配置 RoCE com def selinux bfd server
原文地址:http://blog.51cto.com/lullaby/2169524