Update, back up and uninstall
Automatic updates
Section titled “Automatic updates”GPU Kitchen updates itself. Once a day, inside a time slot, it moves to the current release. Your models keep serving while it updates. Only the app restarts.
Open Settings → Updates to see:
- the version that runs now;
- the next update, with its version and time;
- the Daily slot. It is 03:00 to 05:00 by default, in the cluster’s time zone. Only the owner can change it;
- the past updates, with their result.
An update waits for work that cannot resume, such as a running benchmark or a model download. It then moves to the next day’s slot. After three postponed slots, it applies anyway.
Every release is signed. GPU Kitchen checks the signature before it installs anything. It never moves to an older release.
Before a release that changes the database, GPU Kitchen saves a copy of it next to the original. Keep at least twice the size of the database free on the disk.
If the new version does not start, GPU Kitchen keeps the previous one running. Your data is not
touched. gpuk logs shows why the new version failed.
Update now
Section titled “Update now”On the controller, run either:
sudo gpuk updateor the install command again:
curl -fsSL https://gpu.kitchen/install.sh | sudo shOn a machine that already runs GPU Kitchen, the install command keeps all your settings and runs
gpuk update. It updates gpuk itself, the GPU Kitchen service and the app.
gpuk update --checkcompares your version with the current release.gpuk update --version vX.Y.Zmoves to a given release.gpuk statusshows your version and whether an update exists.
On a GPU node, sudo gpuk update updates the node. The controller also brings its nodes to its
own version after it updates.
Back up the database
Section titled “Back up the database”sudo gpuk backupIt saves the database while the app keeps running. The copy goes under
/var/lib/gpu-kitchen/backups/ unless you name another folder.
Copy the backup to another machine. Keep the cluster’s encryption key with it, from the data
folder (/var/lib/gpu-kitchen/secrets): without it, the backup cannot be read.
sudo gpuk backup --offsite copies it to encrypted S3 storage for you, once
/etc/gpu-kitchen/offsite.env names that storage; the copy tool comes with GPU Kitchen.
To back up every day, run sudo gpuk backup-timer on, or sudo gpuk backup-timer on --offsite
to copy each backup off the machine too. It is off until you turn it on. Each daily run keeps a
week of its own backups on the machine. sudo gpuk backup-timer off stops it.
During the beta, a backup does not bring a lost machine back as it was. You install GPU Kitchen again, then bring back your recipes and benchmarks from the backup, as described below. Accounts, keys, nodes and settings are lost: you set them up again.
If your cluster uses its own PostgreSQL server, back up that server with its own tools instead.
Keep your recipes and benchmarks on a new database
Section titled “Keep your recipes and benchmarks on a new database”Some releases cannot update an older database. You then install GPU Kitchen on a new database. Your recipes and benchmark results can come with you:
- Before you reinstall, run
sudo gpuk backup. - Install the new release, and open it once so that it creates its database.
- Run:
sudo gpuk carry-over /var/lib/gpu-kitchen/backups/<backup folder>It checks the backup, stops the app for a moment, copies the rows and starts the app again. It
also reads a backup that an older release of the same epoch made the earlier way, with the app
stopped. You can also give it a file made by pg_dump -Fc.
A backup made by a release of another epoch, the first two numbers of its version, is refused: such a release starts from zero, and nothing of the previous epoch comes with you.
It copies your recipes, templates, benchmarks, evaluations, baskets and saved charts, with the engines, models and GPU configurations they use. It does not copy nodes, GPUs, My cookbook, accounts, keys or settings. Benchmarks that were waiting for another cluster wait on yours again.
Run it on a new cluster. If the database already has recipes or benchmarks of its own, it
stops and copies nothing. --replace deletes them first and takes the backup’s instead.
Uninstall
Section titled “Uninstall”sudo gpuk uninstallIt removes only the GPU Kitchen service. The app, your settings and your data stay. Run
sudo gpuk install with the same options to bring the service back.
sudo gpuk uninstall --purgeIt also removes the app, its settings in /etc/gpu-kitchen, the node identity and gpuk itself.
It never deletes the data folder (/var/lib/gpu-kitchen by default): the database, the models and
the encryption key stay there. Delete that folder yourself if you want them gone. A later install
on the same folder reuses them.
On a GPU node, remove the node from Nodes & GPU on the controller too.
