Thursday 13 August 2020

A useful tool - snapshots: how they are created and what they can do

Data security and safety is an important issue for any business. Unlike physical servers, clouds have much broader capabilities. For example, you can completely restore a virtual machine disk from the past. This is available thanks to the useful tool snapshots. Earlier we already wrote what it is and why they are called a time machine. Now let's tell in more detail under what conditions snapshots are created and how storage of two snapshots of each disk of the client virtual machine is achieved.

What are snapshots and why are they needed

Snapshots are complete snapshots of customer virtual machine disks that we create on a regular basis. For all users of TuchaFlex + and TuchaBit services, we take snapshots and store the last two of them for each client disk. The cost of creating and storing snapshots is already included in the cost of renting servers.  

What are snapshots for? A snapshot can be used to restore a machine disk to the state it was in when the snapshot was taken. Also, the snapshot can be uploaded for further use as an image of a new virtual machine, or added as an additional disk to any server within our cloud infrastructure.

How snapshots are created tech support engineer job description

Let's recall how snapshots are created. The virtual machine is stopped during the snapshot creation. The pause can last from a few seconds to several minutes - it all depends on the size of the disk and the size of the data that has changed since the last snapshot. At this time, the snapshot has the status Creating . When the snapshot is taken, it gets the BackingUp statusand the virtual machine resumes its work. Then the snapshot is copied from the main storage to the backup. This process takes from several minutes to several hours, the exact time depends on the volume of the disc. This does not affect the operation of the virtual machine. After that, the snapshot is deleted from the main storage, and the virtual machine is briefly stopped at this time. When the snapshot is deleted from the main storage, the virtual machine will continue to work, and the snapshot saved in the backup storage will receive the BackedUp status . 

In what order are the images taken? In the queue, those disks for which the last saved snapshot was created before the others have higher priority. There is an intelligent algorithm that determines their queue, taking into account the "age" of the last images and the load on the infrastructure.

Is it possible to change the time of taking pictures

For a specific virtual machine, you can shift the snapshot time or make the interval narrower. However, it is worth considering this: if you narrow the time period too much, then the likelihood that the picture will be taken during this period is significantly reduced. This is because another likelihood increases: at the specified time interval, the storage will already create a snapshot of another disk. Therefore, if the user still wants to narrow the time interval for taking pictures, we recommend setting the gap width at least 3-4 hours. 

A virtual machine can also give up its turn in another case: if at the moment when the snapshot queue comes up to it, it performs operations with a disk with an intensity of more than 1024 KB / s. It is for this reason that pictures are not always taken strictly every night.

You can of course ignore the shared queue and virtual machine activity metrics. That is, to create pictures strictly at certain hours and days (for example, once a day at 4:20). However, there are certain risks involved. For example, there is a risk of data corruption inside the server itself, since the operating system, when creating a snapshot, may start recording any data that will not be added due to a pause in the virtual machine, which is necessary to take a snapshot. As a result, the file system can theoretically lose its consistency (integrity), which will lead to damage or loss of some data.

If the customer finds it convenient to take a different snapshot time, you can change the schedule. To do this, you just need to contact our technical support service , and we will organize everything.

Tags on pictures

Noremove

Any snapshot can be noremove tagged with a value of 1 . This means that it will not be automatically deleted, changed or overwritten (although it can be deleted manually). This label should be placed on the snapshot itself, not on the virtual machine or disk. Note that when both snapshots are marked with noremove , new snapshots will be created, but not saved. This means that actual pictures will not appear.

Nosnapshot

Also, a virtual machine or its disk can be marked with a nosnapshot label with a value of 1 . In this case, automatic snapshots for them will not be created until the mark is removed.

An important point to note that concerns both noremove and nosnapshot tags. The Value field should contain the exact time of the labels.

No comments:

Post a Comment

What You Can Model with the Heat Transfer Module

Conduction, Convection, and Radiation Analyses The Heat Transfer Module can be used to study the three types of heat transfer in detail, exp...