11.3. Updating the Overcloud
11.3.1. Configuration Agent
Important
stack
user on the director host and source the Undercloud configuration:
source ~/stackrc
$ source ~/stackrc
55-heat-config
) to each Overcloud node. Use the following command to do this for all hosts:
for i in `nova list|awk '/Running/ {print $(NF-1)}'|awk -F"=" '{print $NF}'`; do echo $i; scp -o StrictHostKeyChecking=no /usr/share/openstack-heat-templates/software-config/elements/heat-config/os-refresh-config/configure.d/55-heat-config heat-admin@${i}: ; ssh -o StrictHostKeyChecking=no heat-admin@${i} 'sudo /bin/bash -c "cp /home/heat-admin/55-heat-config /usr/libexec/os-refresh-config/configure.d/55-heat-config"'; done
$ for i in `nova list|awk '/Running/ {print $(NF-1)}'|awk -F"=" '{print $NF}'`; do echo $i; scp -o StrictHostKeyChecking=no /usr/share/openstack-heat-templates/software-config/elements/heat-config/os-refresh-config/configure.d/55-heat-config heat-admin@${i}: ; ssh -o StrictHostKeyChecking=no heat-admin@${i} 'sudo /bin/bash -c "cp /home/heat-admin/55-heat-config /usr/libexec/os-refresh-config/configure.d/55-heat-config"'; done
heat-config-rebuild-deployed
script on each node. Use the following command to do this for all nodes:
for i in `nova list|awk '/Running/ {print $(NF-1)}'|awk -F"=" '{print $NF}'`; do echo $i; scp -o StrictHostKeyChecking=no /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin/heat-config-rebuild-deployed heat-admin@${i}: ; ssh -o StrictHostKeyChecking=no heat-admin@${i} 'sudo /bin/bash -c "mkdir -p /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin ; cp heat-config-rebuild-deployed /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin/heat-config-rebuild-deployed ; chmod +x /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin/heat-config-rebuild-deployed ; /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin/heat-config-rebuild-deployed"' ; done
$ for i in `nova list|awk '/Running/ {print $(NF-1)}'|awk -F"=" '{print $NF}'`; do echo $i; scp -o StrictHostKeyChecking=no /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin/heat-config-rebuild-deployed heat-admin@${i}: ; ssh -o StrictHostKeyChecking=no heat-admin@${i} 'sudo /bin/bash -c "mkdir -p /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin ; cp heat-config-rebuild-deployed /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin/heat-config-rebuild-deployed ; chmod +x /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin/heat-config-rebuild-deployed ; /usr/share/openstack-heat-templates/software-config/elements/heat-config/bin/heat-config-rebuild-deployed"' ; done
11.3.2. Modified Overcloud Templates
Important
/usr/share/openstack-tripleo-heat-templates/
.
- Backup your existing custom template collection:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow mv ~/templates/my-overcloud/ ~/templates/my-overcloud.bak
$ mv ~/templates/my-overcloud/ ~/templates/my-overcloud.bak
- Replace the new version of the template collection from
/usr/share/openstack-tripleo-heat-templates
:Copy to Clipboard Copied! Toggle word wrap Toggle overflow sudo cp -rv /usr/share/openstack-tripleo-heat-templates ~/templates/my-overcloud/
# sudo cp -rv /usr/share/openstack-tripleo-heat-templates ~/templates/my-overcloud/
- Check for differences between the old and new custom template collection. To see changes between the two, use the following
diff
command:Copy to Clipboard Copied! Toggle word wrap Toggle overflow diff -Nary ~/templates/my-overcloud.bak/ ~/templates/my-overcloud/
# diff -Nary ~/templates/my-overcloud.bak/ ~/templates/my-overcloud/
This helps identify customizations from the old template collection that you can incorporate into the new template collection. - Incorporate customization into the new custom template collection.
Important
/usr/share/openstack-tripleo-heat-templates
. Red Hat recommends using the methods from the following section instead of modifying the Heat template collection:
git
.
11.3.3. New Environment Parameters
~/templates/param-updates.yaml
):
New Parameter
|
Description
|
---|---|
ControlPlaneDefaultRoute
|
The default route of the control plane network.
|
EC2MetadataIp
|
The IP address of the EC2 metadata server.
|
parameter_defaults: ControlPlaneDefaultRoute: 192.168.1.1 EC2MetadataIp: 169.254.169.254
parameter_defaults:
ControlPlaneDefaultRoute: 192.168.1.1
EC2MetadataIp: 169.254.169.254
11.3.4. Version Specific Notes
If you started with OpenStack Platform director 7.0 and are upgrading to OpenStack Platform director 7.2 or later:
- Be sure to provide the same value for the
ServiceNetMap
parameter that was used on the initial cloud deployment (see Section 6.2.6.3, “Assigning OpenStack Services to Isolated Networks”. If a custom value was used on the initial deployment, provide the same custom value. If you are updating from 7.0 and used no customServiceNetMap
value on the initial deployment, include the following environment file in the update command to preserve the 7.0 value:/usr/share/openstack-tripleo-heat-templates/environments/updates/update-from-keystone-admin-internal-api.yaml
Make sure to include this file on any subsequent updates of the Overcloud.Changing the value ofServiceNetMap
after Overcloud creation is not currently supported. - If using a single network for the Overcloud (for example, the original deployment did not include
network-isolation.yaml
) then include the following environment file in the update command:/usr/share/openstack-tripleo-heat-templates/environments/updates/update-from-publicvip-on-ctlplane.yaml
Make sure to include this file on any subsequent updates of the Overcloud. Note that you do not need this file if using an external load balancer.
If you started with OpenStack Platform director 7.1 and are upgrading to OpenStack Platform director 7.2 or later:
- Be sure to provide the same value for the
ServiceNetMap
parameter that was used on the initial cloud deployment (see Section 6.2.6.3, “Assigning OpenStack Services to Isolated Networks”. If a custom value was used on the initial deployment, provide the same custom value. If you are updating from 7.1 and used no custom value forServiceNetMap
on the initial deployment, then no additional environment file or value needs to be provided forServiceNetMap
. Changing the value ofServiceNetMap
after Overcloud creation is not currently supported. - Include the following environment file in the update command to make sure the VIP resources remain mapped to
vip.yaml
:/usr/share/openstack-tripleo-heat-templates/environments/updates/update-from-vip.yaml
Make sure to include this file on any subsequent updates of the Overcloud. Note that you do not need this file if using an external load balancer. - If updating from 7.1 and not using external load balancer, provide the control VIP for the
control_virtual_ip
input parameter. This is because the resource is replaced during the upgrade. To do so, find the current control_virtual_ip address with:Copy to Clipboard Copied! Toggle word wrap Toggle overflow neutron port-show control_virtual_ip | grep ip_address
$ neutron port-show control_virtual_ip | grep ip_address {"subnet_id": "3d7c11e0-53d9-4a54-a9d7-55865fcc1e47", "ip_address": "192.0.2.21"} |
Add it into a custom environment file, such as~/templates/param-updates.yaml
from Section 11.3.3, “New Environment Parameters”, as follows:Copy to Clipboard Copied! Toggle word wrap Toggle overflow parameters: ControlFixedIPs: [{'ip_address':'192.0.2.21'}]
parameters: ControlFixedIPs: [{'ip_address':'192.0.2.21'}]
Make sure to include this file on any subsequent updates of the Overcloud. Note that you do not need this file if using an external load balancer.Delete the existing Neutron port:Copy to Clipboard Copied! Toggle word wrap Toggle overflow neutron port-delete control_virtual_ip
$ neutron port-delete control_virtual_ip
The update process replaces this VIP with a new port using the original IP address.
If upgrading from OpenStack Platform director 7.2 to OpenStack Platform director 7.3 or later:
- Heat on the Undercloud requires an increase in the RPC response timeout to accomodate a known issue (see BZ#1305947). Edit the
/etc/heat/heat.conf
and set the following parameter:Copy to Clipboard Copied! Toggle word wrap Toggle overflow rpc_response_timeout=600
rpc_response_timeout=600
Then restart all Heat services:Copy to Clipboard Copied! Toggle word wrap Toggle overflow systemctl restart openstack-heat-api.service systemctl restart openstack-heat-api-cfn.service systemctl restart openstack-heat-engine.service
$ systemctl restart openstack-heat-api.service $ systemctl restart openstack-heat-api-cfn.service $ systemctl restart openstack-heat-engine.service
11.3.5. Updating the Overcloud Packages
openstack overcloud update
from the director.
-e
to include environment files relevant to your Overcloud and its upgrade path. The order of the environment files is important as the parameters and resources defined in subsequent environment files take precedence. Use the following list as an example of the environment file order:
- The
overcloud-resource-registry-puppet.yaml
file from the Heat template collection. Although this file is included automatically when you run theopenstack overcloud deploy
command, you must include this file when you run theopenstack overcloud update
command. - Any network isolation files, including the initialization file (
environments/network-isolation.yaml
) from the Heat template collection and then your custom NIC configuration file. See Section 6.2.6, “Isolating all Networks into VLANs” for more information on network islocation. - Any external load balancing environment files.
- Any storage environment files.
- Any environment files for Red Hat CDN or Satellite registration.
- Any version-specific environment files from Section 11.3.4, “Version Specific Notes”.
- Any other custom environment files.
-i
option, which puts the command in an interactive mode that requires confirmation at each breakpoint. Without the -i
option, the update remains paused at the first breakpoint.
openstack overcloud update stack overcloud -i \ --templates \ -e /usr/share/openstack-tripleo-heat-templates/overcloud-resource-registry-puppet.yaml \ -e /usr/share/openstack-tripleo-heat-templates/environments/network-isolation.yaml \ -e /home/stack/templates/network-environment.yaml \ -e /home/stack/templates/storage-environment.yaml \ -e /home/stack/templates/rhel-registration/environment-rhel-registration.yaml \ -e /usr/share/openstack-tripleo-heat-templates/environments/updates/update-from-vip.yaml \ -e /home/stack/templates/param-updates.yaml
$ openstack overcloud update stack overcloud -i \
--templates \
-e /usr/share/openstack-tripleo-heat-templates/overcloud-resource-registry-puppet.yaml \
-e /usr/share/openstack-tripleo-heat-templates/environments/network-isolation.yaml \
-e /home/stack/templates/network-environment.yaml \
-e /home/stack/templates/storage-environment.yaml \
-e /home/stack/templates/rhel-registration/environment-rhel-registration.yaml \
-e /usr/share/openstack-tripleo-heat-templates/environments/updates/update-from-vip.yaml \
-e /home/stack/templates/param-updates.yaml
not_started: [u'overcloud-controller-0', u'overcloud-controller-1', u'overcloud-controller-2'] on_breakpoint: [u'overcloud-compute-0'] Breakpoint reached, continue?
not_started: [u'overcloud-controller-0', u'overcloud-controller-1', u'overcloud-controller-2']
on_breakpoint: [u'overcloud-compute-0']
Breakpoint reached, continue?
on_breakpoint
list. This begins the update for that node. You can also type a node name to clear a breakpoint on a specific node, or a regular expression to clear breakpoints on mulitple nodes at once. However, it is not recommended to clear breakpoints on multiple controller nodes at once. Continue this process until all nodes have complete their update.
Important
Important
sudo pcs property set stonith-enabled=true
$ sudo pcs property set stonith-enabled=true