remote backups
Sep. 11th, 2007 10:28 am![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
So I just skimmed through this lengthy thread on a webmaster BBS: a huge percentage of the sites hosted by a little reseller have vanished because said reseller didn't pay the bill to the larger hosting provider he was using; this has possibly happened because the person behind this one-man operation died. (Slashdot summary, with link to long thread, here.)
This, coupled with a bit of paranoia due to waiting for my own website to reconnect to the world (rdwarf.net is changing providers, and it seems to be taking a while for the DNS servers to reconnect properly - oh, and it's back up, at least for me. yay! the dns is propagating.) led me to a guide to using rsync to keep a local copy of your remotely-hosted website.
The basic recipe given here works quite fine; I just finished running a backup. The comments have a few good suggestions as well - I've tweaked it a little to be this:
rsync -azPe ssh username@your.host:/full/path/to/your/directory/ /Users/egypt/Documents/web-backup --exclude=php-cache*
Adding the 'P' into the flags gives me a progress meter; the '--exclude' bit tells it to not bother with the assload of generated HTML my back end keeps around.
I may end up automating this, but right now, just clicking the saved command file to refresh the backup when I upload a new picture will help a lot. My site's not database-driven so I don't need to back that up as well.
I've been meaning to do this for years.
As I halfway recalled, cron is depreciated on OSX in favor of launchd. Looks like the easiest way to make this happen automagically is probably to use Lingon.
This, coupled with a bit of paranoia due to waiting for my own website to reconnect to the world (rdwarf.net is changing providers, and it seems to be taking a while for the DNS servers to reconnect properly - oh, and it's back up, at least for me. yay! the dns is propagating.) led me to a guide to using rsync to keep a local copy of your remotely-hosted website.
The basic recipe given here works quite fine; I just finished running a backup. The comments have a few good suggestions as well - I've tweaked it a little to be this:
rsync -azPe ssh username@your.host:/full/path/to/your/directory/ /Users/egypt/Documents/web-backup --exclude=php-cache*
Adding the 'P' into the flags gives me a progress meter; the '--exclude' bit tells it to not bother with the assload of generated HTML my back end keeps around.
I may end up automating this, but right now, just clicking the saved command file to refresh the backup when I upload a new picture will help a lot. My site's not database-driven so I don't need to back that up as well.
I've been meaning to do this for years.
As I halfway recalled, cron is depreciated on OSX in favor of launchd. Looks like the easiest way to make this happen automagically is probably to use Lingon.
Good idea.
Date: 2007-09-11 07:57 pm (UTC)There isn't much you can do in that kind of situation but to order your server direct from the hosting company. I can't tell you how many hosting companys says, "We have thousands of servers hosted from this one client who sub hosts" Its one of the reasons why I am staying with he.net now:P
no subject
Date: 2007-09-11 08:07 pm (UTC)