SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Addict agentforte's Avatar
    Join Date
    May 2007
    Toronto, ON, Canada
    0 Post(s)
    0 Thread(s)

    Question Using PHP to make backups.. do you know how?

    Could anyone advise on how to have a website automatically backup files on a separate server? The files will be mp3's and images uploaded by members on the website.

    I am thinking that I can keep a log of all uploads, deletes, and edits.
    Then, 3 or 4 times during the day, the website would run a script to update the backup files on the other server.

    For performance on a busy website, would it be better to do this, or just save files onto both servers at the time of the upload, delete, or changes?

    What kind of problems do you think I will run into with either of these methods?


  2. #2
    ✯✯✯ silver trophybronze trophy php_daemon's Avatar
    Join Date
    Mar 2006
    2 Post(s)
    0 Thread(s)
    I'd suggest keeping track of the changes and synchronizing the servers periodically, during the least busy time for example. Basically it would involve an extra database table and a script to transfer the files via ftp.

    So, yes, it's a lot more efficient way as opposed to simultaneous mirroring. Otherwise you'd make users wait for the files to be transfered to another server.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts