Iscriviti   Guestbook   Immagini   Forum   Download   Mappa   513 utenti on line 
Italiano
MENU
CONFIGURAZIONI
RISORSE
INFO
Login

DOWNLOAD
Device
Suggerimenti

 

Database support in voicemail

The Asterisk voicemail system, comedian mail, supports configuration of mailboxes in a database. Voicemail supports both Postgres? and MySQL databases. Work is going on to make it support UnixODBC.

This means:
  • All voicemail user configurations will be read dynamically from database
  • Users can change their voicemail passwords from inside voicemail or using a simple web-based UI

1. Download

Note that the MySQL support has been moved to asterisk-addons due to MySQL changing the licensing of their libraries to full GPL.

cd /usr/src
export CVSROOT=:pserver:anoncvs@cvs.digium.com:/usr/cvsroot
cvs login - the password is anoncvs.
cvs checkout asterisk-addons

2. Compile

cp asterisk-addons/mysql-vm-routines.h asterisk-0.7.2/apps
cd asterisk-0.7.2
vi apps/Makefile +14
USE_MYSQL_VM_INTERFACE=1
make clean
make
make install

3. Configure in voicemail.conf

In the [general] section in ((asterisk config voicemail.conf|voicemail.conf)) specify

dbuser=''username''
dbpass=''password''
dbhost=''localhost''
dbname=''asterisk_vm''

4. Configure database

Create a database (e.g. 'asterisk_vm') & a user which can access it (needs to have write access for password changes from inside VM).
Table has to be called 'users' (hardcoded in .h file)

CREATE TABLE users (
   context char(79) DEFAULT '' NOT NULL,
   mailbox char(79) DEFAULT '' NOT NULL,
   password char(79) DEFAULT '' NOT NULL,
   fullname char(79) DEFAULT '' NOT NULL,
   email char(79) DEFAULT '' NOT NULL,
   pager char(79) DEFAULT '' NOT NULL,
   options char(159) DEFAULT '' NOT NULL,
   stamp timestamp,
   PRIMARY KEY (context,mailbox)
);

Note that context refers to the Mailbox context, not extension context)
Note that the password is stored in plain text


 

Valid CSS!