From 96c6e7fcea763c0e440f210e14c9487dea48faa6 Mon Sep 17 00:00:00 2001 From: Roger Luethi Date: Tue, 22 Aug 2017 17:44:09 +0200 Subject: [PATCH] Pike update This changeset contains update for Pike. Notable changes include: - First release after big documentation move (URLs changed) Change-Id: I73288f3d32c5883b1b27d8827a367086de560046 --- labs/osbash/config/config.compute1 | 2 +- labs/osbash/config/openstack | 14 ++--- labs/osbash/scripts/ubuntu/apt_init.sh | 22 ++++---- .../scripts/ubuntu/apt_install_mysql.sh | 2 +- .../osbash/scripts/ubuntu/apt_pre-download.sh | 2 +- labs/osbash/scripts/ubuntu/apt_upgrade.sh | 2 +- .../scripts/ubuntu/install_memcached.sh | 2 +- .../osbash/scripts/ubuntu/install_rabbitmq.sh | 4 +- .../scripts/ubuntu/setup_cinder_controller.sh | 55 +++++++++++++------ .../scripts/ubuntu/setup_cinder_volumes.sh | 15 ++--- labs/osbash/scripts/ubuntu/setup_glance.sh | 4 +- .../scripts/ubuntu/setup_heat_controller.sh | 6 +- labs/osbash/scripts/ubuntu/setup_horizon.sh | 17 +----- labs/osbash/scripts/ubuntu/setup_keystone.sh | 25 ++++----- .../scripts/ubuntu/setup_neutron_compute.sh | 4 +- .../ubuntu/setup_neutron_compute_part_2.sh | 12 ++-- .../ubuntu/setup_neutron_controller.sh | 8 ++- .../ubuntu/setup_neutron_controller_part_2.sh | 10 ++-- .../scripts/ubuntu/setup_nova_compute.sh | 18 +++--- .../scripts/ubuntu/setup_nova_controller.sh | 2 +- .../ubuntu/setup_self-service_compute.sh | 2 +- .../ubuntu/setup_self-service_controller.sh | 4 +- 22 files changed, 123 insertions(+), 109 deletions(-) diff --git a/labs/osbash/config/config.compute1 b/labs/osbash/config/config.compute1 index 1331de79..bc231db4 100644 --- a/labs/osbash/config/config.compute1 +++ b/labs/osbash/config/config.compute1 @@ -17,7 +17,7 @@ NET_IF_2="manual 203.0.113.0" #------------------------------------------------------------------------------ # Size of second disk in MB (/dev/sdb) # Test volume is 1 GB; backing volume must be bigger -SECOND_DISK_SIZE=1040 +SECOND_DISK_SIZE=1280 #------------------------------------------------------------------------------ # http://docs.openstack.org/mitaka/install-guide-ubuntu/environment.html diff --git a/labs/osbash/config/openstack b/labs/osbash/config/openstack index 1501c28a..20d9c6d5 100644 --- a/labs/osbash/config/openstack +++ b/labs/osbash/config/openstack @@ -1,10 +1,10 @@ # This file contains OpenStack configuration data. It is used by both # host (osbash, Windows batch) and VM guest scripts. -# ocata (production release; cloud-archive:ocata) -# ocata-proposed (pre-release testing: cloud-archive:ocata-proposed) -# ocata-staging (ppa:openstack-ubuntu-testing/ocata) -: ${OPENSTACK_RELEASE:=ocata} +# pike (production release; cloud-archive:pike) +# pike-proposed (pre-release testing: cloud-archive:pike-proposed) +# pike-staging (ppa:openstack-ubuntu-testing/pike) +: ${OPENSTACK_RELEASE:=pike} # CirrOS image URL if [ "$(uname -m)" = "x86_64" ]; then @@ -19,7 +19,7 @@ unset arch CIRROS_IMG_NAME="cirros" #------------------------------------------------------------------------------ -# http://docs.openstack.org/mitaka/install-guide-ubuntu/environment-networking.html +# https://docs.openstack.org/install-guide/environment-networking.html #------------------------------------------------------------------------------ # Networks used by OpenStack training-labs setup @@ -31,7 +31,7 @@ NETWORK_2="provider 203.0.113.0" PXE_INITIAL_NODE_IP="10.0.0.240" #------------------------------------------------------------------------------ -# http://docs.openstack.org/ocata/install-guide-ubuntu/launch-instance-networks-provider.html +# https://docs.openstack.org/install-guide/launch-instance-networks-provider.html #------------------------------------------------------------------------------ # Public network @@ -42,7 +42,7 @@ PXE_INITIAL_NODE_IP="10.0.0.240" : ${END_IP_ADDRESS:=203.0.113.200} #------------------------------------------------------------------------------ -# http://docs.openstack.org/mitaka/install-guide-ubuntu/launch-instance-networks-private.html +# https://docs.openstack.org/install-guide/launch-instance-selfservice.html #------------------------------------------------------------------------------ # Private demo network diff --git a/labs/osbash/scripts/ubuntu/apt_init.sh b/labs/osbash/scripts/ubuntu/apt_init.sh index 584e15ea..9ae6af49 100755 --- a/labs/osbash/scripts/ubuntu/apt_init.sh +++ b/labs/osbash/scripts/ubuntu/apt_init.sh @@ -44,27 +44,27 @@ sudo apt update # --------------------------------------------------------------------------- # Enable the OpenStack repository -# http://docs.openstack.org/ocata/install-guide-ubuntu/environment-packages.html +# https://docs.openstack.org/install-guide/environment-packages-ubuntu.html # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # NOTE: Using pre-release staging ppa is not documented in install-guide -# https://launchpad.net/~ubuntu-cloud-archive/+archive/ubuntu/ocata-staging +# https://launchpad.net/~ubuntu-cloud-archive/+archive/ubuntu/pike-staging #-------------------------------------------------------------------------- echo "Installing packages needed for add-apt-repository." sudo apt -y install software-properties-common case "$OPENSTACK_RELEASE" in - ocata) - REPO=cloud-archive:ocata - SRC_FILE=cloudarchive-ocata.list + pike) + REPO=cloud-archive:pike + SRC_FILE=cloudarchive-pike.list ;; - ocata-proposed) - REPO=cloud-archive:ocata-proposed - SRC_FILE=cloudarchive-ocata-proposed.list + pike-proposed) + REPO=cloud-archive:pike-proposed + SRC_FILE=cloudarchive-pike-proposed.list ;; - ocata-staging) - REPO=ppa:ubuntu-cloud-archive/ocata-staging - SRC_FILE=ubuntu-cloud-archive-ubuntu-ocata-staging-xenial.list + pike-staging) + REPO=ppa:ubuntu-cloud-archive/pike-staging + SRC_FILE=ubuntu-cloud-archive-ubuntu-pike-staging-xenial.list ;; *) echo >&2 "Unknown OpenStack release: $OPENSTACK_RELEASE. Aborting." diff --git a/labs/osbash/scripts/ubuntu/apt_install_mysql.sh b/labs/osbash/scripts/ubuntu/apt_install_mysql.sh index fff2d6c4..de641f7b 100755 --- a/labs/osbash/scripts/ubuntu/apt_install_mysql.sh +++ b/labs/osbash/scripts/ubuntu/apt_install_mysql.sh @@ -22,7 +22,7 @@ echo "Will bind MySQL server to $DB_IP." #------------------------------------------------------------------------------ # Install and configure the database server -# http://docs.openstack.org/ocata/install-guide-ubuntu/environment-sql-database.html +# https://docs.openstack.org/install-guide/environment-sql-database-ubuntu.html #------------------------------------------------------------------------------ echo "Sourced MySQL password from credentials: $DATABASE_PASSWORD" diff --git a/labs/osbash/scripts/ubuntu/apt_pre-download.sh b/labs/osbash/scripts/ubuntu/apt_pre-download.sh index 49370802..28e1b1dc 100755 --- a/labs/osbash/scripts/ubuntu/apt_pre-download.sh +++ b/labs/osbash/scripts/ubuntu/apt_pre-download.sh @@ -54,7 +54,7 @@ apt_download cinder-api cinder-scheduler python-cinderclient apt_download openstack-dashboard # Cinder Volumes -apt_download lvm2 cinder-volume +apt_download lvm2 cinder-volume thin-provisioning-tools # Nova Compute apt_download nova-compute nova-compute-qemu qemu sysfsutils diff --git a/labs/osbash/scripts/ubuntu/apt_upgrade.sh b/labs/osbash/scripts/ubuntu/apt_upgrade.sh index 842b68af..03a19e1e 100755 --- a/labs/osbash/scripts/ubuntu/apt_upgrade.sh +++ b/labs/osbash/scripts/ubuntu/apt_upgrade.sh @@ -14,7 +14,7 @@ exec_logfile #------------------------------------------------------------------------------ # Finalize the installation -# http://docs.openstack.org/mitaka/install-guide-ubuntu/environment-packages.html +# https://docs.openstack.org/install-guide/environment-packages-ubuntu.html #------------------------------------------------------------------------------ # Note: We assume that apt_init.sh set up repos and updated the apt index files diff --git a/labs/osbash/scripts/ubuntu/install_memcached.sh b/labs/osbash/scripts/ubuntu/install_memcached.sh index e84bfb16..10f0ff2f 100755 --- a/labs/osbash/scripts/ubuntu/install_memcached.sh +++ b/labs/osbash/scripts/ubuntu/install_memcached.sh @@ -14,7 +14,7 @@ indicate_current_auto #------------------------------------------------------------------------------ # Memcached -# http://docs.openstack.org/ocata/install-guide-ubuntu/environment-memcached.html +# https://docs.openstack.org/install-guide/environment-memcached-ubuntu.html #------------------------------------------------------------------------------ echo "Installing memcache packages." diff --git a/labs/osbash/scripts/ubuntu/install_rabbitmq.sh b/labs/osbash/scripts/ubuntu/install_rabbitmq.sh index cc1c40e6..84f09450 100755 --- a/labs/osbash/scripts/ubuntu/install_rabbitmq.sh +++ b/labs/osbash/scripts/ubuntu/install_rabbitmq.sh @@ -14,14 +14,14 @@ indicate_current_auto #------------------------------------------------------------------------------- # Install the message broker service (RabbitMQ). -# http://docs.openstack.org/ocata/install-guide-ubuntu/environment-messaging.html +# https://docs.openstack.org/install-guide/environment-messaging-ubuntu.html #------------------------------------------------------------------------------- echo "Installing RabbitMQ." sudo apt install -y rabbitmq-server echo -n "Waiting for RabbitMQ to start." -while ! sudo rabbitmqctl status >/dev/null; do +until sudo rabbitmqctl status >/dev/null; do sleep 1 echo -n . done diff --git a/labs/osbash/scripts/ubuntu/setup_cinder_controller.sh b/labs/osbash/scripts/ubuntu/setup_cinder_controller.sh index 9f28195a..46bb512f 100755 --- a/labs/osbash/scripts/ubuntu/setup_cinder_controller.sh +++ b/labs/osbash/scripts/ubuntu/setup_cinder_controller.sh @@ -14,9 +14,13 @@ indicate_current_auto #------------------------------------------------------------------------------ # Set up Block Storage service controller (cinder controller node) -# http://docs.openstack.org/ocata/install-guide-ubuntu/cinder-controller-install.html +# https://docs.openstack.org/cinder/pike/install/cinder-controller-install-ubuntu.html #------------------------------------------------------------------------------ +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Prerequisites +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + echo "Setting up database for cinder." setup_database cinder "$CINDER_DB_USER" "$CINDER_DBPASS" @@ -40,42 +44,42 @@ openstack role add \ "$ADMIN_ROLE_NAME" echo "Registering cinder with keystone so that other services can locate it." -openstack service create \ - --name cinder \ - --description "OpenStack Block Storage" \ - volume - openstack service create \ --name cinderv2 \ --description "OpenStack Block Storage" \ volumev2 -openstack endpoint create \ - --region "$REGION" \ - volume public http://controller:8776/v1/%\(tenant_id\)s +openstack service create \ + --name cinderv3 \ + --description "OpenStack Block Storage" \ + volumev3 openstack endpoint create \ --region "$REGION" \ - volume internal http://controller:8776/v1/%\(tenant_id\)s + volumev2 public http://controller:8776/v2/%\(project_id\)s openstack endpoint create \ --region "$REGION" \ - volume admin http://controller:8776/v1/%\(tenant_id\)s + volumev2 internal http://controller:8776/v2/%\(project_id\)s openstack endpoint create \ --region "$REGION" \ - volumev2 public http://controller:8776/v2/%\(tenant_id\)s + volumev2 admin http://controller:8776/v2/%\(project_id\)s openstack endpoint create \ --region "$REGION" \ - volumev2 internal http://controller:8776/v2/%\(tenant_id\)s + volumev3 public http://controller:8776/v3/%\(project_id\)s openstack endpoint create \ --region "$REGION" \ - volumev2 admin http://controller:8776/v2/%\(tenant_id\)s + volumev3 internal http://controller:8776/v3/%\(project_id\)s + +openstack endpoint create \ + --region "$REGION" \ + volumev3 admin http://controller:8776/v3/%\(project_id\)s # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -# Install and configure cinder +# Install and configure components # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - echo "Installing cinder." @@ -143,6 +147,16 @@ conf=/etc/apache2/conf-available/cinder-wsgi.conf sudo sed -i --follow-symlinks '/WSGIDaemonProcess/ s/processes=[0-9]*/processes=1/' $conf # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# not in install-guide: as of 2017-08-22, cinder wsgi processes can not +# read /etc/cinder due to permission problem introduced with Pike packages +# (drwxr-x--- root cinder) vs. cinder:www-data +if ls -ld /etc/cinder | grep "root cinder"; then + echo "Setting owner for /etc/cinder." + sudo chown cinder:cinder /etc/cinder +else + echo "XXX Workaround for /etc/cinder owner no longer needed." +fi + echo "Restarting the Compute API service." sudo service nova-api restart @@ -150,6 +164,11 @@ echo "Restarting the Block Storage services." sudo service cinder-scheduler restart sudo service apache2 restart -# Not in the install-guide: -echo "Removing unused SQLite database file." -sudo rm -v /var/lib/cinder/cinder.sqlite +AUTH="source $CONFIG_DIR/admin-openstackrc.sh" +echo -n "Waiting for cinder to start." +until node_ssh controller "$AUTH; openstack volume service list" >/dev/null \ + 2>&1; do + echo -n . + sleep 1 +done +echo diff --git a/labs/osbash/scripts/ubuntu/setup_cinder_volumes.sh b/labs/osbash/scripts/ubuntu/setup_cinder_volumes.sh index f380fcca..a6f13813 100755 --- a/labs/osbash/scripts/ubuntu/setup_cinder_volumes.sh +++ b/labs/osbash/scripts/ubuntu/setup_cinder_volumes.sh @@ -15,7 +15,7 @@ indicate_current_auto #------------------------------------------------------------------------------ # Install and configure a storage node -# http://docs.openstack.org/ocata/install-guide-ubuntu/cinder-storage-install.html +# https://docs.openstack.org/cinder/pike/install/cinder-storage-install-ubuntu.html #------------------------------------------------------------------------------ MY_MGMT_IP=$(get_node_ip_in_network "$(hostname)" "mgmt") @@ -24,6 +24,10 @@ echo "IP address of this node's interface in management network: $MY_MGMT_IP." echo "Installing qemu support package for non-raw image types." sudo apt install -y qemu +# not in install-guide (needed to prevent lvcreate error): +echo "Installing thin-provisioning-tools." +sudo apt install -y thin-provisioning-tools + # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # Prerequisites # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -115,12 +119,9 @@ echo "Restarting cinder service." sudo service tgt restart sudo service cinder-volume restart -# Not in the install-guide: -sudo rm -v /var/lib/cinder/cinder.sqlite - #------------------------------------------------------------------------------ -# Verify the Block Storage installation -# http://docs.openstack.org/ocata/install-guide-ubuntu/cinder-verify.html +# Verify Cinder operation +# https://docs.openstack.org/cinder/pike/install/cinder-verify.html #------------------------------------------------------------------------------ echo "Verifying Block Storage installation on controller node." @@ -182,7 +183,7 @@ check_cinder_services #------------------------------------------------------------------------------ # Verify the Block Storage installation -# http://docs.openstack.org/ocata/install-guide-ubuntu/launch-instance-cinder.html +# https://docs.openstack.org/install-guide/launch-instance-cinder.html # (partial implementation without instance) #------------------------------------------------------------------------------ diff --git a/labs/osbash/scripts/ubuntu/setup_glance.sh b/labs/osbash/scripts/ubuntu/setup_glance.sh index 0b8da55d..72c3b058 100755 --- a/labs/osbash/scripts/ubuntu/setup_glance.sh +++ b/labs/osbash/scripts/ubuntu/setup_glance.sh @@ -14,7 +14,7 @@ indicate_current_auto #------------------------------------------------------------------------------ # Install the Image Service (glance). -# http://docs.openstack.org/ocata/install-guide-ubuntu/glance-install.html +# https://docs.openstack.org/glance/pike/install/install-ubuntu.html #------------------------------------------------------------------------------ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -133,7 +133,7 @@ sudo service glance-api restart #------------------------------------------------------------------------------ # Verify the Image Service installation -# http://docs.openstack.org/ocata/install-guide-ubuntu/glance-verify.html +# https://docs.openstack.org/glance/pike/install/verify.html #------------------------------------------------------------------------------ echo -n "Waiting for glance to start." diff --git a/labs/osbash/scripts/ubuntu/setup_heat_controller.sh b/labs/osbash/scripts/ubuntu/setup_heat_controller.sh index a0a8e4c8..52ddd2e5 100755 --- a/labs/osbash/scripts/ubuntu/setup_heat_controller.sh +++ b/labs/osbash/scripts/ubuntu/setup_heat_controller.sh @@ -17,7 +17,7 @@ wait_for_keystone #------------------------------------------------------------------------------ # Install the Orchestration Service (heat) -# http://docs.openstack.org/project-install-guide/orchestration/ocata/install-ubuntu.html +# https://docs.openstack.org/heat/pike/install/install-ubuntu.html #------------------------------------------------------------------------------ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -205,8 +205,8 @@ ENDTIME=$(date +%s) echo "Restarting heat servies took $((ENDTIME - STARTTIME)) seconds." #------------------------------------------------------------------------------ -# Verify operation of Orchestration Service (heat). -# http://docs.openstack.org/project-install-guide/orchestration/ocata/verify.html +# Verify operation +# https://docs.openstack.org/heat/pike/install/verify.html #------------------------------------------------------------------------------ echo "Listing service components." diff --git a/labs/osbash/scripts/ubuntu/setup_horizon.sh b/labs/osbash/scripts/ubuntu/setup_horizon.sh index 9a4b062d..3c89ec37 100755 --- a/labs/osbash/scripts/ubuntu/setup_horizon.sh +++ b/labs/osbash/scripts/ubuntu/setup_horizon.sh @@ -13,7 +13,7 @@ indicate_current_auto #------------------------------------------------------------------------------ # Set up OpenStack Dashboard (horizon) -# http://docs.openstack.org/ocata/install-guide-ubuntu/horizon-install.html +# https://docs.openstack.org/horizon/pike/install/install-ubuntu.html #------------------------------------------------------------------------------ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -30,17 +30,6 @@ echo "Installing horizon." sudo apt install -y openstack-dashboard # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -# XXX changing owner/permissions (work-around for packaging bug -- the -# Dashboard will not work without it) -sudo ls -l /var/lib/openstack-dashboard/ -sudo namei -l /var/lib/openstack-dashboard/ - -sudo chown www-data:www-data /var/lib/openstack-dashboard -sudo chown www-data:www-data /var/lib/openstack-dashboard/secret_key -sudo chmod 700 /var/lib/openstack-dashboard -sudo chmod 600 /var/lib/openstack-dashboard/secret_key -# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # Edit the /etc/openstack-dashboard/local_settings.py file. conf=/etc/openstack-dashboard/local_settings.py auth_host=controller @@ -71,7 +60,7 @@ echo "memcached listening on $interface_ip:$port." interface_name=$(getent hosts "$auth_host" | awk '{ print $2 }') # Line should read something like: 'LOCATION' : 'controller:11211', -if grep "LOCATION.*$interface_name:$port" $conf; then +if sudo grep "LOCATION.*$interface_name:$port" $conf; then echo "$conf agrees." else echo >&2 "$conf disagrees. Aborting." @@ -79,7 +68,7 @@ else fi echo "CACHES configuration in $conf:" -awk '/^CACHES =/,/^}/' $conf +sudo awk '/^CACHES =/,/^}/' $conf # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - echo "Enabling Identity API version 3." diff --git a/labs/osbash/scripts/ubuntu/setup_keystone.sh b/labs/osbash/scripts/ubuntu/setup_keystone.sh index 9b548287..9bb5ec65 100755 --- a/labs/osbash/scripts/ubuntu/setup_keystone.sh +++ b/labs/osbash/scripts/ubuntu/setup_keystone.sh @@ -15,9 +15,13 @@ indicate_current_auto #------------------------------------------------------------------------------ # Set up keystone for controller node -# http://docs.openstack.org/ocata/install-guide-ubuntu/keystone-install.html +# https://docs.openstack.org/keystone/pike/install/keystone-install-ubuntu.html #------------------------------------------------------------------------------ +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Prerequisites +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + echo "Setting up database for keystone." setup_database keystone "$KEYSTONE_DB_USER" "$KEYSTONE_DBPASS" @@ -34,7 +38,7 @@ mysql -u keystone -p"$KEYSTONE_DBPASS" keystone -h controller -e quit # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - echo "Installing keystone." -sudo apt install -y keystone +sudo apt install -y keystone apache2 libapache2-mod-wsgi conf=/etc/keystone/keystone.conf echo "Editing $conf." @@ -101,9 +105,6 @@ sudo sed -i --follow-symlinks '/WSGIDaemonProcess/ s/processes=[0-9]*/processes= echo "Restarting apache." sudo service apache2 restart -echo "Removing default SQLite database." -sudo rm -f /var/lib/keystone/keystone.db - # Set environment variables for authentication export OS_USERNAME=$ADMIN_USER_NAME export OS_PASSWORD=$ADMIN_PASS @@ -115,7 +116,7 @@ export OS_IDENTITY_API_VERSION=3 #------------------------------------------------------------------------------ # Create a domain, projects, users, and roles -# http://docs.openstack.org/ocata/install-guide-ubuntu/keystone-users.html +# https://docs.openstack.org/keystone/pike/install/keystone-users.html #------------------------------------------------------------------------------ # Wait for keystone to come up @@ -148,7 +149,7 @@ openstack role add \ #------------------------------------------------------------------------------ # Verify operation -# http://docs.openstack.org/ocata/install-guide-ubuntu/keystone-verify.html +# https://docs.openstack.org/keystone/pike/install/keystone-verify-ubuntu.html #------------------------------------------------------------------------------ echo "Verifying keystone installation." @@ -163,13 +164,11 @@ sudo ls -l $conf # From this point on, we are going to use keystone for authentication unset OS_AUTH_URL OS_PASSWORD -# XXX If the default domain ID is default and the default domain name is -# Default, why are we using default here? echo "Requesting an authentication token as an admin user." openstack \ --os-auth-url http://controller:35357/v3 \ - --os-project-domain-name default \ - --os-user-domain-name default \ + --os-project-domain-name Default \ + --os-user-domain-name Default \ --os-project-name "$ADMIN_PROJECT_NAME" \ --os-username "$ADMIN_USER_NAME" \ --os-auth-type password \ @@ -179,8 +178,8 @@ openstack \ echo "Requesting an authentication token for the demo user." openstack \ --os-auth-url http://controller:5000/v3 \ - --os-project-domain-name default \ - --os-user-domain-name default \ + --os-project-domain-name Default \ + --os-user-domain-name Default \ --os-project-name "$DEMO_PROJECT_NAME" \ --os-username "$DEMO_USER_NAME" \ --os-auth-type password \ diff --git a/labs/osbash/scripts/ubuntu/setup_neutron_compute.sh b/labs/osbash/scripts/ubuntu/setup_neutron_compute.sh index 968cc3a0..c05f572c 100755 --- a/labs/osbash/scripts/ubuntu/setup_neutron_compute.sh +++ b/labs/osbash/scripts/ubuntu/setup_neutron_compute.sh @@ -14,8 +14,8 @@ exec_logfile indicate_current_auto #------------------------------------------------------------------------------ -# Set up OpenStack Networking (neutron) for compute node. -# http://docs.openstack.org/ocata/install-guide-ubuntu/neutron-compute-install.html +# Install and configure compute node +# https://docs.openstack.org/neutron/pike/install/compute-install-ubuntu.html #------------------------------------------------------------------------------ echo "Installing networking components for compute node." diff --git a/labs/osbash/scripts/ubuntu/setup_neutron_compute_part_2.sh b/labs/osbash/scripts/ubuntu/setup_neutron_compute_part_2.sh index c885e1cd..af460f4f 100755 --- a/labs/osbash/scripts/ubuntu/setup_neutron_compute_part_2.sh +++ b/labs/osbash/scripts/ubuntu/setup_neutron_compute_part_2.sh @@ -14,12 +14,12 @@ exec_logfile indicate_current_auto #------------------------------------------------------------------------------ -# Set up OpenStack Networking (neutron) for compute node. -# http://docs.openstack.org/ocata/install-guide-ubuntu/neutron-compute-install.html +# Install and configure compute node +# https://docs.openstack.org/neutron/pike/install/compute-install-ubuntu.html #------------------------------------------------------------------------------ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -# Configure Compute to use Networking +# Configure the Compute service to use the Networking service # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - neutron_admin_user=neutron @@ -48,7 +48,7 @@ sudo service neutron-linuxbridge-agent restart #------------------------------------------------------------------------------ # Networking Option 2: Self-service networks -# http://docs.openstack.org/ocata/install-guide-ubuntu/neutron-verify-option2.html +# https://docs.openstack.org/neutron/pike/install/verify-option2.html #------------------------------------------------------------------------------ echo "Sourcing the admin credentials." @@ -56,5 +56,5 @@ source "$CONFIG_DIR/admin-openstackrc.sh" echo "Listing agents to verify successful launch of the neutron agents." -echo "neutron agent-list" -neutron agent-list +echo "openstack network agent list" +openstack network agent list diff --git a/labs/osbash/scripts/ubuntu/setup_neutron_controller.sh b/labs/osbash/scripts/ubuntu/setup_neutron_controller.sh index b5dc9e87..e42a9663 100755 --- a/labs/osbash/scripts/ubuntu/setup_neutron_controller.sh +++ b/labs/osbash/scripts/ubuntu/setup_neutron_controller.sh @@ -13,10 +13,14 @@ exec_logfile indicate_current_auto #------------------------------------------------------------------------------ -# Set up OpenStack Networking (neutron) for controller node. -# http://docs.openstack.org/ocata/install-guide-ubuntu/neutron-controller-install.html +# Install and configure controller node +# https://docs.openstack.org/neutron/pike/install/controller-install-ubuntu.html #------------------------------------------------------------------------------ +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Prerequisites +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + echo "Setting up database for neutron." setup_database neutron "$NEUTRON_DB_USER" "$NEUTRON_DBPASS" diff --git a/labs/osbash/scripts/ubuntu/setup_neutron_controller_part_2.sh b/labs/osbash/scripts/ubuntu/setup_neutron_controller_part_2.sh index 374fed15..0cde0005 100755 --- a/labs/osbash/scripts/ubuntu/setup_neutron_controller_part_2.sh +++ b/labs/osbash/scripts/ubuntu/setup_neutron_controller_part_2.sh @@ -14,7 +14,7 @@ indicate_current_auto #------------------------------------------------------------------------------ # Set up OpenStack Networking (neutron) for controller node. -# http://docs.openstack.org/ocata/install-guide-ubuntu/neutron-controller-install.html +# https://docs.openstack.org/neutron/pike/install/controller-install-ubuntu.html #------------------------------------------------------------------------------ source "$CONFIG_DIR/admin-openstackrc.sh" @@ -34,7 +34,7 @@ iniset_sudo $conf DEFAULT nova_metadata_ip controller iniset_sudo $conf DEFAULT metadata_proxy_shared_secret "$METADATA_SECRET" # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -# Configure Compute to use Networking +# Configure the Compute service to use the Networking service # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - echo "Configuring Compute to use Networking." @@ -84,14 +84,14 @@ fi #------------------------------------------------------------------------------ # Set up OpenStack Networking (neutron) for controller node. -# http://docs.openstack.org/ocata/install-guide-ubuntu/neutron-verify.html +# https://docs.openstack.org/neutron/pike/install/verify-option2.html #------------------------------------------------------------------------------ echo -n "Verifying operation." -until openstack extension list --network >/dev/null 2>&1; do +until openstack network agent list >/dev/null 2>&1; do sleep 1 echo -n . done echo -openstack extension list --network +openstack network agent list diff --git a/labs/osbash/scripts/ubuntu/setup_nova_compute.sh b/labs/osbash/scripts/ubuntu/setup_nova_compute.sh index 0eaf953f..766af690 100755 --- a/labs/osbash/scripts/ubuntu/setup_nova_compute.sh +++ b/labs/osbash/scripts/ubuntu/setup_nova_compute.sh @@ -15,7 +15,7 @@ indicate_current_auto #------------------------------------------------------------------------------ # Install and configure a compute node -# http://docs.openstack.org/ocata/install-guide-ubuntu/nova-compute-install.html +# https://docs.openstack.org/nova/pike/install/compute-install-ubuntu.html #------------------------------------------------------------------------------ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -118,12 +118,12 @@ sudo service nova-compute restart echo echo -n "Confirming that the compute host is in the database." AUTH="source $CONFIG_DIR/admin-openstackrc.sh" -node_ssh controller "$AUTH; openstack hypervisor list" -until node_ssh controller "$AUTH; openstack hypervisor list | grep 'compute1.*up'" >/dev/null 2>&1; do +node_ssh controller "$AUTH; openstack compute service list --service nova-compute" +until node_ssh controller "$AUTH; openstack compute service list --service nova-compute | grep 'compute1.*up'" >/dev/null 2>&1; do sleep 2 echo -n . done -node_ssh controller "$AUTH; openstack hypervisor list" +node_ssh controller "$AUTH; openstack compute service list --service nova-compute" echo echo "Discovering compute hosts." @@ -131,13 +131,9 @@ echo "Run this command on controller every time compute hosts are added to" \ "the cluster." node_ssh controller "sudo nova-manage cell_v2 discover_hosts --verbose" -# Not in install-guide: -# Remove SQLite database created by Ubuntu package for nova. -sudo rm -v /var/lib/nova/nova.sqlite - #------------------------------------------------------------------------------ # Verify operation -# http://docs.openstack.org/ocata/install-guide-ubuntu/nova-verify.html +# https://docs.openstack.org/nova/pike/install/verify.html #------------------------------------------------------------------------------ echo "Verifying operation of the Compute service." @@ -152,3 +148,7 @@ openstack catalog list echo "Listing images to verify connectivity with the Image service." echo "openstack image list" openstack image list + +echo "Checking the cells and placement API are working successfully." +echo "on controller node: nova-status upgrade check" +node_ssh controller "sudo nova-status upgrade check" diff --git a/labs/osbash/scripts/ubuntu/setup_nova_controller.sh b/labs/osbash/scripts/ubuntu/setup_nova_controller.sh index eaa2ca12..acb2d9aa 100755 --- a/labs/osbash/scripts/ubuntu/setup_nova_controller.sh +++ b/labs/osbash/scripts/ubuntu/setup_nova_controller.sh @@ -14,7 +14,7 @@ indicate_current_auto #------------------------------------------------------------------------------ # Install Compute controller services -# http://docs.openstack.org/ocata/install-guide-ubuntu/nova-controller-install.html +# https://docs.openstack.org/nova/pike/install/controller-install-ubuntu.html #------------------------------------------------------------------------------ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/labs/osbash/scripts/ubuntu/setup_self-service_compute.sh b/labs/osbash/scripts/ubuntu/setup_self-service_compute.sh index b277ee64..facfa2c8 100755 --- a/labs/osbash/scripts/ubuntu/setup_self-service_compute.sh +++ b/labs/osbash/scripts/ubuntu/setup_self-service_compute.sh @@ -14,7 +14,7 @@ indicate_current_auto #------------------------------------------------------------------------------ # Networking Option 2: Self-service networks -# http://docs.openstack.org/ocata/install-guide-ubuntu/neutron-compute-install-option2.html +# https://docs.openstack.org/neutron/pike/install/compute-install-option2-ubuntu.html #------------------------------------------------------------------------------ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/labs/osbash/scripts/ubuntu/setup_self-service_controller.sh b/labs/osbash/scripts/ubuntu/setup_self-service_controller.sh index 8b554f39..19bd0b6e 100755 --- a/labs/osbash/scripts/ubuntu/setup_self-service_controller.sh +++ b/labs/osbash/scripts/ubuntu/setup_self-service_controller.sh @@ -15,7 +15,7 @@ indicate_current_auto #------------------------------------------------------------------------------ # Networking Option 2: Self-service networks -# http://docs.openstack.org/ocata/install-guide-ubuntu/neutron-controller-install-option2.html +# https://docs.openstack.org/neutron/pike/install/controller-install-option2-ubuntu.html #------------------------------------------------------------------------------ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -136,6 +136,8 @@ echo "Configuring the layer-3 agent." conf=/etc/neutron/l3_agent.ini iniset_sudo $conf DEFAULT interface_driver linuxbridge +# FIXME The following block (comment and change to external_network_bridge +# disappeared in the docs transition to Pike. Intentionally? # The external_network_bridge option intentionally lacks a value to enable # multiple external networks on a single agent. iniset_sudo $conf DEFAULT external_network_bridge ""