OpenStack Stein installation (1)

OpenStack stein installation (1)

Environment:

? 192.168.205.7: as Chrony, DNS and YUM Source server (for faster installation, build your own yum source)
? 192.168.205.147: as DataBase, install MariaDB, RabbitMQ, Memcached
? 192.168.205.167: as controller, install keystone, placement, nova, neutron, dashboard
? 192.168.205.187: as compute node, install neutron agent and nova agent
Note: All operating systems are disabled by default firewalld, iptable is empty, close selinux

Version:

? OS: centos 7 1810 with mini install for controller and SQL server
? OS: CentOS 7 1511 with mini install for compute node
? Openstack Minimal deployment for Stein
? mariadb-10.3.10
Note: Others not specified are yum installations

Destination:

? Minimize the installation of the latest version of openstack stein
? After the installation is complete, the components will run normally.
? The test is successfully established and run.
? The basic network functions are tested by running the test.

Steps:

1. Pre-installation environment preparation
2. Install keystone
3. Install glance image service
4. Install placement< br />5. Install Nova on controller
6. Install Nova on compute node
7. Install Neutron on controller node
8. Install Neutron on compute node
9. Install dashboard
10. Verification test

Environment preparation before installation

Preparation for installation is very important, because there are many openstack services, and the dependencies between services are close. Reasonable planning will not lead to installation problems, otherwise various problems will occur.

Prepare the environment

  1. The time of all servers must be the same. We set the time service synchronization. This can be an external source or our own time source server. I use A chrony server serves as a time server, and Tongjin also serves as dns resolution and yum source
    #yum install chrony
    #systemctl start chronyd
    #cat /etc/chrony.conf
    server 192.168.205.7 iburst
    #systemctl status chronyd
    #chronyc sources -v #Check if the chrony time is synchronized, see ^* is synchronized, otherwise there is no synchronization
  2. Modify the hosts file and copy the hosts file to the three servers. If dns is used, this step is not necessary, but do not configure the host name.
    #cat /etc/hosts
    192.168.205.167 controller1
    192.168.205.147 master
    192.168.205.187 node1
  3. Planning for DNS domain name resolution
    Domain name: flex.net
    name server 192.168.205.7
    A stack.flex.net 192.168.205.167 controller1
    A dbs.flex.net 192.168.205.147 database, memcached, rabbitMQ< br />Tongjin DNS is also used as a forwarding server to install software for yum.
  4. Edit the network card each has three network cards, divided into management network, tenant network and external network, management network dns points to 192.168.205.7
    eth0 is the management and API network
    #cat ifcfg-eth0
    NAME="eth0"
    DEVICE="eth0"
    ONBOOT=yes< br />BOOTPROTO=static
    IPADDR=192.168.205.x
    NETMASK=255.255.255.0
    TYPE=Ethernet
    eth1 is used by tenant tenant network, without IP, set to none
    #cat ifcfg-eth1
    NAME="eth1"
    DEVICE="eth1"
    ONBOOT=yes
    BOOTPROTO=none
    eth2 is installed on the external network Use yum source, use nat method, and set dns to the dns of the intranet: 192.168.205.7
    #cat ifcfg-eth2
    NAME="eth2"
    DEVICE="eth2"
    ONBOOT=yes
    BOOTPROTO=static
    IPADDR=172.18.18.x
    NETMASK=255.255.255.0
    GATEWAY=172.18.18.2
    DNS1=192.168.205.7
    Note: Do not modify HWADDR and UUID< /pre>
  5. Install the source, first enable extras packges, I use the source that comes with the original cenos installation, you can also enable the extras source of aliyun or tinghua

    #ls 
    backup CentOS-Base.repo CentOS-Debuginfo.repo CentOS-Media.repo CentOS-Vault.repo
    backup1 CentOS-CR.repo CentOS-fasttrack.repo CentOS-Sources.repo
    # yum list Centos-release-OpenStack*

    Available Packages
    centos-release-openstack-stein.noarch 1-1.el7.centos extras
    centos-release-openstack- ocata.noarch 1-2.el7 extras
    centos-release-openstack-pike.x86_64 1-1.el7 extras
    centos-release-openstack-queens.noarch 1-2.el7.centos extras < br />
    Note: We need to disable the epel source during installation
  6. We use yum to directly download and install the latest stein source
    #yum install centos-release-openstack -stein
  7. After the installation is complete, we see some more sources in the directory

    #ls
    backup CentOS-Debuginfo.repo Ce ntOS-QEMU-EV.repo
    backup1 CentOS-fasttrack.repo CentOS-Sources.repo
    CentOS-Base.repo CentOS-Media.repo CentOS-Storage-common.repo
    CentOS-Ceph -Nautilus.repo CentOS-NFS-Ganesha-28.repo CentOS-Vault.repo

    #cat CentOS-OpenStack-stein.repo
    CentOS-OpenStack-stein.repo
  8. Update the package on all nodes
    # yum upgrade
  9. Install the openstack client on all nodes
    # yum install python -openstackclient

    Install the database

  10. Install the database and python components
    # yum install mariadb mariadb-server python2-PyMySQL
  11. Create a database configuration file and write the following configuration
    # vi /etc/my.cnf.d/openstack.cnf
    [mysqld]
    bind-address = 192.168.205.147
    default-storage-engine = innodb
    innodb_file_per_table = on
    max_connections = 4096
    collation-server = utf8_general_ci
    character-set-server = utf8
  12. < li>Allow the system to automatically start the service and start the service when the system boots

    # systemctl enable mariadb.service
    # systemctl start mariadb.service
  13. Run the mysql_secure_installation script, especially the root password, and configure a suitable password for root. For demonstration, we set it as root, and the password is root123
    # mysql_secure_installation

    Install the message queue on mysql< /h4>

    Openstack services use message queues to coordinate operation and status information. Message queues usually run on the controller. Openstack supports several message queues such as rabbitMQ, Qpid, ZeroMQ. Most distributions support these Specific message queue. In this experiment, we use RabbitMQ because most distributions support it. In this column, our message queue runs in dababase

  14. Install package
    # yum install rabbitmq -server
  15. Allow the system to automatically start the service and start the service when the system boots
    # systemctl enable rabbitmq-server.service
    # systemctl start rabbitmq-server.service
  16. Add an openstack user
    # rabbitmqctl add_user openstack openstack123
  17. Allow openstack users to have write, and read access rights
    # rabbitmqctl set_permissions openstack ". *" ".*" ".*"
    Note: Authorize user "openstack" in vhost "/" ...

    Install and configure Memcached

    Identity The identification service authentication mechanism uses Memcached to cache tokens. Memcached usually runs on the controller. For production deployment, we recommend enabling a combination of firewall, authentication and encryption to protect it.

  18. Install the package
    # yum install memcached python-memcached
  19. Edit the file /etc/sysconfig/memcached and modify the configuration file service to use the management IP , Allow other nodes to access Memcached through the management IP
    #vi /etc/sysconfi/memcached
    OPTIONS="-l 127.0.0.1,::1,master" #If you install it on the database server, Then change the name of the database server, because the analysis has been done in the hosts
  20. Allow the system to automatically start the service and start the service when the system boots
    # systemctl enable memcached.service
    # systemctl start memcached.service

WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 5493 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.