3

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?

Garg
  • 456
  • 6
  • 19

2 Answers2

2

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.
arheops
  • 14,867
  • 1
  • 15
  • 27
  • Thank's for the answer. I don't want to save messages into database so at this point ODBC_STORAGE is not an option. If I trying to use one of other two options do I need something additional configuration on Asterisk side or this is only on Linux and file sharing side? – Garg Feb 04 '16 at 06:02
  • And one more question. If I use NFS what I must share? Whole `/var/spool/voicemail/..` directory? – Garg Feb 04 '16 at 09:08
  • In all cases you should share voicemail folder. It is /var/spool/asterisk/voicemail/ if you not changed something in /etc/asterisk/asterisk.conf – arheops Feb 04 '16 at 14:19
1

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
S.I.
  • 2,691
  • 11
  • 34
  • 53