Results 1 to 13 of 13

Thread: Automating Website Backup?

  1. #1
    Junior Senior Member Aaron's Avatar
    Join Date
    Jul 2003
    Location
    London, England
    Posts
    1,516
    Thanks
    0
    Thanked
    1 time in 1 post

    Automating Website Backup?

    I don't know about you but I just don't trust my web host with my website data. Over the past few years I've had my website dissappear quite a few times and I've had to upload a backup copy.

    Backing up my website can be a pain and I'm lazy, so I don't do it as often as I should.

    So I thought I'd look into a way of backing it up automatically.

    My initial idea was to use a batch file and the built-in FTP software in Windows (XP), scheduling the batch file to be run every week:

    backupwebsite.bat
    @Echo Off
    @Echo Deleting old copy
    del BACKUP_DRIVE_LETTER:\Website
    @Echo Backing up current version
    ftp -s:backup.txt
    backup.txt:
    open MY_HOST
    USERNAME
    PASSWORD
    lcd BACKUP_DRIVE_LETTER:\Website
    mget *
    quit
    But it just hangs on the mget * command.

    Does anyone know what I'm doing wrong? Could someone possibly suggest another (free and simple) way to backup my website, please?

    Cheers.

  2. #2
    Treasure Hunter extraordinaire herulach's Avatar
    Join Date
    Apr 2005
    Location
    Bolton
    Posts
    5,618
    Thanks
    18
    Thanked
    172 times in 159 posts
    • herulach's system
      • Motherboard:
      • MSI Z97 MPower
      • CPU:
      • i7 4790K
      • Memory:
      • 8GB Vengeance LP
      • Storage:
      • 1TB WD Blue + 250GB 840 EVo
      • Graphics card(s):
      • 2* Palit GTX 970 Jetstream
      • PSU:
      • EVGA Supernova G2 850W
      • Case:
      • CM HAF Stacker 935, 2*360 Rad WC Loop w/EK blocks.
      • Operating System:
      • Windows 8.1
      • Monitor(s):
      • Crossover 290HD & LG L1980Q
      • Internet:
      • 120mb Virgin Media
    Is it just a simple site? (No cgi etc?) If so then you could just use the firefox spider plug in (cant recall the name) and just run that as often as you like. WOuldnt help with dynamic content though.

  3. #3
    Administrator Moby-Dick's Avatar
    Join Date
    Jul 2003
    Location
    There's no place like ::1 (IPv6 version)
    Posts
    10,665
    Thanks
    53
    Thanked
    384 times in 313 posts
    if you enter those commands locally would they work ?
    I'd have thougth it woudl be 8.8 ( but I'm probably wrong )
    you might wan tto set type binary as well ?
    my Virtualisation Blog http://jfvi.co.uk Virtualisation Podcast http://vsoup.net

  4. #4
    Junior Senior Member Aaron's Avatar
    Join Date
    Jul 2003
    Location
    London, England
    Posts
    1,516
    Thanks
    0
    Thanked
    1 time in 1 post
    My website is just a Wordpress-powered blog and some photos really. Nothing fancy.

    If I try the commands manually, I get the same result. Setting the mode to binary sadly doesn't help either. ls returns "200 PORT command successful" and then hangs too, so maybe it's just Microsoft's ftp client being rubbish? Are there any alternative command line ftp clients that anyone would recommend?

  5. #5
    TiG
    TiG is offline
    Walk a mile in other peoples shoes...
    Join Date
    Jul 2003
    Location
    Questioning it all
    Posts
    6,213
    Thanks
    43
    Thanked
    47 times in 42 posts
    I'm also assuming the content on the web site must be changing without you uploading changes?. Otherwise backing up the web version seems odd?.

    anyway the mget * is interactive meaning you need to say "yes" to each file.

    I don't think standard ftp has an Non interactive Mget option....

    TiG
    -- Hexus Meets Rock! --

  6. #6
    Junior Senior Member Aaron's Avatar
    Join Date
    Jul 2003
    Location
    London, England
    Posts
    1,516
    Thanks
    0
    Thanked
    1 time in 1 post
    Yes, it will be changing since it's mainly a blog where I write posts online, rather than writing them offline and uploading them.

    I've found a piece of software called "MoveIt Freely", which advertises itself as a drop-in replacement for Windows' ftp client - with better security and features. Perhaps this will work.

    Cheers for the help everyone.

  7. #7
    HEXUS.net Webmaster
    Join Date
    Jul 2003
    Location
    UK
    Posts
    3,108
    Thanks
    1
    Thanked
    0 times in 0 posts
    http://www.gnu.org/software/wget/wget.html

    Command line options you can call to do FTP operations

  8. #8
    Ex-MSFT Paul Adams's Avatar
    Join Date
    Jul 2003
    Location
    %systemroot%
    Posts
    1,926
    Thanks
    29
    Thanked
    77 times in 59 posts
    • Paul Adams's system
      • Motherboard:
      • Asus Maximus VIII
      • CPU:
      • Intel Core i7-6700K
      • Memory:
      • 16GB
      • Storage:
      • 2x250GB SSD / 500GB SSD / 2TB HDD
      • Graphics card(s):
      • nVidia GeForce GTX1080
      • Operating System:
      • Windows 10 x64 Pro
      • Monitor(s):
      • Philips 40" 4K
      • Internet:
      • 500Mbps fiber
    Quote Originally Posted by TiG
    anyway the mget * is interactive meaning you need to say "yes" to each file.

    I don't think standard ftp has an Non interactive Mget option....
    "prompt" should work?

    It might depend on the FTP server you talk to.
    I just did a test the worked for 2 files in a folder:
    Code:
    open ftp.x.x.x
    username
    password
    cd folder1\folder2\folder3
    prompt
    bin
    hash
    lcd c:\
    mget *
    close
    Didn't test it with a script but it should be the same principle methinks.
    ~ I have CDO. It's like OCD except the letters are in alphabetical order, as they should be. ~
    PC: Win10 x64 | Asus Maximus VIII | Core i7-6700K | 16GB DDR3 | 2x250GB SSD | 500GB SSD | 2TB SATA-300 | GeForce GTX1080
    Camera: Canon 60D | Sigma 10-20/4.0-5.6 | Canon 100/2.8 | Tamron 18-270/3.5-6.3

  9. #9
    Junior Senior Member Aaron's Avatar
    Join Date
    Jul 2003
    Location
    London, England
    Posts
    1,516
    Thanks
    0
    Thanked
    1 time in 1 post
    Thanks everyone. I think my main problem was that I didn't set it to passive mode.

    The beers are on me if there's ever a Hexus meet in London.

  10. #10
    Senior Member
    Join Date
    Aug 2005
    Location
    Leeds
    Posts
    267
    Thanks
    8
    Thanked
    16 times in 16 posts
    Don't forget to backup your database for WP!
    http://wordpress.org/development/200...s-backup-week/

  11. #11
    Member
    Join Date
    May 2004
    Location
    Glasgow
    Posts
    190
    Thanks
    2
    Thanked
    5 times in 3 posts
    small suggestion - try to work it in so that you download the new backup before deleting the current one....cant count the number of times ive heard of people delating a backup of somthing to then back it up again and not realise somthigns gone wrong and infact theyve gone and deleted the only decent copy

  12. #12
    Senior Member
    Join Date
    Oct 2003
    Posts
    2,069
    Thanks
    4
    Thanked
    7 times in 3 posts
    good plan stan!
    Twigman

  13. #13
    Civilian Nick F's Avatar
    Join Date
    May 2004
    Location
    London
    Posts
    4,668
    Thanks
    9
    Thanked
    18 times in 10 posts
    • Nick F's system
      • CPU:
      • 2.4Ghz C2D
      • Memory:
      • 4GB
      • Storage:
      • 320Gb internal / 750Gb external
      • Case:
      • Apple iMac
      • Operating System:
      • Mac OSx
      • Monitor(s):
      • 24inch
      • Internet:
      • 8mb BE connection
    Does your cpanel not offer this kind of thing? I can do actomatic backups on my site.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Backup Options
    By michaels in forum PC Hardware and Components
    Replies: 4
    Last Post: 18-08-2005, 11:24 PM
  2. Replies: 0
    Last Post: 26-07-2005, 11:27 AM
  3. Website / Name Purchasing and Hosting (Help)
    By muddyfox470 in forum Software
    Replies: 8
    Last Post: 08-07-2005, 03:27 PM
  4. BBC culls Cult website
    By Steve in forum HEXUS News
    Replies: 0
    Last Post: 01-07-2005, 01:47 PM
  5. recommend some website design software
    By petrefax in forum Software
    Replies: 24
    Last Post: 23-09-2004, 09:00 AM

Posting Permissions

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