-5

So, I'm almost finished building my first major production web app, and am wondering how to manage the backup protocol.

Cold backups via my hosting control panel seem ideal - but daily downtime sounds awful for UX. Hot backups seem pointless as they cannot be trusted to not be corrupt.

My server runs Debian.

Is there a way to SSH in and clone the filesystem on my local machine, before encrypting with Veracrypt, before posting it to the moon, as an off-planet backup? (Lol.)

I suppose I don't need to backup the entire fs on a daily basis, but definitely Mongodb. What's the easiest way to automate a mongodb backup?

Thanks so much for reading :)

Ward - Reinstate Monica
  • 12,788
  • 28
  • 44
  • 59
harry young
  • 101
  • 4
  • Questions involving web hosting control panels are off-topic because they customize their systems so that standard system administration methods no longer apply. Some related topics may be asked on Webmasters or see Where can I ask questions about web hosting control panels? – TomTom Apr 17 '21 at 11:47
  • Have you ever managed a vps? – harry young Apr 17 '21 at 11:52
  • You mean outside of having around 80 of them in my own computers and running multiple Azure based setups for companies? Not really. Except those 80 vm's (that get backed up automatically twice per day and are for development) and the azure clusters I managed in projects for production code. Yeah. A little. – TomTom Apr 17 '21 at 12:04
  • Im simply looking for someone with experience with Mongo to explain the optimal way to make and store backups – harry young Apr 17 '21 at 15:17

1 Answers1

1

Generally:

  • They do not use control panels. Seriously. Those are for small retail.
  • They do NOT back up anything of the web app - and they are designed with backup in mind.

The last is important. Unless you run a photo app or something where people upload documents - there is basically only the database to back up. What about the web app? That one lives as code in a repository with automatic deployment scripts, there is zero sense in backing that one up.

Generally backups are something handled with and through whoever is admin of the servers (i.e. the hoster). MS for example offers this as service that you can trigger, no need to copy anything local (and they copy on 3 data centers for safety like fire). Your access is slow, non scalable etc.

Hot backups seem pointless as they cannot be trusted to not be corrupt.

Professional databases are designed with hot backup in mind, down to the last transaction or backing up ONLY the changed transactions. If your db is not -> here you go, you chose it, you live with it.

TomTom
  • 50,857
  • 7
  • 52
  • 134
  • Well DO, EC2 and my new vps of choice all have a backup option (snapshot) in their control panel...? – harry young Apr 17 '21 at 11:50
  • Yes. Those are generally not what people mean when they talk "control panel" though. We talk of web contrrol panels. – TomTom Apr 17 '21 at 12:03
  • ahh I guess you thought I was referring to the likes of cpanel. – harry young Apr 17 '21 at 14:33
  • "Professional databases are designed with hot backup in mind, down to the last transaction or backing up ONLY the changed transactions. If your db is not -> here you go, you chose it, you live with it." - Mongo is professional... Any idea how backups work? – harry young Apr 17 '21 at 14:41