Sunday, April 24, 2016

Using DevStack to Deploy OpenStack Kilo

kilo

I OpenStack Kilo Installation By Using DevStack

用原生的Devstack是無法安裝Kilo版本的主要是pbr版本的問題。
為了解決這樣的問題,必須換source git。
我們把source git換到trystack。
local.conf加入下面這行。

GIT_BASE=${GIT_BASE:-http://git.trystack.cn}

透過著個方法可以很順利的安裝kilo版。

完整的安裝流程在之前的Blog已經寫過了。

http://gogosatellite.blogspot.tw/2016/04/using-devstack-to-install-openstack.html

只需要將Devstack換成kilo版。

git clone https://github.com/openstack-dev/devstack.git -b stable/kilo

完整的local.conf如下。

[[local|localrc]]
DEST=/opt/stack
#change github to trystack
HOST_IP=172.16.235.128
GIT_BASE=${GIT_BASE:-http://git.trystack.cn}
#NOVNC_REPO=${NOVNC_REPO:-http://git.trystack.cn/kanaka/noVNC.git}

ADMIN_PASSWORD=password
MYSQL_PASSWORD=password
RABBIT_PASSWORD=password
SERVICE_PASSWORD=password
SERVICE_TOKEN=tokentoken


ENABLED_SERVICES=key,rabbit,mysql,horizon
ENABLED_SERVICES+=,n-api,n-crt,n-cpu,n-net,n-cond,n-sch,n-novnc,n-cauth
ENABLED_SERVICES+=,g-api,g-reg

# Enabling Neutron (network) Service
disable_service n-net
enable_service q-svc
enable_service q-agt
enable_service q-dhcp
enable_service q-l3
enable_service q-meta
enable_service neutron
enable_service q-vpn

## Neutron options
FIXED_RANGE=10.0.0.0/24
FIXED_NETWORK_SIZE=256
NETWORK_GATEWAY=10.0.0.1
PRIVATE_SUBNET_NAME=privateA

PUBLIC_SUBNET_NAME=public-subnet
FLOATING_RANGE=172.16.235.0/24
PUBLIC_NETWORK_GATEWAY=172.16.235.2
#Q_FLOATING_ALLOCATION_POOL="start=172.24.4.11,end=172.24.4.29"
PUBLIC_INTERFACE=eth0
Q_USE_PROVIDERNET_FOR_PUBLIC=True
OVS_PHYSICAL_BRIDGE=br-ex
PUBLIC_BRIDGE=br-ex
OVS_BRIDGE_MAPPINGS=public:br-ex



LIBVIRT_TYPE=qemu

IMAGE_URLS="http://download.cirros-cloud.net/0.3.3/cirros-0.3.3-x86_64-uec.tar.gz"

SCREEN_LOGDIR=/opt/stack/screen-logs
SYSLOG=True
LOGFILE=~/devstack/stack.sh.log


Q_USE_DEBUG_COMMAND=True

# RECLONE=No
RECLONE=yes
OFFLINE=False

Result

This is your host ip: 172.16.235.128
Horizon is now available at http://172.16.235.128/
Keystone is serving at http://172.16.235.128:5000/
The default users are: admin and demo
The password: password
stack@kilo:~/devstack$

After Reboot

After reboot the Openstack is stoped, we need to add the following command to make OpenStack alive.
su stack cd /devstack sudo ./rejoin-stack

The networking is still not right, and we can add the following command to make the network correctly.

ifconfig eth0 0 ## MANAGEMENT IP ADDRESS
ifconfig br-ex 172.16.235.128 netmask 255.255.255.0 up
route add default gw 172.16.235.2 dev br-ex metric 100

172.16.235.128 is hostip that we want to connect throuth a client.
We can detect gw before install the OpenStack by using route command to get the default gateway.

Now the system go back to a normal state, enjoy OpenStack.

No comments:

Post a Comment