Sir,<br>A.J.Stiles<br><br>This dialplan is not working . when I called to out of box . <br><br><br><div class="gmail_quote">On Tue, May 10, 2011 at 2:00 PM, A J Stiles <span dir="ltr"><<a href="mailto:asterisk_list@earthshod.co.uk">asterisk_list@earthshod.co.uk</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div class="im">On Tuesday 10 May 2011, mahesh katta wrote:<br>
> sir,<br>
><br>
> Below configuration i wase made in server . but this is not working.<br>
><br>
><br>
> exten => _90XXXXXXXXX,1,NoOp(${CALLERID(num)})<br>
> exten => _90XXXXXXXXX/5001,2,Set(CALLERID(name)=44578999)<br>
> exten => _90XXXXXXXXX,3,AGI(agi://<a href="http://127.0.0.1:4577/call_log" target="_blank">127.0.0.1:4577/call_log</a>)<br>
> exten => _90XXXXXXXXX/5001,4,Set(CALLERID(num)=44578999)<br>
> exten =><br>
> _90XXXXXXXXX,5,MixMonitor(/var/spool/asterisk/astrec/${TIMESTAMP}-${CALLERI<br>
>DNUM}-${EXTEN}-${UNIQUEID}.gsm|av(0)V(0)) exten =><br>
> _90XXXXXXXXX,6,Dial(${TRUNK}/${EXTEN:1},,tTo)<br>
> exten => _90XXXXXXXXX,7,Hangup<br>
<br>
</div>OK. Here's what I see going on.<br>
<br>
When you dial 90XXXXXXXXX:<br>
Stage 1: The NoOp() will just write the CALLERID(num) to the console. (This<br>
initially will be the originating extension number.)<br>
Stage 2: If the originating extension is 5001, the CALLERID(name) will be set<br>
to 44578999.<br>
Stage 3: Calls an AGI script, presumably to log the call outside of the CDR<br>
database.<br>
Stage 4: If the originating extension is 5001, the CALLERID(num) will be set<br>
to 44578999.<br>
Stage 5: Starts a recording.<br>
Stage 6: Passes the dialled number, skipping 1 digit from the beginning<br>
(i.e. the initial 9 for the outside line), to a Dial() command.<br>
Stage 7: Hangs up.<br>
<br>
I'm not at all convinced that this is right, especially as you are mixing<br>
destination extensions with and without originating extensions. And, the way<br>
this bit is written, it will only ever set the outgoing caller ID for<br>
extension 5001.<br>
<br>
I think it needs to be more like this. Here, I'm taking an educated guess<br>
that you want your caller ID to appear on outgoing calls as 445789 followed<br>
by the last 2 digits of the extension number. If this is not right, you will<br>
have to change it -- or explain exactly how to derive the caller ID you want<br>
to appear on external phones, from the originating internal extension, like I<br>
originally asked.<br>
<div class="im"><br>
exten => _90XXXXXXXXX,1,NoOp(${CALLERID(num)})<br>
</div>exten => _90XXXXXXXXX,2,Set(outgoing_ident=445789${CALLERID(num):-2})<br>
exten => _90XXXXXXXXX,3,NoOp(${outgoing_ident})<br>
exten => _90XXXXXXXXX,4,Set(CALLERID(name)=${outgoing_ident})<br>
exten => _90XXXXXXXXX,5,AGI(agi://<a href="http://127.0.0.1:4577/call_log" target="_blank">127.0.0.1:4577/call_log</a>)<br>
exten => _90XXXXXXXXX,6,Set(CALLERID(num)=${outgoing_ident})<br>
exten =><br>
_90XXXXXXXXX,7,MixMonitor(/var/spool/asterisk/astrec/${TIMESTAMP}-${CALLERIDNUM}-${EXTEN}-${UNIQUEID}.gsm|<br>
av(0)V(0))<br>
exten =>_90XXXXXXXXX,8,Dial(${TRUNK}/${EXTEN:1},,tTo)<br>
exten => _90XXXXXXXXX,9,Hangup<br>
<br>
What this will do:<br>
<br>
Stage 1: The NoOp() will just write the CALLERID(num) to the console. (This<br>
initially will be the originating extension number.)<br>
Stage 2: Creates a variable "outgoing_ident". This consists of the string<br>
445789 followed by the last 2 digits of the originating extension number.<br>
Stage 3: The NoOp() will write the value of ${outgoing_ident} to the console.<br>
Stage 4: Sets CALLERID(name) to the value we just put into ${outgoing_ident}.<br>
Stage 5: Calls logging AGI script.<br>
Stage 6: Sets CALLERID(num) to the value we just put into ${outgoing_ident}.<br>
This is most likely to be noticed.<br>
Stage 7: Starts recording.<br>
Stage 8: Passes the dialled number, skipping 1 digit from the beginning, to a<br>
Dial() command.<br>
Stage 9: Hangs up.<br>
<br>
Modify stage 2 if necessary to suit exactly how you want your outgoing ident<br>
to appear. You can take out the NoOp() statements and renumber appropriately<br>
once it's working as you want it.<br>
<br>
Note that if the console seems to show you created the right ident but it<br>
doesn't appear on phones when you dial out, then either the format is wrong<br>
or your telco doesn't think you are authorised to use that ident; this is a<br>
matter you will need to take up with your phone company.<br>
<font color="#888888"><br>
--<br>
</font><div><div></div><div class="h5">AJS<br>
<br>
Answers come *after* questions.<br>
<br>
--<br>
_____________________________________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" target="_blank">http://www.api-digital.com</a> --<br>
New to Asterisk? Join us for a live introductory webinar every Thurs:<br>
<a href="http://www.asterisk.org/hello" target="_blank">http://www.asterisk.org/hello</a><br>
<br>
asterisk-users mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-users" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-users</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br><font face="Verdana, sans-serif"><font size="2"><font color="#000000">Best
Regards, <br><br>Mahesh Katta</font><br><font color="#ff9900"><b>BUZZ</b></font><font color="#000000"><b>WORKS</b></font><font color="#000000">
Business Services Private Limited<br></font><font color="#999999">BANGALORE
</font><font color="#000000">| </font><font color="#999999">CHENNAI </font><font color="#808080">|
</font><font color="#999999">HYDERABAD </font><font color="#000000">|
</font><font color="#ff9900">MUMBAI| </font><font color="#999999">DELHI<br></font><font color="#000000">201, Crystal Tower, 75 Gundavali Cross Lane, Andheri Kurla Road, Andheri (E) Mumbai 400069</font><font color="#666666"><br>
</font><font color="#ff9900">GSM</font><font color="#000000">
+91.97029.70779 | </font><font color="#ff9900">Phone </font><font color="#000000">+91.22.4229.2634
| </font><font color="#ff9900">Fax </font><font color="#000000">+91.22.4229.2634<br></font><font color="#ff9900">Web</font><font color="#000000">
<a href="http://www.buzzworks.com/" target="_blank">http://www.buzzworks.com<br></a></font></font></font><br>