tags:

views:

51

answers:

1

I tried backing up our site today using the Unix 'cp' command and ended up getting our office blocked out by PLESK -> it added my ip to /etc/hosts.deny as it thought I was flooding the server.

After Tech support fixed the issue, they suggested I go folder by folder to back it up, but there's about 10,000 folders on the site totaling 1/2 a terabyte, each with multiple sub-folders, so this isn't viable.

Basically I want to be able to mirror the domain on another domain we've got set up on the same dedicated server so I can test with live images (the bulk of our content).

Any suggestions e.g adding some rules to open_base_dir and getting PHP to recursively copy the folders to the other domain (remember it's on the same dedicated box so it just needs to traverse the directory, not FTP things).

+1  A: 

You could try rsync with the --bwlimit option. Or you could do a one-off sneakernet backup with a USB drive and subsequently maintain the backup with rsync.

As a general rule, always use rsync in preference to cp. It has many benefits, including the fact that you don't have to mount remote volumes.

Marcelo Cantos
The USB is out of the question as the server is hosted in a different city to us. Will look into rsync as the Wikipedia entry makes it sound like just what we need - daily increments to the site aren't huge -> it's just that 3 years of client images are stored there currently :-)
niggles
Depending on your bandwidth and data charges, USB-over-UPS might be faster and cheaper.
Marcelo Cantos