vmrestore
vmrestore
restores data from backups created by vmbackup.
Restore process can be interrupted at any time. It is automatically resumed from the interruption point when restarting vmrestore
with the same args.
Usage #
VictoriaMetrics must be stopped during the restore process.
Run the following command to restore backup from the given -src
into the given -storageDataPath
:
./vmrestore -src=<storageType>://<path/to/backup> -storageDataPath=<local/path/to/restore>
Shell HelpCopy
<storageType>://<path/to/backup>
is the path to backup made with vmbackup.vmrestore
can restore backups from the following storage types:GCS. Example:
-src=gs://<bucket>/<path/to/backup>
S3. Example:
-src=s3://<bucket>/<path/to/backup>
Azure Blob Storage. Example:
-src=azblob://<container>/<path/to/backup>
Any S3-compatible storage such as MinIO, Ceph or Swift. See these docs for details.
Local filesystem. Example:
-src=fs://</absolute/path/to/backup>
. Note thatvmbackup
prevents from storing the backup into the directory pointed by-storageDataPath
command-line flag, since this directory should be managed solely by VictoriaMetrics orvmstorage
.<local/path/to/restore>
is the path to folder where data will be restored. This folder must be passed to VictoriaMetrics in-storageDataPath
command-line flag after the restore process is complete.
The original -storageDataPath
directory may contain old files. They will be substituted by the files from backup, i.e. the end result would be similar to rsync –delete.
Troubleshooting #
If
vmrestore
eats all the network bandwidth, then set-maxBytesPerSecond
to the desired value.If
vmrestore
has been interrupted due to temporary error, then just restart it with the same args. It will resume the restore process.