Updating
Updating MicroShift clusters
Abstract
Chapter 1. About Red Hat build of MicroShift updates Copy linkLink copied to clipboard!
Updates are supported on Red Hat build of MicroShift beginning with the General Availability version 4.14. With the 4.16 release, the following updates are supported:
- A maximum of two minor versions to the next in sequence, for example, from 4.14 to 4.16.
- One minor version to the next in sequence, for example, from 4.15 to 4.16.
- Patch updates are also supported from z-stream to z-stream, for example 4.16.1 to 4.16.2.
1.1. Understanding MicroShift updates Copy linkLink copied to clipboard!
Red Hat build of MicroShift updates are supported on both rpm-ostree
edge-deployed hosts and non-OSTree hosts. You can complete updates using the following methods:
-
Embed the latest version of MicroShift in a new
rpm-ostree
system image such as Red Hat Enterprise Linux for Edge (RHEL for Edge). See Applying updates on an OSTree system - Manually update the RPMs on a non-OSTree system such as Red Hat Enterprise Linux (RHEL). See Applying updates manually with RPMs
Only rpm-ostree
updates include automatic rollbacks.
1.1.1. RPM OSTree updates Copy linkLink copied to clipboard!
Using the RHEL for Edge rpm-ostree
update path allows for automated backup and system rollback in case any part of the update fails. You must build a new rpm-ostree
image and embed the new MicroShift version in that image. The rpm-ostree
image can be the same version or an updated version, but the versions of RHEL for Edge and MicroShift must be compatible.
Check following compatibility table for details:
Red Hat Device Edge release compatibility matrix
Red Hat Enterprise Linux (RHEL) and MicroShift work together as a single solution for device-edge computing. You can update each component separately, but the product versions must be compatible. Supported configurations of Red Hat Device Edge use verified releases for each together as listed in the following table:
RHEL for Edge Version(s) | MicroShift Version | MicroShift Release Status | Supported MicroShift Version→MicroShift Version Updates |
9.4 | 4.16 | Generally Available | 4.16.0→4.16.z, 4.14→4.16 and 4.15→4.16 |
9.2, 9.3 | 4.15 | Generally Available | 4.15.0→4.15.z, 4.14→4.15 and 4.15→4.16 |
9.2, 9.3 | 4.14 | Generally Available | 4.14.0→4.14.z, 4.14→4.15 and 4.14→4.16 |
9.2 | 4.13 | Technology Preview | None |
8.7 | 4.12 | Developer Preview | None |
1.1.2. Manual RPM updates Copy linkLink copied to clipboard!
You can use the manual RPM update path to replace your existing version of MicroShift. The versions of RHEL and MicroShift must be compatible. Ensuring system health and completing additional system backups are manual processes.
Ensure that your version of RHEL is compatible with the version of MicroShift you are updating to, especially if you are updating MicroShift across two minor versions.
1.1.3. Checking version update path Copy linkLink copied to clipboard!
Before updating MicroShift or {op-system}, determine the compatibilities. Plan for the versions of each that you intend to use.
Red Hat build of MicroShift update paths
- MicroShift version 4.16
- Version 4.16 to 4.16.z on {op-system} or RHEL for Edge 9.4
- MicroShift version 4.15
- Version 4.15 on {op-system} or RHEL for Edge 9.2 or 9.3 to 4.16 on {op-system} or RHEL for Edge 9.4
- Version 4.15 to 4.15.z on {op-system} or RHEL for Edge 9.2 or 9.3
- MicroShift version 4.14
- Version 4.14 on {op-system} or RHEL for Edge 9.2 or 9.3 to 4.16 on {op-system} or RHEL for Edge 9.4
- Version 4.14 to 4.15 on {op-system} or RHEL for Edge 9.2 or 9.3
- Version 4.14 to 4.14.z on {op-system} or RHEL for Edge 9.2 or 9.3
Chapter 2. Update options for Red Hat Device Edge Copy linkLink copied to clipboard!
To update Red Hat Device Edge, you can update both Red Hat build of MicroShift and Red Hat Enterprise Linux (RHEL), or each part by itself without updating the other. You must keep the parts in a supported configuration. Consider the following options when planning updates to your current deployments.
2.1. Red Hat Device Edge updates Copy linkLink copied to clipboard!
You can update Red Hat Enterprise Linux (RHEL) operating system independently of your Red Hat build of MicroShift version if the version combination is supported. See the following table for details:
Red Hat Device Edge release compatibility matrix
Red Hat Enterprise Linux (RHEL) and MicroShift work together as a single solution for device-edge computing. You can update each component separately, but the product versions must be compatible. Supported configurations of Red Hat Device Edge use verified releases for each together as listed in the following table:
RHEL for Edge Version(s) | MicroShift Version | MicroShift Release Status | Supported MicroShift Version→MicroShift Version Updates |
9.4 | 4.16 | Generally Available | 4.16.0→4.16.z, 4.14→4.16 and 4.15→4.16 |
9.2, 9.3 | 4.15 | Generally Available | 4.15.0→4.15.z, 4.14→4.15 and 4.15→4.16 |
9.2, 9.3 | 4.14 | Generally Available | 4.14.0→4.14.z, 4.14→4.15 and 4.14→4.16 |
9.2 | 4.13 | Technology Preview | None |
8.7 | 4.12 | Developer Preview | None |
Keeping component versions in a supported configuration of Red Hat Device Edge can require updating MicroShift and RHEL at the same time. Ensure that your version of RHEL is compatible with the version of MicroShift you are updating to, especially if you are updating MicroShift across two minor versions. Otherwise, you can create an unsupported configuration, break your node, or both. For more information, see the Red Hat Device Edge release compatibility matrix.
2.2. Standalone MicroShift updates Copy linkLink copied to clipboard!
You can update just your MicroShift version by embedding the new version in a RHEL image or by installing the RPMs on a standard RHEL operating system. Consider your current operating system version and deployments when planning a MicroShift update.
The following factors apply to a standalone MicroShift version update:
- MicroShift operates as an in-place update and does not require removal of the earlier version.
- Data backups beyond those required for the usual functioning of your applications are not required.
- You can potentially update MicroShift without reinstalling your applications and Operators.
-
Only
rpm-ostree
updates include automatic rollbacks.
You must update RHEL to update MicroShift if your current operating system is not compatible with the new version of MicroShift that you want to use.
2.2.1. Updating MicroShift on RHEL for Edge Copy linkLink copied to clipboard!
You can have automated backup and system rollback in case any part of the update fails by using the rpm-ostree
update path for a new or existing RHEL for Edge deployment.
-
You can update MicroShift on an
rpm-ostree
system such as RHEL for Edge by building a new system image containing the new version of MicroShift. -
The
rpm-ostree
image can be the same version or an updated version, but the versions of RHEL for Edge and MicroShift must be compatible.
The following features are available in the RHEL for Edge update path:
- The system automatically rolls back to an earlier healthy system state if the update fails.
- You do not need to reinstall applications.
- You do not need to reinstall Operators.
- You can update an application without updating MicroShift using this update type.
- The image you build can contain other updates as needed.
To begin a MicroShift update by embedding the new version in a RHEL for Edge image, use the procedures in the following documentation:
To understand more about greenboot, see the following documentation:
2.2.2. Manual RPM updates Copy linkLink copied to clipboard!
You can update MicroShift manually on Red Hat Enterprise Linux (RHEL) by updating the RPMs. This type of update is useful for development environments and testing.
- To complete this update type, use the subscription manager to enable the repository that has the new RPMs.
- Use manual processes to ensure system health and complete additional system backups.
- To begin a manual RPM update, use the procedures in the following documentation:
- About updating MicroShift RPMs manually
2.2.2.1. Keeping MicroShift and RHEL in a supported configuration Copy linkLink copied to clipboard!
When using RPM updates, avoid creating an unsupported configuration or breaking your node by carefully managing your RHEL repositories.
Prerequisites
- You understand the support status of the version of MicroShift you are using.
- You have root-user access to your build host.
- You reviewed the Red Hat Device Edge release compatibility matrix.
Procedure
Avoid unintended updates by locking your operating system version by running the following command:
sudo subscription-manager release --set=<x.y>
$ sudo subscription-manager release --set=<x.y>
1 Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
- Replace <x.y> with the major and minor version of your compatible RHEL system. For example, 9.4.
Update both MicroShift and RHEL versions by running the following command:
sudo subscription-manager release --set=<9.4> command.
$ sudo subscription-manager release --set=<9.4> command.
1 Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
- Replace <9.4> with the major and minor version of your compatible RHEL system.
If you are using an EUS MicroShift release, disable the RHEL standard-support-scope repositories by running the following command:
sudo subscription-manager repos \ --disable=rhel-<9>-for-x86_64-appstream-rpms \ --disable=rhel-<9>-for-x86_64-baseos-rpms
$ sudo subscription-manager repos \ --disable=rhel-<9>-for-x86_64-appstream-rpms \
1 --disable=rhel-<9>-for-x86_64-baseos-rpms
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
- Replace <9> with the major version of your compatible RHEL system.
After you disable the standard-support repositories, enable the RHEL EUS repos by running the following command:
sudo subscription-manager repos \ --enable rhel-<9>-for-x86_64-appstream-eus-rpms \ --enable rhel-<9>-for-x86_64-baseos-eus-rpms`
$ sudo subscription-manager repos \ --enable rhel-<9>-for-x86_64-appstream-eus-rpms \
1 --enable rhel-<9>-for-x86_64-baseos-eus-rpms`
Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
- Replace <9> with the major version of your compatible RHEL system.
Verification
List the repositories you have enabled for RHEL by running the following command:
sudo subscription-manager repos --list-enabled
$ sudo subscription-manager repos --list-enabled
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Example output
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
2.3. Standalone RHEL updates Copy linkLink copied to clipboard!
You can update to any RHEL type without updating MicroShift if the two final versions in your Red Hat Device Edge are compatible. Check compatibilities before beginning an update. Use the RHEL documentation specific to your use case.
For example:
2.4. Simultaneous MicroShift and RHEL updates Copy linkLink copied to clipboard!
You can update your RHEL operating system type and update MicroShift at the same time, if the final versions are a supported configuration of Red Hat Device Edge. You can use following workflow to plan the general steps to take:
- Check for compatibility before beginning an update.
- Use the RHEL documentation specific to your update path to plan and update the operating system.
- Enable the correct MicroShift repository to ensure alignment between your RHEL and MicroShift versions.
- Use the MicroShift update type specific to your update path, such as using an RPM installation or embedding MicroShift into an operating system image.
Chapter 3. Updating RPMs on a RHEL for Edge system Copy linkLink copied to clipboard!
You can update MicroShift on Red Hat Enterprise Linux for Edge (RHEL for Edge) by embedding the new version of MicroShift on a new operating system image. The procedures are the same for minor-version and patch updates. For example, use the same steps to upgrade from 4.16 to 4.18 or from 4.16.2 to 4.16.3.
Downgrades are not supported. The following procedure is for upgrades only.
3.1. MicroShift updates on an RHEL for Edge system Copy linkLink copied to clipboard!
Updating MicroShift on a Red Hat Enterprise Linux for Edge (RHEL for Edge) system requires building a new RHEL for Edge image containing the new version of MicroShift and any associated optional RPMs. After you create the rpm-ostree
image with MicroShift embedded, you can boot into that operating system image.
The procedures are the same for minor-version and patch updates. For example, use the same steps to upgrade from 4.16 to 4.17 or from 4.17.2 to 4.17.3. The following details apply:
- Back up and system rollback are automatic with this update type.
- You can use the following workflow to update applications running in the MicroShift node. Ensure compatibilities between the application and the adjacent versions of MicroShift and RHEL for Edge before starting an update.
Downgrades other than automatic rollbacks are not supported. The following procedure is for updates only.
ImportantThe steps you use depends on how your existing deployment is set up. The following procedure outlines the general steps you can take, with links to the RHEL for Edge documentation. The RHEL for Edge documentation is your resource for specific details on building an updated operating system image.
3.2. Applying updates on an OSTree system Copy linkLink copied to clipboard!
To update MicroShift on Red Hat Enterprise Linux for Edge (RHEL for Edge), embed the new version of MicroShift on a new operating system image.
Prerequisites
- The system requirements for installing MicroShift have been met.
- You have root user access to the host.
- The version of MicroShift you have is compatible with the RHEL for Edge image you are preparing to use.
You cannot downgrade MicroShift with this process. Downgrades are not supported.
Procedure
Create an image builder configuration file for adding the
rhocp-4.16
RPM repository source required to pull MicroShift RPMs by running the following command:Copy to Clipboard Copied! Toggle word wrap Toggle overflow Add the update RPM source to the image builder by running the following command:
sudo composer-cli sources add rhocp-4.16.toml
$ sudo composer-cli sources add rhocp-4.16.toml
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Build a new image of RHEL for Edge that contains the new version of MicroShift. To determine the steps required, use the following documentation:
Update the host to use the new image of RHEL for Edge. To determine the steps required, use the following documentation:
Reboot the host to apply updates by running the following command:
sudo systemctl reboot
$ sudo systemctl reboot
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
Chapter 4. Updating RPMs manually Copy linkLink copied to clipboard!
Updating Red Hat build of MicroShift for non-image-based Red Hat Enterprise Linux (RHEL) systems requires updating the RPMs. For patch releases, such as 4.16.1 to 4.16.2, simply update the RPMs. For minor-version release updates, add the step of enabling the update repository by using your subscription manager.
You can back up application data as needed and move the data copy to a secure location when using any update type.
4.1. Applying patch updates using RPMs Copy linkLink copied to clipboard!
Updating MicroShift on non rpm-ostree
systems such as Red Hat Enterprise Linux (RHEL) requires downloading then updating the RPMs. For example, use the following procedure to upgrade from 4.16.1 to 4.16.2.
Keeping component versions in a supported configuration of Red Hat Device Edge can require updating MicroShift and RHEL at the same time. Ensure that your version of RHEL is compatible with the version of MicroShift you are updating to, especially if you are updating MicroShift across two minor versions. Otherwise, you can create an unsupported configuration, break your node, or both. For more information, see the Red Hat Device Edge release compatibility matrix.
Prerequisites
- The system requirements for installing MicroShift have been met.
- You have root user access to the host.
- The version of MicroShift you have is compatible to upgrade to the version you are preparing to use.
- You have verified that your host operating system is compatible with the version of MicroShift you are preparing to install.
- You have completed a system backup.
You cannot downgrade MicroShift with this process. Downgrades are not supported.
Procedure
Update the MicroShift RPMs by running the following command:
sudo dnf update microshift
$ sudo dnf update microshift
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
The system health check runs on this update type, but does not perform any actions. If the update fails, an error message appears with the instruction to check the logs.
4.2. Applying minor-version updates with RPMs Copy linkLink copied to clipboard!
Updating a MicroShift minor version on non rpm-ostree
systems such as Red Hat Enterprise Linux (RHEL) requires downloading then updating the RPMs. For example, use the following procedure to update from 4.15 to 4.16.
You can only update MicroShift from one version to the next in sequence. Jumping minor versions is not supported. For example, must update 4.15 to 4.16.
Prerequisites
- The system requirements for installing MicroShift have been met.
- You have root user access to the host.
- The version of MicroShift you have is compatible to upgrade to the version you are preparing to use.
- You have verified that your host operating system is compatible with the version of MicroShift you are preparing to install.
- You have completed a system backup.
You cannot downgrade MicroShift with this process. Downgrades are not supported.
Procedure
For all lifecycles, enable the repository for the release you want to update to by running the following command:
sudo subscription-manager repos \ --enable rhocp-4.16-for-rhel-9-$(uname -m)-rpms \ --enable fast-datapath-for-rhel-9-$(uname -m)-rpms
$ sudo subscription-manager repos \ --enable rhocp-4.16-for-rhel-9-$(uname -m)-rpms \ --enable fast-datapath-for-rhel-9-$(uname -m)-rpms
Copy to Clipboard Copied! Toggle word wrap Toggle overflow For extended support (EUS) releases, also enable the EUS repositories by running the following command:
sudo subscription-manager repos \ --enable rhel-9-for-$(uname -m)-appstream-eus-rpms \ --enable rhel-9-for-$(uname -m)-baseos-eus-rpms
$ sudo subscription-manager repos \ --enable rhel-9-for-$(uname -m)-appstream-eus-rpms \ --enable rhel-9-for-$(uname -m)-baseos-eus-rpms
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Avoid unintended future updates into an unsupported configuration by locking your operating system version with the following command:
sudo subscription-manager release --set=9.4
$ sudo subscription-manager release --set=9.4
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Update the MicroShift RPMs by running the following command:
sudo dnf update microshift
$ sudo dnf update microshift
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Reboot the host to apply updates by running the following command:
sudo systemctl reboot
$ sudo systemctl reboot
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
The system health check runs on this update type, but does not perform any actions. If the update fails, an error message appears with the instruction to check the logs.
Verification
Check if the health checks exited with a successful boot by running the following command:
sudo systemctl status greenboot-healthcheck
$ sudo systemctl status greenboot-healthcheck
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Check the health check logs by running the following command:
sudo journalctl -u greenboot-healthcheck
$ sudo journalctl -u greenboot-healthcheck
Copy to Clipboard Copied! Toggle word wrap Toggle overflow
Chapter 5. Listing RPM update package contents Copy linkLink copied to clipboard!
You can preview the contents of a MicroShift RPM package update before installing. This helps you make sure that the update you are planning is a supported configuration of Red Hat Device Edge.
5.1. Listing the contents of the MicroShift RPM release package Copy linkLink copied to clipboard!
To see the images included with a MicroShift release, you can list the contents of the microshift-release-info
RPM by downloading and unpacking the RPM.
Prerequisites
- You are using Red Hat Enterprise Linux (RHEL) or an operating system with an RPM package manager.
- Your MicroShift repositories are enabled.
Procedure
Optional: List which versions of the MicroShift RPM are available for download by running the following command:
sudo dnf repoquery microshift-release-info-0:4.16.*
$ sudo dnf repoquery microshift-release-info-0:4.16.*
1 Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
- Replace the example value
4.16.*
with the major and minor release numbers you are interested in.
Example output
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Download the RPM package you want by running the following command:
sudo dnf download microshift-release-info-<release_version>
$ sudo dnf download microshift-release-info-<release_version>
1 Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
- Replace
<release_version>
with the numerical value of the release you are deploying, using the entire version number, for example,4.16.0
.
Example output
microshift-release-info-4.16.0.-202311101230.p0.g7dc6a00.assembly.4.16.0.el9.noarch.rpm
microshift-release-info-4.16.0.-202311101230.p0.g7dc6a00.assembly.4.16.0.el9.noarch.rpm
1 Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
- Your output should contain the date and commit ID.
Unpack the RPM package without installing it by running the following command:
rpm2cpio <microshift_release_info> | cpio -idmv
$ rpm2cpio <microshift_release_info> | cpio -idmv
1 Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
- Replace
<microshift_release_info>
with the name of the RPM package from the previous step. For example,microshift-release-info-4.16.10-202408291007.p0.g6e4ee4d.assembly.4.16.10.el9.noarch.rpm
.
Example output
Copy to Clipboard Copied! Toggle word wrap Toggle overflow List the contents by running the following command:
cat ./usr/share/microshift/release/release-x86_64.json
$ cat ./usr/share/microshift/release/release-x86_64.json
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Example output
Copy to Clipboard Copied! Toggle word wrap Toggle overflow