GSTT-CSC / MLOps

Framework for building ML apps
GNU General Public License v3.0
9 stars 5 forks source link

Update minio #100

Closed laurencejackson closed 1 year ago

laurencejackson commented 1 year ago

We have been using a very old version of minio that is incompatible with future releases, to avoid technical debt we should move to the new versions.

This PR makes the following changes:

Since the new version of minio is not compatible with the old version we need to migrate the old files over to the new one. Our minio is so old that the migration process published by minio didn't work (https://blog.min.io/deprecation-of-the-minio-gateway/), I kept coming across errors when trying to import configs or export metadata. I have done a simple filesystem mirror locally though and that seems to have worked. Instructions below:

We need to start two instances of minio to mirror them. First we need to separate the existing data new data directory. mv <minio data dir> <new location>

Then we need to recreate the old directory mkdir <minio data dir>

After this we can start the old minio using a simple docker run: docker run -p 9000:9000 --name minio_old -v <new location>:/data -e 'MINIO_ROOT_USER=minio' -e 'MINIO_ROOT_PASSWORD=qwer1234!' minio/minio:RELEASE.2021-03-17T02-33-02Z server /data

Then we can start the new server docker compose up -d --build

Then we need to set aliases using mc mc alias set oldminio http://localhost:9000 USER PWD mc alias set newminio http://localhost:8002 USER PWD

Then we can start the migration: mc mirror --preserve oldminio/mlflow newminio/mlflow

github-actions[bot] commented 1 year ago

Coverage

Coverage Report
FileStmtsMissCoverMissing
mlops
   Experiment.py1442980%45–50, 65–66, 83, 85, 90, 160–174, 192, 194–195, 236–237, 241, 243–246, 250–251, 261
   ProjectFile.py22195%38
   cli.py16160%1–46
mlops/data/tools
   tools.py353111%14–67
mlops/data/transforms
   LoadImageXNATd.py382729%21–25, 47–90
TOTAL28210463% 

Tests Skipped Failures Errors Time
13 2 :zzz: 0 :x: 0 :fire: 2m 32s :stopwatch: