PDA

View Full Version : Backing up Attachments


Lynne
06-21-2007, 03:16 PM
I'm interested to hear other admins methods of backing up their attachments folder.

My site runs on two servers - one is the webserver, the other is for mysql. My attachments are stored in the file system on the main webserver. Currently, we have a bit over 4.2 GB in attachments. My method of backing them up is to do a backup of that folder once a week in the middle of the night (that is the lowest activity for us) using a cron job I wrote. All it does is tar the attachment folder and then put that backup in the backup folder on that server. Then, I manually go and scp a copy over to the mysql server every week. So, we end up with two copies of the backup - one on each server.

I just know there must be a better way to do this. It seems kinda stupid to make a whole tar of the folder every week when most of those attachments stay the same. Does anyone have a better script to use to do their backups? Or a better suggestion on how to handle their attachments?

Thanks for any input.

Lynne
06-23-2007, 02:42 AM
No one has any comments about this? I know other sites must backup their attachments using some method.

COBRAws
06-26-2007, 07:27 PM
I just FTP orSSH and download them to a backup server.

da420
06-26-2007, 07:29 PM
I just gzip the folder via SSH, and download via FTP.

Shazz
06-26-2007, 08:35 PM
I moved all my attachments to file system and I backed them up using FTP

Lynne
06-27-2007, 02:44 PM
I have them in the file system, but we are talking about over 4 GB worth of attachments (and getting bigger every day). I figured some of you guys with big boards would also have this same 'problem'.

Shazz
06-27-2007, 02:47 PM
vB.org uses file system, I wonder how that works... :|

Bigblah
06-27-2007, 03:43 PM
I've done an update of a mirror of my attachments by accessing the backup server via SSH and running wget with the -N option (and -r and -l for recursive retrieval). wget can connect through FTP so you can point it to your attachment directory.

With that many attachments though, having wget retrieve every directory filelisting and check timestamps would certainly be a time consuming process.

Angel-Pie
07-08-2007, 12:30 AM
i havent done any backing up yet, just getting the board together and then will back up the files but thanks for all the ideas!

orban
07-08-2007, 09:47 AM
I rsync them to another server, smooth and painless. You can't possible gzip and download 5gb of attachments every couple days so we had to find another way.