Hi,<br><br>I was trying to use 2 of asterisk servers and interconnected, one of them as a peer to other sever (configured in sip.conf), so all the calls to server 1 will just be passed to server 2 (has PRI Card, TE 412P, only one PRI connected), i was sending calls to server 1 and that would send to server 2 and then dial out using Dahdi, but the problem that i got was the hangup cause codes, i was not able to pass the appropriate ones to the server 0 (Test server) that sent a call to server 1. For example, when the user at server 0 (test server) made a call to server 1, that sends it to server 2 and connects to the appropriate destination, but in the mean while if we just cancel the call, we need to see the SIP error code as 487 - Request terminated, but I was only able to see the ISDN core in PRI debug on server 2, but was not able to see &#39;487&#39; in sip debug, even though if i am handling the error code conditions........Is there any way of handling the error codes properly....?<br>
<br>Asterisk version: 1.4.22.1<br>Libpri: 1.4.10.1<br>dahdi: 2.2.0.2 are the versions that I am using.<br><br><br>The way I was handling the codes for the server 2:<br><br><br>[macro-result]<br>exten =&gt; s,1,Wait(1)<br>
exten =&gt; s,2,ResetCDR(w)<br>exten =&gt; s,3,NoCDR()<br>exten =&gt; s,4,GotoIf($[${ISNULL(${ARG1})}]?7:5)<br>exten =&gt; s,5,Set(RC=${ARG1})<br>exten =&gt; s,6,Goto(s|9)<br>exten =&gt; s,7,GotoIf($[${ISNULL(${DIALSTATUS})}]?8:rc-${DIALSTATUS}|1)<br>
exten =&gt; s,8,Set(RC=${IF($[${ISNULL(${HANGUPCAUSE})}]?0:${HANGUPCAUSE})})<br>exten =&gt; s,9,Goto(rc-${RC}|1)<br>exten =&gt; s,10,Hangup(${RC})<br>exten =&gt; i,1,Set(RC=0)<br>exten =&gt; i,2,Goto(s|9)<br><br>exten =&gt; rc-ANSWER,1,Set(RC=16)<br>
exten =&gt; rc-ANSWER,2,Goto(s|9)<br><br>exten =&gt; rc-BUSY,1,Set(RC=17)<br>exten =&gt; rc-BUSY,2,Goto(s|9)<br><br>exten =&gt; rc-CANCEL,1,Set(RC=16)<br>exten =&gt; rc-CANCEL,2,Goto(s|9)<br><br>exten =&gt; rc-CHANUNAVAIL,1,Set(RC=44)<br>
exten =&gt; rc-CHANUNAVAIL,2,Goto(s|9)<br><br>exten =&gt; rc-CONGESTION ,1,Set(RC=19)<br>exten =&gt; rc-CONGESTION ,2,Goto(s|9)<br><br>;exten =&gt; rc-NOANSWER,1,Set(RC=19)<br>;exten =&gt; rc-NOANSWER,2,Goto(s|9)<br><br>exten =&gt; rc-0,1,NoOp(NOTDEFINED)<br>
exten =&gt; rc-0,n,Goto(s|10)<br><br>exten =&gt; rc-1,1,NoOp(UNALLOCATED)<br>exten =&gt; rc-1,n,Goto(s|10)<br><br>exten =&gt; rc-2,1,NoOp(NO_ROUTE_TRANSIT_NET)<br>exten =&gt; rc-2,n,Goto(s|10)<br><br>exten =&gt; rc-3,1,NoOp(NO_ROUTE_DESTINATION)<br>
exten =&gt; rc-3,n,Goto(s|10)<br><br>exten =&gt; rc-6,1,NoOp(CHANNEL_UNACCEPTABLE)<br>exten =&gt; rc-6,n,Goto(s|10)<br><br>exten =&gt; rc-7,1,NoOp(CALL_AWARDED_DELIVERED)<br>exten =&gt; rc-7,n,Goto(s|10)<br><br>exten =&gt; rc-16,1,NoOp(NORMAL_CLEARING)<br>
exten =&gt; rc-16,n,Goto(s|10)<br><br>exten =&gt; rc-17,1,NoOp(USER_BUSY)<br>;exten =&gt; rc-17,n,Busy() <br>exten =&gt; rc-17,n,Goto(s|10)<br><br>exten =&gt; rc-18,1,NoOp(NO_USER_RESPONSE)<br>exten =&gt; rc-18,n,Goto(s|10)<br>
<br>exten =&gt; rc-19,1,NoOp(NO_ANSWER)<br>exten =&gt; rc-19,n,Goto(s|10)<br><br>exten =&gt; rc-21,1,NoOp(CALL_REJECTED)<br>exten =&gt; rc-21,n,Goto(s|10)<br><br><br>exten =&gt; rc-28,1,NoOp(INVALID_NUMBER_FORMAT)<br>exten =&gt; rc-28,n,Goto(s|10)<br>
<br>exten =&gt; rc-29,1,NoOp(FACILITY_REJECTED)<br>exten =&gt; rc-29,n,Goto(s|10)<br><br>exten =&gt; rc-30,1,NoOp(RESPONSE_TO_STATUS_ENQUIRY)<br>exten =&gt; rc-30,n,Goto(s|10)<br><br>exten =&gt; rc-31,1,NoOp(NORMAL_UNSPECIFIED)<br>
exten =&gt; rc-31,n,Goto(s|10)<br><br>exten =&gt; rc-34,1,NoOp(NORMAL_CIRCUIT_CONGESTION)<br>exten =&gt; rc-34,n,Congestion()<br>exten =&gt; rc-34,n,Goto(s|10)<br><br>Thank you for your help.<br><br>Regards<br>Sandesh<br>