How to perform admin tasks¶
Backups¶
To backup your Oasis at least the file data and mongodb data needs to be saved. You determined the path to your file data (your uploads) during the installation. By
default all data is stored in a directory called .volumes
that is created in the
current working directory of your installation/docker-compose. This directory can be backed up like any other file backup (e.g. rsync).
To backup the mongodb, please refer to the official mongodb documentation. We suggest a simple mongodump export that is backed up alongside your files. The default configuration mounts .volumes/mongo
into the mongodb container (as /backup
) for this purpose. You can use this to export the NOMAD mongo database. Combine this with rsync on the .volumes
directory and everything should be set. To create a new mongodump run:
The elasticsearch contents can be reproduced with the information in the files and the mongodb.
To create a new oasis with the backup data, create the .volumes
directory from your backup. Start the new oasis. Use mongorestore:
Now you still have to recreate the elasticsearch index:
Managing data with the CLI¶
The NOMAD command line interface (CLI) provides a few useful administrative functions. To use the NOMAD CLI, open a shell into the app container and run it from there:
For example you can ls or remove uploads:
You can also reset the processing (of "stuck") uploads and reprocess:
You can also use the CLI to wipe the whole installation:
Upload commands¶
The nomad admin uploads
group of CLI commands allow you to inspect and modify
all or some uploads in your installation. Sub-commands include ls
, rm
,
chown
, process
(see below), index
(see below).
The command group takes many different parameters to target specific subsets of uploads. Here are a few examples:
--unpublished
--published
--outdated
Select published uploads with older NOMAD versions than the current--processing-failure
Uploads with processing failures.
For a complete list refer to the CLI reference documentation.
Alternatively, you can use a list of upload ids at the end of the command, e.g.:
If you have a list of ids (e.g. in a file), you could use xargs
:
Re-processing¶
Processing includes the conversion of raw files into NOMAD entries. Files are parsed, normalizers are called, the processing results are stored, and the search index is updated. In certain scenarios (failed processing, migration, changed plugins) might require that admins process certain uploads again.
Re-Indexing¶
Each NOMAD entry is represented in NOMAD's search index. Only if an entry is in this index, you can find it via the search interface. Some changes between NOMAD versions (see also our update guide), might require that you re-index all uploads.