Home > linux > Hot backup setup for trixbox Pro

Hot backup setup for trixbox Pro

Trixbox Hot Backup – servers need identical telephony hardware or this will not work.

On backup server:
Install trixbox pro, and activate it

ssh-keygen -t rsa
<enter>
<enter>
<enter>
scp ~/.ssh/id_rsa.pub root@server1-IP:.ssh/authorized_keys
(Now you can scp/ssh/rsync without password)

nano trixboxbackup.sh
rsync -aq –delete root@server1-IP:/etc/asterisk /etc
rsync -aq –delete root@server1-IP:/var/lib/asterisk/sounds /var/lib/asterisk
rsync -aq –delete root@server1-IP:/var/lib/asterisk/mohmp3 /var/lib/asterisk
rsync -aq –delete root@server1-IP:/var/spool/asterisk/voicemail /var/spool/asterisk
rsync -aq –delete root@server1-IP:/var/spool/asterisk/monitor /var/spool/asterisk
rsync -aq –delete root@server1-IP:/tftpboot/ /tftpboot
rsync -aq –delete root@server1-IP:/etc/wanpipe /etc

ctrl-x y, to close and save
chmod 777 trixboxbackup.sh

nano /etc/crontab
add these lines:
00 * * * * root /root/trixboxbackup.sh
30 * * * * root /root/trixboxbackup.sh

It should now replace the contents of those directories on the hot backup server with the contents of the directories on the production server. It will happen silently, every 30 minutes. That can be adjusted to suit.

In case there is a serious problem with server1:

Power it off
Move PRI cables to same ports on backup server
change IP of backup server to IP of server1
Reboot backup server
Reboot phones. If connected to POE switch, simply power cycle POE switch.

The only problem is if you are using voip trunks on server1. The two servers could compete for the same voip registration. The backup server should be blocked at the firewall in this case.

Advertisements
Categories: linux
  1. parkpost
    August 17, 2009 at 5:23 am

    There are some intriguing IP telephony products and applications reaching the marketplace now. Interesting post.

  1. No trackbacks yet.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: