Legacy Upgrade Support
This website/page will be End-of-life (EOL) after 31 August 2024. We recommend you to visit OpenEBS Documentation for the latest Mayastor documentation (v2.6 and above).
Mayastor is now also referred to as OpenEBS Replicated PV Mayastor.
A legacy installation of Mayastor (1.0.5 and below) cannot be seamlessly upgraded and needs manual intervention. Follow the below steps if you wish to upgrade from Mayastor 1.0.x to Mayastor 2.1.0 and above. Mayastor uses etcd as a persistent datastore for its configuration. As a first step, take a snapshot of the etcd. The detailed steps for taking a snapshot can be found in the etcd documentation.
As compared to Mayastor 1.0, the Mayastor 2.0 feature-set introduces breaking changes in some of the components, due to which the upgrade process from 1.0 to 2.0 is not seamless. The list of such changes are given below: ETCD:
Control Plane: The prefixes for control plane have changed from
/namespace/$NAMESPACE/control-plane/
to/openebs.io/mayastor/apis/v0/clusters/$KUBE_SYSTEM_UID/namespaces/$NAMESPACE/
Data Plane: The Data Plane nexus information containing a list of healthy children has been moved from
$nexus_uuid
to/openebs.io/mayastor/apis/v0/clusters/$KUBE_SYSTEM_UID/namespaces/$NAMESPACE/volume/$volume_uuid/nexus/$nexus_uuid/info
RPC:
Control Plane: The RPC for the control plane has been changed from NATS to gRPC.
Data Plane: The registration heartbeat has been changed from NATS to gRPC.
Pool CRDs:
The pool CRDs have been renamed
DiskPools
(previously, MayastorPools).
In order to start the upgrade process, the following previously deployed components have to be deleted.
To delete the control-plane components, execute:
Next, delete the associated RBAC operator. To do so, execute:
In the above command, add the previously installed Mayastor version in the format v1.x.x
Once all the above components have been successfully removed, fetch the latest helm chart from Mayastor-extension repo and save it to a file, say
helm_templates.yaml
. To do so, execute:
Next, update the
helm_template.yaml
file, add the following helm label to all the resources that are being created.
Copy the
etcd
andio-engine
spec from thehelm_templates.yaml
and save it in two different files say, mayastor_2.0_etcd.yaml and mayastor_io_v2.0.yaml. Once done, remove theetcd
andio-engine
specs fromhelm_templates.yaml
. These components need to be upgraded separately.
Install the new control-plane components using the
helm-templates.yaml
file.
In the above method of installation, the nexus (target) High Availability (HA) is disabled by default. The steps to enable HA are described later in this document.
Verify the status of the pods. Upon successful deployment, all the pods will be in a running state.
Verify the etcd prefix and compat mode.
Verify if the DiskPools are online.
Next, verify the status of the volumes.
After upgrading control-plane components, the data-plane pods have to be upgraded. To do so, deploy the
io-engine
DaemonSet from Mayastor's new version.
Using the command given below, the data-plane pods (now io-engine pods) will be upgraded to Mayastor v2.0.
Delete the previously deployed data-plane pods (
mayastor-xxxxx
). The data-plane pods need to be manually deleted as their update-strategy is set todelete
. Upon successful deletion, the newio-engine
pods will be up and running.NATS has been replaced by gRPC for Mayastor versions 2.0 or later. Hence, the NATS components (StatefulSets and services) have to be removed from the cluster.
After
control-plane
andio-engine
, the etcd has to be upgraded. Before starting the etcd upgrade, label the etcd PV and PVCs with helm. Use the below example to create alabels.yaml
file. This will be needed to make them helm compatible.
Next, deploy the etcd YAML. To deploy, execute:
Now, verify the etcd space and compat mode, execute:
Once all the components have been upgraded, the HA module can now be enabled via the helm upgrade command.
This concludes the process of legacy upgrade. Run the below commands to verify the upgrade,
Last updated