Refer to some information on the Internet to finally install openstack. Although I have been in contact with openstack for 2 or 3 years, they are intermittent. Picking it up again now, hopefully digging into it this time. Without further ado, let’s get to the point and record the process of installing Openstack this time.
VirtualBox+Ubuntu+Openstack
VirtualBox: 5.0.16 (Linux version)
Ubuntu: 14.4.04 server version
Openstack: Kilo
1, Install VirtualBox and ubuntu, this is simple, just follow the default. Remember to check ssh server when installing ubuntu. Mainly can be remoted to ubuntu later
2. Install git, then download DevStack:
$ sudo apt-get install git -y
$ git clone -b stable/kilo https://git.openstack.org/openstack-dev/devstack
(An article I referenced before was the installed juno version, but it seems that the juno branch of devstack has been deleted or something. I can't find it anyway, so I went to git to find it directly: https://git.openstack.org/cgit/ openstack-dev/devstack/?h=master After reaching this page, click the drop-down menu in the upper right corner to see some existing branches, here stable/kilo is selected)
3. Installation, if you just type ./stack.sh, it will only install some default openstack components, such as Neutron, which will not be installed. Then we can define some installed components by ourselves, first create local.conf in devstack, then change the permissions, and then write the components we need to install
$ cd devstack
$ touch local.conf
$ chmod 644 local.conf
local.conf file content:
[[local|localrc]]
ADMIN_PASSWORD=123456
SERVICE_TOKEN=$ADMIN_PASSWORD
MYSQL_PASSWORD=$ADMIN_PASSWORD
RABBIT_PASSWORD=$ADMIN_PASSWORD
SERVICE_PASSWORD=$ADMIN_PASSWORD
# Branch
GLANCE_BRANCH=stable/kilo
HORIZON_BRANCH=stable/kilo
KEYSTONE_BRANCH=stable/kilo
NOVA_BRANCH=stable/kilo
NEUTRON_BRANCH=stable/kilo
HEAT_BRANCH=stable/kilo
CEILOMETER_BRANCH=stable/kilo
TROVE_BRANCH=stable/kilo
# Services
ENABLED_SERVICES=rabbit,mysql,key
ENABLED_SERVICES+=,n-api,n-crt,n-obj,n-cpu,n-cond,n-sch,n-novnc,n-cauth
ENABLED_SERVICES+=,s-proxy,s-object,s-container,s-account
ENABLED_SERVICES+=,g-api,g-reg
ENABLED_SERVICES+=,cinder,c-api,c-vol,c-sch,c-bak
ENABLED_SERVICES+=,trove,tr-api,tr-tmgr,tr-cond
ENABLED_SERVICES+=,horizon
# Ceilometer
ENABLED_SERVICES+=,ceilometer-acompute,ceilometer-acentral,ceilometer-collector,ceilometer-api
ENABLED_SERVICES+=,ceilometer-alarm-notify,ceilometer-alarm-eval
# Heat
ENABLED_SERVICES+=,heat,h-api,h-api-cfn,h-api-cw,h-eng
# Neutron
DISABLED_SERVICES=n-net
ENABLED_SERVICES+=,q-svc,q-agt,q-dhcp,q-l3,q-meta,q-metering,neutron
# Neutron - Load Balancing
ENABLED_SERVICES+=,q-lbaas
# VLAN configuration
Q_PLUGIN=ml2
ENABLE_TENANT_VLANS=True
# GRE tunnel configuration
Q_PLUGIN=ml2
ENABLE_TENANT_TUNNELS=True
Q_ML2_TENANT_NETWORK_TYPE=gre
# Logging
LOGFILE=$DEST/logs/stack.sh.log
SCREEN_LOGDIR=$DEST/logs/screen
LOGDAYS=2
# Swift
SWIFT_HASH=66a3d6b56c1f479c8b4e70ab5c2000f5
SWIFT_REPLICAS=1
SWIFT_DATA_DIR = $ DEST / data
# Tempest
enable_service tempest
$ ./stack.sh
When the installation is successful, several lines of openstack information will appear, similar to this (screenshots from the Internet):
Off topic:
When you log in to openstack for the first time, everything is normal, but when you restart ubuntu and log in to openstack again, an error such as no instance will be reported. At this time, you can cd devstack, run ./rejoin-stack, and log in again It seems to be fine, as for the reason I am also exploring.