Tips on how to Use DigitalOcean Backups and Snapshots – CloudSavvy IT

Posted on

DigitalOcean logo

How’s your backup technique? You may shield your cloud property from catastrophe by making common backups. Right here’s find out how to use DigitalOcean’s two imaging programs, Backups and Snapshots.

What’s The Distinction?

Backups and Snapshots each produce an entire disk picture of your droplet at a specific cut-off date. You may restore the droplet’s state utilizing the picture. DigitalOcean additionally allows you to spin up a brand new droplet with the backup or snapshot picture as its base.

The distinction lies in how the picture is created. “Backups” is a fully-managed automated system. Backups are enabled on a per-droplet foundation. When lively, DigitalOcean will create a disk picture every week. The backup will probably be retained for 4 weeks, so that you’ll have 4 completely different restoration choices.

Backups add one other 20% to the month-to-month value of your droplet. They’re saved in the identical datacentre as your droplet, so it’s believable – though maybe inconceivable – {that a} datacentre-wide outage or pure catastrophe might stop you utilizing your backups.

Snapshots are on-demand photographs. You create them manually, utilizing the Management Panel or the API. As soon as created, snapshots persist in your account indefinitely, till you explicitly delete them.

Snapshots are billed primarily based on their measurement. You’ll pay $0.05/GiB per 30 days. Snapshots are created in the identical datacentre as your droplet. You may make snapshots out there in different datacentre areas on a per-snapshot foundation.

In contrast to backups, snapshots aren’t restricted to droplets. You too can create snapshots of your Block Storage Volumes. You must think about periodically snapshotting your volumes as they received’t be included in droplet snapshots or backups.

Setting Up Droplet Backups

Let’s have a look at organising automated droplet backups first.

Login to your Digital Management Panel. Click on any droplet on the homepage. Then, on the droplet particulars web page, click on the “Backups” hyperlink within the sidebar. You’ll see an “Allow Backups” button. Click on the button to activate backups.

DigitalOcean robotically allocates you a weekly backup window which you’ll’t change or customise. The web page will present you what your backup schedule is; till your schedule is run, no backups will probably be out there to your droplet.

You may automate backup setup by utilizing Doctl, DigitalOcean’s command-line shopper. When you’re authenticated, run doctl compute droplet listing to get the listing of droplets in your account. Observe down the ID of the droplet you need to configure.

Subsequent, setup backups for the droplet:

doctl compute droplet-action enable-backups <droplet-id>

As soon as backups have been created, you may listing them utilizing one other command:

doctl compute droplet backups <droplet-id>

Restoring a Backup

You may view your 4 retained backups on the backside of a droplet’s Backups web page. Click on the “Extra” button to see the out there choices.

You may restore your droplet by clicking “Restore Droplet” and acknowledging the affirmation immediate. It will overwrite your present droplet with the contents of the backup.

The “Create Droplet” choice provides you one other restoration technique. It will allow you to configure a brand new droplet utilizing the backup as its preliminary picture. You’ll be taken to the droplet creation web page to decide on the {hardware} plan to your new droplet.

Lastly, you may convert backups into snapshots. This allows you to maintain a backup indefinitely, past the tip of the default month-to-month retention interval. You too can use snapshots to switch backup information into a brand new datacentre area.


To handle snapshots within the net interface, choose a droplet and click on the “Snapshots” hyperlink in its sidebar.

You create new snapshots utilizing the controls on the prime of the web page. Give the snapshot a reputation and click on “Take stay snapshot”. It will seize the droplet with out powering it off. If it is advisable assure information consistency, you must shutdown the droplet earlier than taking the snapshot.

Snapshot creation takes as much as 1 minute per GB of knowledge utilized by your droplet. The snapshot will present up beneath “Droplet snapshots” when the method completes.

To snapshot a quantity, click on the Volumes hyperlink within the left sidebar. Click on the “Extra” button subsequent to any of your volumes. Press “Take snapshot” and provides your snapshot a reputation. Quantity snapshots require an identical creation time to droplet snapshots.

You may entry all of your droplet and quantity snapshots from the “Photos” hyperlink within the sidebar. Use the “Droplets” and “Volumes” tabs to see your snapshots.

The “Extra” menu allows you to create a droplet from the snapshot, restore the droplet (or quantity) utilizing the snapshot, or switch the snapshot into one other area. The latter choice allows you to subsequently create a brand new droplet in a special datacentre that makes use of the snapshot as its base picture.

You may orchestrate snapshot actions utilizing Doctl. Listed below are some useful instructions when working with snapshots:

# Get all snapshots saved for a droplet
doctl compute droplet snapshots <droplet-id>

# Create a snapshot of a droplet
doctl compute droplet-action snapshot <droplet-id>

# Create a snapshot of a quantity
doctl compute quantity snapshot <volume-id>

# Record all snapshots in your account
doctl compute snapshot listing

# Delete a snapshot
doctl compute snapshot delete <snapshot-id>

Use the compute droplet listing, compute quantity listing and compute snapshot listing instructions to get the useful resource IDs to provide to the snapshot instructions proven above.

Backing Up Different DigitalOcean Assets

Backups are just for droplets; Snapshots are for droplets and volumes. You may’t use them with some other DigitalOcean useful resource sort.

You must think about the way you’ll backup your different DigitalOcean information. The platform’s managed providers – reminiscent of Managed Databases and Spaces object storage – do have built-in backups inside DigitalOcean’s infrastructure. It’s possible you’ll need to manually backup to a different cloud supplier within the curiosity of making certain redundancy.


DigitalOcean Backups are a set-it-and-forget-it strategy to backups which ought to “simply work” for many gentle workloads. Nevertheless, the weekly schedule and same-datacentre storage received’t work for something business-critical. If that’s the case, you must think about periodic snapshots or a customized backup system.

Snapshots are best if you’re about to make a significant droplet configuration change. You may snapshot your machine to offer you a restoration choice within the occasion of failure. The portability of snapshots allows you to transfer information between DigitalOcean areas with out having to manually switch something.

Source link

Gravatar Image
I love to share everything with you

Leave a Reply

Your email address will not be published. Required fields are marked *