Virtual Server Snapshots¶
A Snapshot is a local backup of a virtual server disk. A snapshot does not take up any disk capacity at the time of creation. The disk capacity is consumed only by changes performed on the disk after the snapshot’s creation.
Creating a snapshot and performing a rollback are instant operations. It is recommended to create a snapshot before performing any non-trivial action inside the virtual server.
Snapshots are stored on the same node storage as virtual server disks used for the snapshots. Failure of a node storage, therefore, results in loss of snapshots.
Name - Snapshot name (read-only).
Disk ID - Virtual server disk ID (read-only).
Type - Snapshot type (read-only). One of:
Created - The date and time when the snapshot was created (read-only).
Status - Snapshot state (read-only). One of:
Size - The approximate size of the snapshot (read-only).
The snapshot size parameter is automatically updated once every hour.
Snapshots created with the Freeze filesystem option enabled are marked with a flag icon appended to their status.
Advanced Snapshot Parameters¶
- Freeze filesystem? - Whether to create an application-consistent snapshot (KVM only). Requires QEMU Guest Agent to be running inside the virtual server.
Create snapshot - Immediately create a snapshot from one or all virtual server’s disks.
Delete snapshot - Remove data of the snapshot.
Rollback snapshot - Restore server disk data from the snapshot.
A snapshot rollback will lead to deletion of all data including every newer snapshot created after the restored snapshot.
It is also possible to restore a snapshot into another virtual server. This functionality is currently available only in the API (
PUT /vm/(hostname_or_uuid)/snapshot/(snapname)) .
A Snapshot Definition is a configuration based on which periodic snapshots are automatically created and deleted.
Snapshot Definition Parameters¶
- Name - Snapshot definition name.
- Disk ID - Virtual server disk ID.
- Schedule - Automatic scheduler configuration in Cron format. Use your local time for the hour field (it will be internally converted into UTC).
- Retention - Maximum number of snapshots to keep. After exceeding this number of snapshots, the oldest snapshot associated with the snapshot definition will be automatically removed.
- Active - Whether the snapshot definition is active.
Advanced Snapshot Definition Parameters¶
- Freeze filesystem? - Whether to create application-consistent snapshots (KVM only). Requires QEMU Guest Agent to be running inside the virtual server.
Cron format is a flexible way to define time and frequency of running a periodic task. It is defined as a string of five fields separated by a space.
|Field name||Allowed values|
|Day of month||1-31|
|Month||1-12 (January - December)|
|Day of week||0-6 (Sunday - Saturday)|
30 08 10 06 *- Run a task once every year on June 10 at 8:30 AM.
00 11,16 * * *- Run a task twice a day at 11:00 AM and 4:00 PM.
00 09-17 * * *- Run a task once every hour between 9:00 AM and 5:00 PM.
00 09-18 * * 1-5- Run a task once every hour between 9:00 AM and 5:00 PM from Monday till Friday.
* * * * *- Run a task once every minute.
0,10,20,30,40,50 * * * *- Run a task once every 10 minutes.
0,2,4,6,8,10 * * * *- Run a task every 2 minutes during the first 10 minutes of a hour.
0 0 1 1 *- Run a task once a year at midnight of January 1.
0 0 * * *- Run a task once a day at midnight.
0 * * * *- Run a task once an hour at the beginning of the hour.
Creating an Image From a Snapshot¶
Name - Unique image identifier (usually used in the API).
Alias - A user-defined name of an image (usually displayed in the GUI).
Version - Image version.
Access - Image visibility. One of:
- Public - Image is usable by all users in this virtual data center.
- Private - Image is usable by SuperAdmins and owners of this image.
- Deleted - Image is hidden and unusable for new servers, but can be still used by some already defined servers.
Owner - Image owner.
Tags - Comma-separated list of image tags, which will be inherited by virtual servers that will use this image.
Resizable? (Resize) - Specifies whether an image is able to resize a virtual disk during an initial start or deploy procedure. This is usually achieved by a post-installation script that has to be included in the disk image.
Shutdown after deploy? (Deploy) - Specifies whether an image is able to shut down a virtual server after an initial start. Such an image should include a post-installation script, which will shut down the running operating system after it has been successfully configured. After a virtual server is stopped, it is considered to be successfully deployed, and it will be automatically started by the system.
More information about disk images can be found in a separate chapter.