Switch storage back ends

To facilitate online garbage collection, switching storage back ends initializes a new metadata store and erases your existing tags. As a best practice, you should always move, back up, and restore MSR storage back ends together with your metadata.

Kubernetes deployments

To switch your storage back end to Amazon S3 using the MSR Operator:

  1. Add the following values to the custom resource manifest. If you are using IAM role authentication, do not include the lines for accesskey and secretkey. Running Kubernetes on AWS requires that you include v4auth: true.

    spec:
      registry:
        storage:
          backend: "s3"
          s3:
            region: <region>
            bucket: <bucket-name>
            accesskey: <access-key>
            secretkey: <secret-key>
            v4auth: true
          persistentVolume:
            size: <size>
    
  2. Apply these changes to the custom resource:

    kubectl apply -f cr-sample-manifest.yaml
    
  3. Verify that the reconciliation process for the custom resource is complete:

    kubectl get msrs.msr.mirantis.com
    kubectl get rethinkdbs.rethinkdb.com
    

To switch your storage back end to Amazon S3 using a Helm chart:

helm upgrade msr msrofficial/msr \
--set registry.storage.backend=s3 \
--set registry.storage.s3.accesskey=<> \
--set registry.storage.s3.secretkey=<> \
--set registry.storage.s3.region=us-east-2 \
--set registry.storage.s3.bucket=testing-msr-kube

Swarm deployments

  1. SSH into a manager node on the Swarm cluster on which you are running MSR.

  2. Edit your values.yaml file to include the new storage back end:

    registry:
      storage:
        backend: '<storage-backend>'
    
  3. Obtain a list of non-manager nodes along with their node IDs, noting the IDs of the nodes on which MSR is installed:

    docker node ls --format "{{ .ID }}" --filter "role=worker"
    
  4. Update your MSR deployment, specifying a node ID for each node on which MSR is installed:

    docker run -it \
      --rm \
      -v /var/run/docker.sock:/var/run/docker.sock \
      -v <path-to-values.yml>:/config/values.yml \
      msr-installer \
      upgrade \
      --node <node-id>
    
  5. Review the status of the deployed services:

    docker stack services msr