; ; Configuration for Shared Line Appearances (SLA). ; ; See doc/sla.pdf for more information. ; ; ---- General Options ---------------- [general] ;attemptcallerid=no ; Attempt CallerID handling. The default value for this ; is "no" because CallerID handling with an SLA setup is ; known to not work properly in some situations. However, ; feel free to enable it if you would like. If you do, and ; you find problems, please do not report them. ; ------------------------------------- ; ---- Trunk Declarations ------------- ; [line1] ; Provide a name for this trunk. type=trunk ; This line is what marks this entry as a trunk. device=Zap/2 ; Map this trunk declaration to a specific device. ; NOTE: You can not just put any type of channel here. ; Zap channels can be directly used. IP trunks ; require some indirect configuration which is ; described in doc/sla.pdf. ;autocontext=line1 ; This supports automatic generation of the dialplan entries ; if the autocontext option is used. Each trunk should have ; a unique context name. Then, in zapata.conf, this device ; should be configured to have incoming calls go to this context. ringtimeout=40 ; Set how long to allow this trunk to ring on an inbound call before hanging ; it up as an unanswered call. The value is in seconds. barge=yes ; If this option is set to "no", then no station will be ; allowed to join a call that is in progress. The default ; value is "yes". hold=open ; This option configure hold permissions for this trunk. ; "open" - This means that any station can put this trunk ; on hold, and any station can retrieve it from ; hold. This is the default. ; "private" - This means that once a station puts the ; trunk on hold, no other station will be ; allowed to retrieve the call from hold. [line2] type=trunk device=Zap/3 ringtimeout=40 barge=yes hold=open [line3] type=trunk device=Zap/4 ringtimeout=40 barge=yes hold=open [line4] type=trunk device=Zap/5 ringtimeout=40 barge=yes hold=open [line5] type=trunk device=Zap/6 ringtimeout=40 barge=yes hold=open [line6] type=trunk device=Zap/7 ringtimeout=40 barge=yes hold=open [line7] type=trunk device=Zap/1 ringtimeout=40 barge=yes hold=open ;[line4ip] ;type=trunk ;device=Local/disa@line4_outbound ; A Local channel in combination with the Disa ; application can be used to support IP trunks. ; See doc/sla.pdf on more information on how ; IP trunks work. ;autocontext=line4 ; -------------------------------------- ; ---- Station Declarations ------------ [station](!) type=station ringtimeout=15 ringdelay=0 hold=open trunk=line1 trunk=line2 trunk=line3 trunk=line4 trunk=line5 trunk=line6 trunk=line7 [station210](station) device=SIP/210 [station218](station) device=SIP/218 [station219](station) device=SIP/219 [station224](station) device=SIP/224 [station225](station) device=SIP/225 [station2825](station) device=SIP/2825 ; -------------------------------------- ############################################################################# ; extensions.conf - the Asterisk dial plan [general] static=yes writeprotect=no clearglobalvars=no ; [globals] ; [iaxtel700] exten => _91700XXXXXXX,1,Dial(IAX2/${GLOBAL(IAXINFO)}@iaxtel.com/${EXTEN:1}@iaxtel) [macro-trunkdial] exten => s,1,Dial(${ARG1}) exten => s,n,Goto(s-${DIALSTATUS},1) exten => s-NOANSWER,1,Hangup exten => s-BUSY,1,Hangup exten => _s-.,1,NoOp [macro-stdexten]; ; Standard extension macro: ; ${ARG1} - Extension (we could have used ${MACRO_EXTEN} here as well ; ${ARG2} - Device(s) to ring exten => s,1,Dial(${ARG2},20) ; Ring the interface, 20 seconds maximum exten => s,2,Goto(s-${DIALSTATUS},1) ; Jump based on status (NOANSWER,BUSY,CHANUNAVAIL,CONGESTION,ANSWER) exten => s-NOANSWER,1,Voicemail(${ARG1},u) ; If unavailable, send to voicemail w/ unavail announce exten => s-NOANSWER,2,Goto(default,s,1) ; If they press #, return to start exten => s-BUSY,1,Voicemail(${ARG1},b) ; If busy, send to voicemail w/ busy announce exten => s-BUSY,2,Goto(default,s,1) ; If they press #, return to start exten => _s-.,1,Goto(s-NOANSWER,1) ; Treat anything else as no answer exten => a,1,VoicemailMain(${ARG1}) ; If they press *, send the user into VoicemailMain [macro-stdPrivacyexten]; ; ; Standard extension macro: ; ${ARG1} - Extension (we could have used ${MACRO_EXTEN} here as well ; ${ARG2} - Device(s) to ring ; ${ARG3} - Optional DONTCALL context name to jump to (assumes the s,1 extension-priority) ; ${ARG4} - Optional TORTURE context name to jump to (assumes the s,1 extension-priority)` ; exten => s,1,Dial(${ARG2},20|p) ; Ring the interface, 20 seconds maximum, call screening ; option (or use P for databased call screening) exten => s,2,Goto(s-${DIALSTATUS},1) ; Jump based on status (NOANSWER,BUSY,CHANUNAVAIL,CONGESTION,ANSWER) exten => s-NOANSWER,1,Voicemail(${ARG1},u) ; If unavailable, send to voicemail w/ unavail announce exten => s-NOANSWER,2,Goto(default,s,1) ; If they press #, return to start exten => s-BUSY,1,Voicemail(${ARG1},b) ; If busy, send to voicemail w/ busy announce exten => s-BUSY,2,Goto(default,s,1) ; If they press #, return to start exten => s-DONTCALL,1,Goto(${ARG3},s,1) ; Callee chose to send this call to a polite "Don't call again" script. exten => s-TORTURE,1,Goto(${ARG4},s,1) ; Callee chose to send this call to a telemarketer torture script. exten => _s-.,1,Goto(s-NOANSWER,1) ; Treat anything else as no answer exten => a,1,VoicemailMain(${ARG1}) ; If they press *, send the user into VoicemailMain [from-internal] include => default [default] ;extensions exten => 210,1,Macro(stdexten,210,SIP/210) exten => 218,1,Macro(stdexten,218,SIP/218) exten => 219,1,Macro(stdexten,219,SIP/219) exten => 224,1,Macro(stdexten,224,SIP/224) exten => 2824,1,Macro(stdexten,2824,SIP/2824) exten => 225,1,Macro(stdexten,225,SIP/225) exten => 2825,1,Macro(stdexten,2825,SIP/2825) ;home.netgenius.org prefix exten => _5*1.,1,Dial(IAX2/ccraft@home.netgenius.org/${EXTEN:3},,r) ;choose-a-line access prefixes exten => _9*1.,1,Dial(Zap/2/${EXTEN:3},,r) exten => _9*2.,1,Dial(Zap/3/${EXTEN:3},,r) exten => _9*3.,1,Dial(Zap/4/${EXTEN:3},,r) exten => _9*4.,1,Dial(Zap/5/${EXTEN:3},,r) exten => _9*5.,1,Dial(Zap/6/${EXTEN:3},,r) exten => _9*6.,1,Dial(Zap/7/${EXTEN:3},,r) exten => _9*7.,1,Dial(Zap/1/${EXTEN:3},,r) ;BLF hints exten => 210,hint,SIP/210 exten => 218,hint,SIP/218 exten => 219,hint,SIP/219 exten => 224,hint,SIP/224 exten => 225,hint,SIP/225 exten => 2824,hint,SIP/2824 exten => 2825,hint,SIP/2825 ;Access voicemail main menu ;backwards compatibility with old PBX exten => 777,1,VoicemailMain exten => 777,n,Hangup ;from new feature code list exten => _*97,1,VoicemailMain exten => _*97,n,Hangup ;Voicemail codes to transfer to leave messages exten => 910,1,Voicemail(210,u) exten => 9210,1,Voicemail(210,u) exten => 918,1,Voicemail(218,u) exten => 9218,1,Voicemail(218,u) exten => 919,1,Voicemail(219,u) exten => 9219,1,Voicemail(219,u) exten => 924,1,Voicemail(224,u) exten => 9224,1,Voicemail(224,u) exten => 925,1,Voicemail(225,u) exten => 9225,1,Voicemail(225,u) ;-----------_ SLA stuff _----------- [macro-slaline] ; This macro has been modified from the sla.pdf version to allow ; for sending calls from different trunks to different vms ;exten => s,1,Answer(${ARG1}) exten => s,1,SLATrunk(${ARG1}) exten => s,2,Goto(s-${SLATRUNK_STATUS}|1) exten => s-FAILURE,1,Voicemail(${ARG2}|u) exten => s-UNANSWERED,1,Voicemail(${ARG2}|u) [line1] exten => s,1,Macro(slaline|line1|210) [line2] exten => s,1,Macro(slaline|line2|210) [line3] exten => s,1,Macro(slaline|line3|210) ;temporary; exten => s,1,Dial(SIP/224,,r) [line4] exten => s,1,Macro(slaline|line4|210) [line5] exten => s,1,Macro(slaline|line5|212) [line6] exten => s,1,Macro(slaline|line6|225) [line1-outbound] exten => disa,1,Disa(no-password|line1_outbound) exten => _1NXXNXXXXXX,1,Dial(Zap/2/${EXTEN}) include => default [line2-outbound] exten => disa,1,Disa(no-password|line2_outbound) exten => _1NXXNXXXXXX,1,Dial(Zap/3/${EXTEN}) include => default [line3-outbound] exten => disa,1,Disa(no-password|line3_outbound) exten => _1NXXNXXXXXX,1,Dial(Zap/4/${EXTEN}) include => default [line4-outbound] exten => disa,1,Disa(no-password|line4_outbound) exten => _1NXXNXXXXXX,1,Dial(Zap/5/${EXTEN}) include => default [line5-outbound] exten => disa,1,Disa(no-password|line5_outbound) exten => _1NXXNXXXXXX,1,Dial(Zap/6/${EXTEN}) include => default [line6-outbound] exten => disa,1,Disa(no-password|line6_outbound) exten => _1NXXNXXXXXX,1,Dial(Zap/7/${EXTEN}) include => default [line7-outbound] exten => disa,1,Disa(no-password|line7_outbound) exten => _1NXXNXXXXXX,1,Dial(Zap/1/${EXTEN}) include => default [sla-stations] include => default ; x210 - Front Desk exten => station210,1,SLAStation(station210) exten => station210_line1,hint,SLA:station210_line1 exten => station210_line1,1,SLAStation(station210_line1) exten => station210_line2,hint,SLA:station210_line2 exten => station210_line2,1,SLAStation(station210_line2) exten => station210_line3,hint,SLA:station210_line3 exten => station210_line3,1,SLAStation(station210_line3) exten => station210_line4,hint,SLA:station210_line4 exten => station210_line4,1,SLAStation(station210_line4) exten => station210_line5,hint,SLA:station210_line5 exten => station210_line5,1,SLAStation(station210_line5) exten => station210_line6,hint,SLA:station210_line6 exten => station210_line6,1,SLAStation(station210_line6) exten => station210_line7,hint,SLA:station210_line7 exten => station210_line7,1,SLAStation(station210_line7) ; x218 - LA Bourgeois exten => station218,1,SLAStation(station218) exten => station218_line1,hint,SLA:station218_line1 exten => station218_line1,1,SLAStation(station218_line1) exten => station218_line2,hint,SLA:station218_line2 exten => station218_line2,1,SLAStation(station218_line2) exten => station218_line3,hint,SLA:station218_line3 exten => station218_line3,1,SLAStation(station218_line3) exten => station218_line4,hint,SLA:station218_line4 exten => station218_line4,1,SLAStation(station218_line4) exten => station218_line5,hint,SLA:station218_line5 exten => station218_line5,1,SLAStation(station218_line5) exten => station218_line6,hint,SLA:station218_line6 exten => station218_line6,1,SLAStation(station218_line6) exten => station218_line7,hint,SLA:station218_line7 exten => station218_line7,1,SLAStation(station218_line7) ; x219 - Amy Zutterling exten => station219,1,SLAStation(station219) exten => station219_line1,hint,SLA:station219_line1 exten => station219_line1,1,SLAStation(station219_line1) exten => station219_line2,hint,SLA:station219_line2 exten => station219_line2,1,SLAStation(station219_line2) exten => station219_line3,hint,SLA:station219_line3 exten => station219_line3,1,SLAStation(station219_line3) exten => station219_line4,hint,SLA:station219_line4 exten => station219_line4,1,SLAStation(station219_line4) exten => station219_line5,hint,SLA:station219_line5 exten => station219_line5,1,SLAStation(station219_line5) exten => station219_line6,hint,SLA:station219_line6 exten => station219_line6,1,SLAStation(station219_line6) exten => station219_line7,hint,SLA:station219_line7 exten => station219_line7,1,SLAStation(station219_line7) ; x224 - Chris Craft exten => station224,1,SLAStation(station224) exten => station224_line1,hint,SLA:station224_line1 exten => station224_line1,1,SLAStation(station224_line1) exten => station224_line2,hint,SLA:station224_line2 exten => station224_line2,1,SLAStation(station224_line2) exten => station224_line3,hint,SLA:station224_line3 exten => station224_line3,1,SLAStation(station224_line3) exten => station224_line4,hint,SLA:station224_line4 exten => station224_line4,1,SLAStation(station224_line4) exten => station224_line5,hint,SLA:station224_line5 exten => station224_line5,1,SLAStation(station224_line5) exten => station224_line6,hint,SLA:station224_line6 exten => station224_line6,1,SLAStation(station224_line6) exten => station224_line7,hint,SLA:station224_line7 exten => station224_line7,1,SLAStation(station224_line7) ; x225 - Stephanie Reineke exten => station225,1,SLAStation(station225) exten => station225_line1,hint,SLA:station225_line1 exten => station225_line1,1,SLAStation(station225_line1) exten => station225_line2,hint,SLA:station225_line2 exten => station225_line2,1,SLAStation(station225_line2) exten => station225_line3,hint,SLA:station225_line3 exten => station225_line3,1,SLAStation(station225_line3) exten => station225_line4,hint,SLA:station225_line4 exten => station225_line4,1,SLAStation(station225_line4) exten => station225_line5,hint,SLA:station225_line5 exten => station225_line5,1,SLAStation(station225_line5) exten => station225_line6,hint,SLA:station225_line6 exten => station225_line6,1,SLAStation(station225_line6) exten => station225_line7,hint,SLA:station225_line7 exten => station225_line7,1,SLAStation(station225_line7) ;for grandstream button pickup exten => _**.,1,SLAStation(${EXTEN:2}) ############################################################################# ;/etc/asterisk/zapata.conf ; ; Zapata telephony interface ; ; Configuration file ; ; You need to restart Asterisk to re-configure the Zap channel ; CLI> reload chan_zap.so ; will reload the configuration file, ; but not all configuration options are ; re-configured during a reload. [channels] context=from-pstn switchtype=national rxwink=300 ; Atlas seems to use long (250ms) winks usecallerid=yes hidecallerid=no callwaiting=yes usecallingpres=yes callwaitingcallerid=yes threewaycalling=yes transfer=yes canpark=yes cancallforward=yes callreturn=yes echocancel=yes echocancelwhenbridged=yes rxgain=0.0 txgain=0.0 group=1 callgroup=1 pickupgroup=1 immediate=no ; WildCard X101P group=2 signalling = fxs_ks context=line7 channel => 1 ; Rhino Modular group=1 signalling = fxs_ks context=line1 channel => 2 context=line2 channel => 3 context=line3 channel => 4 context=line4 channel => 5 context=line5 channel => 6 context=line6 channel => 7 context=from-internal group=3 signalling = fxo_ks channel => 8-9 ############################################################################# /// CLI with 20 v's Verbosity is at least 20 -- Remote UNIX connection -- Starting simple switch on 'Zap/4-1' -- Executing [s@line3:1] Macro("Zap/4-1", "slaline|line3|210") in new stack -- Executing [s@macro-slaline:1] SLATrunk("Zap/4-1", "line3") in new stack -- Created MeetMe conference 1023 for conference 'SLA_line3' Extension Changed station210_line3 new state Ringing for Notify User 210 Extension Changed station218_line3 new state Ringing for Notify User 218 Extension Changed station219_line3 new state Ringing for Notify User 219 Extension Changed station224_line3 new state Ringing for Notify User 224 Extension Changed station225_line3 new state Ringing for Notify User 225 -- Executing [**station224_line3@sla-stations:1] SLAStation("SIP/224-0826e740", "station224_line3") in new stack -- Hungup 'Zap/4-1' -- Hungup 'Zap/pseudo-833002520' [May 31 13:06:51] WARNING[14379]: app_meetme.c:2767 admin_exec: Conference number 'SLA_line3' not found! == Auto fallthrough, channel 'SIP/224-0826e740' status is 'UNKNOWN' Extension Changed station210_line3 new state Idle for Notify User 210 Extension Changed station218_line3 new state Idle for Notify User 218 Extension Changed station219_line3 new state Idle for Notify User 219 Extension Changed station224_line3 new state Idle for Notify User 224 Extension Changed station225_line3 new state Idle for Notify User 225 ############################################################################# /// /var/log/asterisk/messages [May 31 13:06:51] WARNING[14379] app_meetme.c: Conference number 'SLA_line3' not found!