blog header

INSTALL OPENSTACK ON RHEL6

INSTALL OPENSTACK ON RHEL6

The perquisites are to have sufficient memory and to turn off selinux or set it to permissive. Changes to SELinux require a reboot. You also need sudo access, I ran packstack from my control node.

[root@ap2v ~]# cat /etc/selinux/config
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#     enforcing - SELinux security policy is enforced.
#     permissive - SELinux prints warnings instead of enforcing.
#     disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
#     targeted - Targeted processes are protected,
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted

First add the RHEL6 repo – you can also install from RPM – and install packstack using yum

[root@ap2v ~]# yum install -y https://repos.fedorapeople.org/repos/openstack/openstack-havana/epel-6/
[root@ap2v ~]# yum install -y openstack-packstack

Configure NTP on the nodes. This is not a must but is a good to have. Install ntp and sync up with your ntp server. I used a public ntp server in my configuration.

[root@ap2v ~]# yum install ntp
[root@ap2v ~]# chkconfig ntpd on
[root@ap2v ~]# ntpdate  172.25.1.254
[root@ap2v ~]# /etc/init.d/ntpd start

Now, since I wanted to make modifications to the default packstack install, I generated a file that contained the install configuration. This file is called “answer file” and I put my configuration preferences in it. I then told packstack to use that file to do the install. This answer file is also used if you need to make changes to the openstack cluster, for example if you wanted to add a node. You would use the same process, make changes to the answer file to reflect that a new node has been added and again run packstack and point it to modified the answer file.
I generated the answer file

[root@ap2v ~]# packstack –gen-answer-file=/root/my_answers.txt
[root@ap2v ~]# vi my_answers.txt

The answer file defaults to putting all the openstack modules in one node.

I made changes to ensure that my swift node was installed in my compute node running on a unified computing system

UCS B200 blade. I left the swift proxy node in the control node. Node 172.25.1.12 is my compute node and node 172.25.1.13 is my control node.

# A comma separated list of IP addresses on which to install the
# Swift Storage services, each entry should take the format
# [/dev], for example 127.0.0.1/vdb will install /dev/vdb
# on 127.0.0.1 as a swift storage device(packstack does not create the
# filesystem, you must do this first), if /dev is omitted Packstack
# will create a loopback device for a test setup
CONFIG_SWIFT_STORAGE_HOSTS= 172.25.1.12

#The IP address on which to install the Swift proxy service
CONFIG_SWIFT_PROXY_HOSTS= 172.25.1.13

I installed Cinder in my compute node.

# The IP address of the server on which to install Cinder
CONFIG_CINDER_HOST= 172.25.1.12

I installed nova compute in my compute node. If on a later date I wanted to add a second compute node, I would come make the changes here.

# A comma separated list of IP addresses on which to install the Nova
# Compute services
CONFIG_NOVA_COMPUTE_HOSTS= 172.25.1.13

I also set public interface for Nova Network on the control node to be eth0

# Public interface on the Nova network server
CONFIG_NOVA_NETWORK_PUBIF=eth0

And set the private interface for Nova Network dhcp on the control nodes and private interface of the Nova

# Private interface for Flat DHCP on the Nova network server
CONFIG_NOVA_NETWORK_PRIVIF=eth1

# Private interface for Flat DHCP on the Nova compute servers
CONFIG_NOVA_COMPUTE_PRIVIF=eth1
# Whether to provision for demo usage and testing. Note that
# provisioning is only supported for all-in-one installations.
CONFIG_PROVISION_DEMO=n

And set the Password of admin user

# The password to use for the Keystone admin user
CONFIG_KEYSTONE_ADMIN_PW=mypassword

At this point I was done and was ready to start the install. During the install, you will be prompted for the compute nodes root password.

[root@ap2v ~]# packstack –answer-file=/root/my_answers.txt
Welcome to Installer setup utility
Packstack changed given value  to required value /root/.ssh/id_rsa.pub
Installing:
Clean Up...                                              [ DONE ]
Adding pre install manifest entries...                   [ DONE ]
Setting up ssh [email protected]'s password:
..
172.25.1.13_swift.pp :                                             [ DONE ]
172.25.1.13_nagios.pp :                                            [ DONE ]
172.25.1.13_nagios_nrpe.pp :                                       [ DONE ]
Applying 172.25.1.13_postscript.pp            [ DONE ] 
172.25.1.13_postscript.pp :        

A few 5-15 minutes later the install will complete.

[root@ap2v ~]# nova-manage service list
Binary           Host                                 Zone             Status     State Updated_At
nova-consoleauth server1.example.com                 internal         enabled    :-)   2015-02-04 08:30:49
nova-cert        server1.example.com                 internal         enabled    :-)   2015-02-04 08:30:49
nova-conductor   server1.example.com                 internal         enabled    :-)   2015-02-04 08:30:49
nova-scheduler   server1.example.com                 internal         enabled    :-)   2015-02-04 08:30:49
nova-network     localhost 	                      internal         enabled    :-)   2015-02-04 08:30:50
nova-compute     localhost				   nova            enabled    :-)   2015-02-04 08:30:53

To log in, you naviage to glance on your browser from 172.25.1.13/dashboard. Username is admin. Password would have been auto generated for you when you created the answer file.

You can also grep the keystonerc_admin file generated in the install directory

[root@ap2v ~(keystone_admin)]# cat keystonerc_admin
export OS_USERNAME=admin
export OS_TENANT_NAME=admin
export OS_PASSWORD=mypassword
export OS_AUTH_URL=http://172.25.1.13:35357/v2.0/

NEWSLETTER

Submit to our newsletter to receive exclusive stories delivered to you inbox!

We'll never share your email with anyone else.
course

Related Category Courses

Sign in to your account

Sign in to your account

Welcome back! Login with your data that you entered during registration.

Don't have an account? Sign up

Forget Password

We will send a password reset link on your email.

Create Account

Create Account

Use your email for registration.

Already on Ap2v.com Sign in