diff --git a/Documentation/flexMigration/flex-to-csi-migration.md b/Documentation/flexMigration/flex-to-csi-migration.md new file mode 100644 index 0000000000000..d8f9817dbb008 --- /dev/null +++ b/Documentation/flexMigration/flex-to-csi-migration.md @@ -0,0 +1,31 @@ +--- +title: Migration +weight: 4100 +indent: true +--- + +# Flex to CSI Migration + +The tool [persistent-volume-migrator](https://github.com/ceph/persistent-volume-migrator) aims to help migrate Flex rbd Volumes to Ceph-Csi. + +## Prerquisite + +This guide assumes you have created a Rook cluster with Flex +1) Minimum ceph version should be Ceph-CSI supported. +2) Volume should be in BOUND state and should **not** be in use. + +**NOTE**: The Migration procedure will come with a downtime; As we need to scale down the applications using the Volumes before migration. + +## Steps +1) Create rbac required to run migrator pod + 1) `kubectl create -f cluster/examples/kubernetes/ceph/flex-migration/rbac.yaml` +2) Create migrator pod + 1) `kubectl create -f cluster/examples/kubernetes/ceph/flex-migration/migrator.yaml` +3) Run command to start migration: + 1) To migrate single PVC: + 1) ` --pvc=rbd-pvc --pvc-namespace=default --destinationstorageclass=csi-rook-ceph-block` + 1) `--pvc` reads name of the pvc to migrate + 2) `--pvc-namespace` reads the namespace of the PVC which is going to migrate + 3) `--destinationstorageclass` read the name of the storageclass in which you want mirgrate. + 2) To mirage all the pvc in storageclass: + 1) WIP