I'm currently researching the best backup solution for my CentOS webserver, and I'm thinking of going with either Tarsnap or straight-up Amazon S3.
I am trying to figure out how to discourage a hacker from deleting both my server contents and my remote backups in the worst case where he gains root access to my server and thus has access to the remote backup authentication credentials. (I do fully understand the importance of having a strong password and/or enforcing only key based SSH auth, as well as other general best-practice security. But stuff sometimes happens, there could be a Linux vulnerability or a vulnerability at the VPS level of my host, or something else more or less out of my control.)
I know that both Tarsnap and Amazon S3 have write-only user permissions, but the problem is that I also need automated backup pruning/rotation. Would it be possible to set up either of those services (or possibly some other service) to disallow deletion of backup generations newer than, say, 2 days? That would give me a two day buffer to notice that I was hacked and prevent the hacker from deleting my newest data generations.
Or any other ideas? Thanks a lot!