Question

What is the proper Way of backing up a Droplet ?

Posted April 29, 2020 237 views
Backups

What is the proper way to take a backup of a droplet?

How do the snapshots work?
Can I restore my whole Droplet using snapshot? the database and files and the system config is everything restorable using a snapshot?
Do you have an Existing guide for this?

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
2 answers

Hi @webprotime,

DigitalOcean have pretty good articles/docs on both Snapshots and backups. You can check them by using the following links:

Snapshots

https://www.digitalocean.com/docs/images/snapshots/

Backups

https://www.digitalocean.com/docs/images/backups/

Now, the basic differences are

Backups

Backups are taken once per week, and each backup is retained for four weeks. tBackups are stored in the same datacenter as the corresponding Droplet.

You can enable backups for any Droplet, but they may not be ideal for Droplets with heavy I/O workloads, such as database servers, because disk writes have degraded performance while the backup is being created.

Snapshots

Snapshots provide a full copy of a DigitalOcean Droplet or volume. Creating a snapshot saves everything from the Droplet or volume’s disk to a disk image saved in your DigitalOcean account. They’re an easy way to archive a Droplet or volume at a point in time.

You can use snapshots to create new Droplets or volumes with the same contents of the snapshot. You can back up the contents of a block storage volume, restore a Droplet to the point in time when a snapshot was taken, or migrate a Droplet to a different region.

For more information, I’ll recommend going through the docs. If you still have some questions after reading them, please ask as much as you want!

Regards,
KDSYs

@webprotime, in addition to what KFSys has mentioned, I would like to add that you could use a backup automation service that supports DigitalOcean like ours (SimpleBackup) to get:

  • Flat-file backups (useful if you need to back up certain files/folders to retrieve them individually)
  • Database (MySQL/PostgreSQL/MongoDB) dumps

This will give you the flexibility to:

  • Choose your own backup schedule (hourly, weekly, or any other interval)
  • Store your backups securely on an offsite cloud storage

Laurent

Submit an Answer