OpenStack's basic Environment preparation (L version)

Source: Internet
Author: User
Tags symlink rabbitmq chrony

centos7.1 OpenStack L version, environmental planning as follows

[[email protected] ~]# ansible web -a  ' hostname ' 172.16.80.131 |  Success | rc=0 >>computer1172.16.80.130 | success | rc=0 > >controller[[email protected] ~]# ansible web -a  ' cat /etc/hosts ' 172.16.80.131 | success | rc=0 >>127.0.0.1   localhost  localhost.localdomain localhost4 localhost4.localdomain4::1          localhost localhost.localdomain localhost6  localhost6.localdomain6172.16.80.130 controller172.16.80.131 computer1172.16.80.130 |  success | rc=0 >>127.0.0.1   localhost localhost.localdomain  Localhost4 localhost4.localdomain4::1         localhost  localhost.localdomain localhost6 localhost6.localdomain6172.16.80.130 controller172.16.80.131 computer1 


1, Configuration Time synchronization

[[email protected] ~]# ansible web-a ' yum install chrony-y '


Modify the controller above

[Email protected] ~]# vim/etc/chrony.conf

Allow 172.16.80.0/24


[Email protected] ~]# Systemctl enable Chronyd.service

[Email protected] ~]# systemctl start Chronyd.service

[[email protected] ~]# ansible web-a ' Date '

172.16.80.130 | SUCCESS | Rc=0 >>

Sat Oct 21:31:36 CST 2016


172.16.80.131 | SUCCESS | Rc=0 >>

Sat Oct 21:31:36 CST 2016


[[email protected] ~]# ansible web-a ' timedatectl set-timezone Asia/shanghai ' Set time zone


2. Installing the OpenStack Source

[email protected] ~]# Yum install centos-release-openstack-liberty-y

[email protected] ~]# Yum install https://rdoproject.org/repos/openstack-liberty/rdo-release-liberty.rpm-y


3. Install the database and configure

[email protected] ~]# Yum install mariadb mariadb-server mysql-python-y

[Email protected] ~]# VIM/ETC/MY.CNF

[Mysqld]

Default-storage-engine = InnoDB

Innodb_file_per_table

Collation-server = Utf8_general_ci

Init-connect = ' SET NAMES UTF8 '

Character-set-server = UTF8


[Email protected] ~]# Systemctl enable Mariadb.service

Created symlink From/etc/systemd/system/multi-user.target.wants/mariadb.service to/usr/lib/systemd/system/ Mariadb.service.

[Email protected] ~]# systemctl start Mariadb.service


4. Database creation and authorization

mariadb [(None)]> create database keystone; query ok, 1 row affected  (0.00 sec) mariadb [(none)]> GRANT ALL  PRIVILEGES ON keystone.* TO  ' keystone ' @ ' localhost '  IDENTIFIED BY  ' Keystone '; query ok, 0 rows affected  (0.00 sec) mariadb [(none)]> GRANT  all privileges on keystone.* to  ' keystone ' @ '% '  IDENTIFIED BY  ' Keystone ‘; query ok, 0 rows affected  (0.00 sec) mariadb [(none)]> CREATE  database glance; query ok, 1 row affected  (0.00 sec) mariadb [(none)]> GRANT ALL  PRIVILEGES ON glance.* TO  ' glance ' @ ' localhost '  IDENTIFIED BY  ' glance ' ; query ok, 0 rows affected  (0.00 sec) mariadb [(none)]> GRANT  all privileges on glance.* to  ' glance ' @ '% '  IDENTIFIED BY  ' glance '; query ok, 0 rows affected  (0.00 sec) mariadb [(none)]> CREATE  database nova; query ok, 1 row affected  (0.00 sec) mariadb [(none)]> GRANT ALL  PRIVILEGES ON nova.* TO  ' nova ' @ ' localhost '  IDENTIFIED BY  ' Nova '; query ok, 0 rows affected  (0.00 sec) mariadb [(none)]> GRANT  all privileges on nova.* to  ' Nova ' @ '% '  IDENTIFIED BY  ' Nova '; query ok, 0 rows affected  (0.00 sec) mariadb [(none)]> CREATE  database neutron; query ok, 1 row affected  (0.00 sec) mariadb [(none)]> GRANT ALL  PRIVILEGES ON neutron.* TO  ' neutron ' @ ' localhost '  IDENTIFIED BY  ' Neutron '; Query ok, 0 rows affected  (0.00 sec) mariadb [(none)]> grant all  privileges on neutron.* to  ' neutron ' @ '% '  IDENTIFIED BY  ' neutron '; query ok, 0 rows affected  (0.00 sec) mariadb [(none)]> CREATE  database cinder; query ok, 1 row affected  (0.00 sec) mariadb [(none)]> GRANT ALL  PRIVILEGES ON cinder.* TO  ' cinder ' @ ' localhost '  IDENTIFIED BY  ' cinder ' ; query ok, 0 rows affected  (0.00 sec) mariadb [(none)]> GRANT  all privileges on cinder.* to  ' cinder ' @ '% '  IDENTIFIED BY  ' cinder '; query ok, 0 rows affected  (0.00 SEC)


5. Install Message Queuing, add user authorization

[email protected] ~]# Yum install rabbitmq-server-y


[Email protected] ~]# Systemctl enable Rabbitmq-server.service

Created symlink From/etc/systemd/system/multi-user.target.wants/rabbitmq-server.service To/usr/lib/systemd/system /rabbitmq-server.service.

[Email protected] ~]# systemctl start Rabbitmq-server.service

[Email protected] ~]# rabbitmqctl add_user OpenStack OpenStack

Creating user "OpenStack" ...

[Email protected] ~]# rabbitmqctl set_permissions openstack ". *" ". *" ". *"

Setting permissions for the user "OpenStack" in Vhost "/" ...


[Email protected] ~]# rabbitmq-plugins list

Configured:e = explicitly enabled; E = implicitly enabled

| Status: [Failed to contact [e-mail protected]-status not shown]

|/

[] Amqp_client 3.6.5

[] Cowboy 1.0.3

[] Cowlib 1.0.1

[] Mochiweb 2.13.1

[] Rabbitmq_amqp1_0 3.6.5

[] Rabbitmq_auth_backend_ldap 3.6.5

[] Rabbitmq_auth_mechanism_ssl 3.6.5

[] Rabbitmq_consistent_hash_exchange 3.6.5

[] Rabbitmq_event_exchange 3.6.5

[] Rabbitmq_federation 3.6.5

[] Rabbitmq_federation_management 3.6.5

[] Rabbitmq_jms_topic_exchange 3.6.5

[] Rabbitmq_management 3.6.5

[] Rabbitmq_management_agent 3.6.5

[] Rabbitmq_management_visualiser 3.6.5

[] Rabbitmq_mqtt 3.6.5

[] Rabbitmq_recent_history_exchange 1.2.1

[] rabbitmq_sharding 0.1.0

[] Rabbitmq_shovel 3.6.5

[] Rabbitmq_shovel_management 3.6.5

[] Rabbitmq_stomp 3.6.5

[] Rabbitmq_top 3.6.5

[] rabbitmq_tracing 3.6.5

[] Rabbitmq_trust_store 3.6.5

[] Rabbitmq_web_dispatch 3.6.5

[] Rabbitmq_web_stomp 3.6.5

[] Rabbitmq_web_stomp_examples 3.6.5

[] Sockjs 0.3.4

[] Webmachine 1.10.3


[Email protected] ~]# Rabbitmq-plugins enable rabbitmq_management

The following plugins has been enabled:

Mochiweb

Webmachine

Rabbitmq_web_dispatch

Amqp_client

Rabbitmq_management_agent

Rabbitmq_management


Applying plugin configuration to [email protected] started 6 plugins.


[Email protected] ~]# systemctl restart Rabbitmq-server.service

[Email protected] ~]# Netstat-lntup |grep 5672

650) this.width=650; "src=" Http://s4.51cto.com/wyfs02/M00/89/7B/wKiom1gUusbiqsg1AAA4tQrwl1o169.png "title=" 1.png " alt= "Wkiom1guusbiqsg1aaa4tqrwl1o169.png"/>


Access Test http://172.16.80.130:15672/Default user name password Guest/guest

650) this.width=650; "src=" Http://s1.51cto.com/wyfs02/M01/89/79/wKioL1gUuV3AjRkmAAEyyNU8kok800.png "title=" 1.png " alt= "Wkiol1guuv3ajrkmaaeyynu8kok800.png"/>

Role is set to Administrator, and the password for OpenStack is set

650) this.width=650; "src=" Http://s4.51cto.com/wyfs02/M02/89/79/wKioL1gUupiAhcVHAADHyRQrwrY680.png "title=" 1.png " alt= "Wkiol1guupiahcvhaadhyrqrwry680.png"/>

This article from "Thick tak" blog, declined reprint!

OpenStack's basic Environment preparation (L version)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.