A.0 Preparations on VMware Workstation
[A.1. Deployment model on VMware Workstation] (#deployment)
C. Installation on CONTROLLER NODE
D. Installation on NETWORK NODE
E. Installation on COMPUTE NODE
F. Installing HORIZON, creating networks on CONTROLLER NODE
Configurations of vmnets on vmware workdstation in the following figures.
- VMNET0 - Bridge mode, 192.168.1.0/24
- VMNET2 - VMNET 2. IP range: 10.10.10.0/24
- VMNET3 - VMNET 3. IP range: 10.10.20.0/24 Go to "Edit" tab ==> Virtual Network Editor.
3 nodes model of Openstack deployment in a laptop.
- Ubuntu installation in Vmware Workstation must be ensured by the order of network.
- Ip addresses of NICs are dynamic, shell scripts will automatically assign static IPs later.(written in files config.cfg
- HDD: 20GB
- RAM: 2GB
- CPU: 02 (Virtualization support)
- NIC: 02 NICs (eth0 - vmnet2 ) (eth1 - brige). Dynamic IP.
As showed as following figure:
- HDD: 20GB
- RAM: 2GB
- CPU 01 (Virtualization support)
- NICs: 03. eth0-vmnet2. eth1-bridge . eth2-vmnet3. Dynamic IP.
- Hostname: network
As showed as following figure:
- HDD: 60GB
- RAM: 3GB
- CPU 2x2 (Virtualization support)
- NICs: 03. eth0-vmnet2. eth1-bridge . eth2-vmnet3. Dynamic IP.
- Hostname: compute1
As showed as following figure:
Access under the "root" user into host machines and install packages, preparation scripts for installing process.
apt-get update
apt-get install git -y
git clone https://github.com/vietstacker/openstack-kilo-multinode-U14.04-v1
mv /root/openstack-kilo-multinode-U14.04-v1/KILO-U14.04/ KILO-U14.04
rm -rf openstack-kilo-multinode-U14.04-v1
cd KILO-U14.04/
chmod +x *.sh
Before modifying, no need to assign static IP to NICs on each host machine. Modify the file config.cfg lying in the repo KILO-U14.04 with your own IPs or remain IPs and ensure that they are not used by other machines in your network.
Here is initial file : .... # IP assignment in CONTROLLER NODE CON_MGNT_IP=10.10.10.71 CON_EXT_IP=192.168.1.71
# IP assignment in NETWORK NODE
NET_MGNT_IP=10.10.10.72
NET_EXT_IP=192.168.1.72
NET_DATA_VM_IP=10.10.20.72
# IP assignment in COMPUTE1 NODE
COM1_MGNT_IP=10.10.10.73
COM1_EXT_IP=192.168.1.73
COM1_DATA_VM_IP=10.10.20.73
# IP assignment in COMPUTE2 NODE
COM2_MGNT_IP=10.10.10.74
COM2_EXT_IP=192.168.1.74
COM2_DATA_VM_IP=10.10.20.74
GATEWAY_IP=192.168.1.1
NETMASK_ADD=255.255.255.0
# Set password
DEFAULT_PASS='Welcome123'
.....
Execution in each node
bash ctl-1-ipadd.sh
After executing scripts, the Controller will restart and has the following parameters:
Hostname | NICs | IP ADDRESS | SUBNET MASK | GATEWAY | DNS | Note |
---|---|---|---|---|---|---|
controller | eth0 | 10.10.10.71 | 255.255.255.0 | VMNET2 | ||
eth1 | 192.168.1.71 | 255.255.255.0 | 192.168.1.1 | 8.8.8.8 | brige |
Access to the controller node with the address of CON_EXT_IP declared in the file config.cfg 192.168.1.71 under the "root" user.
cd KILO-U14.04
bash ctl-2-prepare.sh
bash ctl-3-create-db.sh
bash ctl-4.keystone.sh
Creates endpoints to the services. The parameters in shell are get from config.cfg
bash ctl-5-creatusetenant.sh
Executing the openrc file
source admin-openrc.sh
Checking again keystone service
keystone user-list
Result of keystone user-list
+----------------------------------+---------+---------+-----------------------+
| id | name | enabled | email |
+----------------------------------+---------+---------+-----------------------+
| 96caaef69654429da128f2f5411b2551 | admin | True | [email protected] |
| adbe0711c4d540a1a2c817d0eec31568 | cinder | True | [email protected] |
| 902d4729de1345a3946f21e22bc0cdc5 | demo | True | [email protected] |
| 61b56f4bc0ea418e88bdd1e08dad547f | glance | True | [email protected] |
| c59afb418269424992b9d2c517daad36 | neutron | True | [email protected] |
| 682d9357b27341feb4bd04e75d55490c | nova | True | [email protected] |
| 619d4c53ab214c8583b8663eccac217e | swift | True | [email protected] |
+----------------------------------+---------+---------+-----------------------+
Installation of other services
bash ctl-6-glance.sh
bash ctl-7-nova.sh
bash ctl-8-neutron.sh
bash ctl-9-cinder.sh
- Installing NEUTRON, ML2 and GRE config, using use case per-router per-tenant.
Access to the NETWORK NODE under the "root" user
apt-get update
apt-get install git -y
git clone https://github.com/vietstacker/openstack-kilo-multinode-U14.04-v1
mv /root/openstack-kilo-multinode-U14.04-v1/KILO-U14.04/ KILO-U14.04
rm -rf openstack-kilo-multinode-U14.04-v1
cd KILO-U14.04/
chmod +x *.sh
Script for OpenvSwitch installtion and declaring br-int & br-ex for OpenvSwitch
bash net-ipadd.sh
- NETWORK NODE will restart, access again under the "root" user.
- IP và hostname parameters on the NETWORK NODE:
Hostname | NICs | IP ADDRESS | SUBNET MASK | GATEWAY | DNS | NOTE |
---|---|---|---|---|---|---|
network | eth0 | 10.10.10.72 | 255.255.255.0 | VMNET2 | ||
br-ex | 192.168.1.72 | 255.255.255.0 | 192.168.1.1 | 8.8.8.8 | bridge | |
eth2 | 10.10.20.72 | 255.255.255.0 | VMNET3 |
Note: Shell will move eth1 to the promisc mode and assign IP for br-ex created after OpenvSwitch installation.
- Using putty to ssh to the NETWORK NODE through IP 192.168.1.172 with "root" user
cd KILO-U14.04/
bash net-prepare.sh
End of installing on the NETWORK NODE and move to COMPUTE NODE
apt-get update
apt-get install git -y
git clone https://github.com/vietstacker/openstack-kilo-multinode-U14.04-v1
mv /root/openstack-kilo-multinode-U14.04-v1/KILO-U14.04/ KILO-U14.04
rm -rf openstack-kilo-multinode-U14.04-v1
cd KILO-U14.04/
chmod +x *.sh
bash com1-ipdd.sh
NICs of COMPUTE NODE will be following:
Hostname | NICs | IP ADDRESS | SUBNET MASK | GATEWAY | DNS | NOTE |
---|---|---|---|---|---|---|
compute1 | eth0 | 10.10.10.73 | 255.255.255.0 | VMNET2 | ||
br-ex | 192.168.1.73 | 255.255.255.0 | 192.168.1.1 | 8.8.8.8 | bridge | |
eth2 | 10.10.20.73 | 255.255.255.0 | VMNET3 |
COMPUTE node will restart, access again to execute the following scripts
Access to the compute node
cd KILO-U14.04
bash com1-prepare.sh
Choose "YES"
End of COMPUTE NODE installing, move back to the CONTROLLER NODE.
Access to the controller node
cd /root/KILO-U14.04
bash ctl-horizon.sh
neutron net-create ext-net --router:external \
--provider:physical_network external --provider:network_type flat
neutron subnet-create ext-net 192.168.1.0/24 --name ext-subnet \
--allocation-pool start=192.168.1.101,end=192.168.1.200 \
--disable-dhcp --gateway 192.168.1.1
neutron net-create demo-net
neutron subnet-create demo-net 192.168.10.0/24 \
--name demo-subnet --gateway 192.168.1.1 --dns-nameserver 8.8.8.8
neutron router-create demo-router
neutron router-interface-add demo-router demo-subnet
neutron router-gateway-set demo-router ext-net