In this tutorial, How to install OpenStack all in one Centos 7. OpenStack is an open-source for setting up Infrastructure as a service. It provides a solution for both public and private cloud.
For production a minimal OpenStack setup requires one controller and one compute node. To get start OpenStack a practice to set up all-in-one deployment.
- My Laptop use OS Linux Mint
- Installed Vagrant + VirutalBox
Example configure Vagrant for Openstack
huupv@huupv-VivoBook-S15-X530UA:~/VMs_vagrant/Dev_Openstack$ cat Vagrantfile # The content as below Vagrant.configure("2") do |config| config.ssh.insert_key = false config.vm.provider :virtualbox do |vb| vb.memory = 4500 vb.cpus = 2 end # Application server 1. config.vm.define "app3" do |app3| app3.vm.hostname = "OpenstackDev" app3.vm.box = "centos/7" app3.vm.network "private_network", ip: "172.20.19.31" app3.vm.network :forwarded_port, guest: 80, host: 8080 app3.vm.network :forwarded_port, guest: 5000, host: 5000 app3.vm.network :forwarded_port, guest: 9696, host: 9696 app3.vm.network :forwarded_port, guest: 8774, host: 8774 app3.vm.network :forwarded_port, guest: 35357, host: 35357 end end
How to do it setup OpenStack for deployment
To recommended/best practice for OpenStack disable Firewalld, NetworkManager and SELinux.
Stop and disable NetworkManager
sudo systemctl stop NetworkManager sudo systemctl disable NetworkManager
Stop and disable firewalld
sudo systemctl stop firewalld sudo systemctl disable firewalld
Restart network service
sudo systemctl restart network
Can do it permanently in file /etc/selinux/config change SELINUX=enforcing to SELINUX=disabled.
Update your system.
sudo yum -y update
Configure a static IP address and set your hostname in /etc/hosts
Restart the machine.
2. Install OpenStack RPM
On CentOS, the Extras repository provides the RPM that enables the OpenStack repository.
sudo yum install -y centos-release-openstack-stein
3. Install Packstack
sudo yum install -y openstack-packstack
4. Deploy and run OpenStack using Packstack
sudo packstack --allinone
The output as below
[vagrant@OpenstackDev ~]$ sudo packstack --allinone Welcome to the Packstack setup utility The installation log file is available at: /var/tmp/packstack/20190716-150951-Z_3kTo/openstack-setup.log Installing: Clean Up [ DONE ] Discovering ip protocol version [ DONE ] Setting up ssh keys [ DONE ] Preparing servers [ DONE ] Pre installing Puppet and discovering hosts' details [ DONE ] Preparing pre-install entries [ DONE ] Setting up CACERT [ DONE ] Preparing AMQP entries [ DONE ] Preparing MariaDB entries [ DONE ] Fixing Keystone LDAP config parameters to be undef if empty[ DONE ] Preparing Keystone entries [ DONE ] Preparing Glance entries [ DONE ] Checking if the Cinder server has a cinder-volumes vg[ DONE ] Preparing Cinder entries [ DONE ] Preparing Nova API entries [ DONE ] Creating ssh keys for Nova migration [ DONE ] Gathering ssh host keys for Nova migration [ DONE ] Preparing Nova Compute entries [ DONE ] Preparing Nova Scheduler entries [ DONE ] Preparing Nova VNC Proxy entries [ DONE ] Preparing OpenStack Network-related Nova entries [ DONE ] Preparing Nova Common entries [ DONE ] Preparing Neutron LBaaS Agent entries [ DONE ] Preparing Neutron API entries [ DONE ] Preparing Neutron L3 entries [ DONE ] Preparing Neutron L2 Agent entries [ DONE ] Preparing Neutron DHCP Agent entries [ DONE ] Preparing Neutron Metering Agent entries [ DONE ] Checking if NetworkManager is enabled and running [ DONE ] Preparing OpenStack Client entries [ DONE ] Preparing Horizon entries [ DONE ] Preparing Swift builder entries [ DONE ] Preparing Swift proxy entries [ DONE ] Preparing Swift storage entries [ DONE ] Preparing Gnocchi entries [ DONE ] Preparing Redis entries [ DONE ] Preparing Ceilometer entries [ DONE ] Preparing Aodh entries [ DONE ] Preparing Puppet manifests [ DONE ] Copying Puppet modules and manifests [ DONE ] Applying 10.0.2.15_controller.pp 10.0.2.15_controller.pp: [ DONE ] Applying 10.0.2.15_network.pp 10.0.2.15_network.pp: [ DONE ] Applying 10.0.2.15_compute.pp 10.0.2.15_compute.pp: [ DONE ] Applying Puppet manifests [ DONE ] Finalizing [ DONE ] **** Installation completed successfully ****** * A new answerfile was created in: /root/packstack-answers-20190716-150952.txt * Time synchronization installation was skipped. Please note that unsynchronized time on server instances might be problem for some OpenStack components. * File /root/keystonerc_admin has been created on OpenStack client host 10.0.2.15. To use the command line tools you need to source the file. * To access the OpenStack Dashboard browse to http://10.0.2.15/dashboard . Please, find your login credentials stored in the keystonerc_admin in your home directory. * The installation log file is available at: /var/tmp/packstack/20190716-150951-Z_3kTo/openstack-setup.log * The generated manifests are available at: /var/tmp/packstack/20190716-150951-Z_3kTo/manifests
Logging into the dashboard (called as Horizon). Link access http://localhost:8080/dashboard
Password user admin for OpenStack “A new answerfile was created in: /root/packstack-answers-20190716-150952.txt” during install openstack.
$ sudo cat /root/packstack-answers-20190716-150952.txt | grep ADMIN
You have Installed OpenStack all in one centos 7 deployment a practice 🙂