HA Backup and restore

Hello,

Is it possible to make the following options in B&R module:

  • Backup only to FTP/SSH - do not make the backup localy (var/lib/asterisk/backups) - because some hardware’s have very small flash/disk?
  • Restore from remote FTP/SSH?

Done…

If anybody needs it:

http://www.2shared.com/file/u-msQysk/backup-28071tar.html

I’ve tested it, it works…

  • If you choose FTP backup - it deletes the backup on the local machine after it transferes the file to the Remote FTP.
  • You have new menu on the left, where you specify FTP information where the backup file is, and transfer it to the local machine

This was done in a hurry, so the code is not ‘beautifull’, but it works - at least for me :slight_smile:

Be carefull when you upgrade it - make a backup of the the original backup module first (don’t test this on production machine)!!!

I had a feeling my reply wouldn’t be too user friendly but it is an immediate work around for the time being.
I figured there would be a method to overwrite the existing backup as opposed to creating a new one each day. That could probably save a little space.

Let us know how the extra menu goes for the backup.

Thanks for the reply.

But this is too user un-friendly. I allready found a code where if you choose FTP, it makes a local backup and sends it to FTP - I’ve made some adjustment, that after it send the backup via FTP, I delete the local backup.

Now, I just have to make an extra menu, to pull the backup from FTP and restore it.

Couldn’t you make a cronjob to delete the backup from var/lib/asterisk/backups. Just run it a few minutes after the auto backup takes place.

I don’t know the answer for the second question but my guess for a work around would be to ssh into the server and use wget to download it to the /var/lib/asterisk/backups