Listen voice messages on server A from server B with asterisk

396 Views Asked by At

I have RealTime asterisk with 3 servers. In database I hold sippears only and voicemail boxes. Voicemail messages are stored on the system FILE_STORAGE.

Server A and B are for calls and sip registrations and Server C is dundi. Currently everything work fine.. I can call from Server A to Server B. The problem is when I leave message to number who is busy and registered on Server B.. then this number disconnect and register on Server A -> he can't listen the messages because it is stored on Server B..

How can I make any user to be able to listen his messages no matter on which server are?

2

There are 2 best solutions below

3
On BEST ANSWER

You have alot of options, most of each in clustering area.

Simplest options are:

  • Glusterfs setup on both server, voicemail in glusterfs directory. This one do failover

  • NFS/samba share on both servers.

  • mysql master-master replication, use ODBC_STORAGE, put all voicemails in db. This one is recommended if you also want easy access from web interface to your voice files and simple search/lookup/get message. Highly recommended use innodb tables and optimized mysql config.
2
On

Easiest way just for to be able to listen them no matter on which of both servers user is registered is NFS and mounting for example /var/spool/asterisk/. In this case you need to install some additional components. Here is great tutorial how can you done this: How to configure an NFS server and mount NFS shares - Ubuntu

Another way if you can make master-slave with two servers in cluster and using rsync . Then you can sync every X minutes/hours/days folder to remote server to keep them in case of failure.

rsync -a local_dir/ user@remote-host-ip:/path/to/dir