Brendan

Cycling and Travelling around Japan

How to backup your Azure website

Posted on | March 22, 2013 | No Comments

Microsoft does not have a backup system available for its Websites in Azure.

However you can piece one together with the following two parts and add them to a cron to get a backup done each night

MYSQL: (database)

/usr/bin/mysqldump -h <server> -u <username> –password=<password> –single-transaction > sql`date “+\%Y-\%m-\%d”`.sql

FTP: (Files)

wget -r –level=0 –quiet -P `date “+\%Y-\%m-\%d”` ftp://<username (don’t forget to escape the slash)>:<password>@<server>

 

If you have loads of themes and uploads on the server it may take a few moments to get the copy done. I tested a default install and it took about 10 to 15 seconds. This is an incentive to reduce unnecessary clutter inside your wordpress installation.

Comments

Leave a Reply





  • Calendar

    March 2013
    M T W T F S S
    « Nov    
     123
    45678910
    11121314151617
    18192021222324
    25262728293031
  • Tags

  • Meta