[Serusers] ser+asterisk+voicemail(resolved)

hofi raid at hofi.priv.at
Wed Mar 30 16:27:41 CEST 2005


hi rafael

yes that's it :)

thank you very much

regards
hofi

> Hi Hofi
> You must use t_check_status... this will solve your problem:
>
> failure_route[1]{
>         if (t_check_status("408|486")){   ## Do not include 487!!
>                 revert_uri ();
>                 rewritehostport ("x.x.x.x:port");
>                 append_branch();
>                 t_relay();
>                 break;
>         }
> }
>
> regards
>
> Rafael J. Risco G.V.
> Millicom Peru SA
>
>
>
> On Wed, 30 Mar 2005 11:58:32 +0200 (CEST), hofi <raid at hofi.priv.at> wrote:
>> hi
>>
>> the first problem is solved (pstn to voicemail !working!)
>>
>> ser config snip:
>>
>> loadmodule "/usr/local/lib/ser/modules/sl.so"
>> loadmodule "/usr/local/lib/ser/modules/tm.so"
>>
>> # ------------- tm parameters
>> modparam("tm", "fr_timer", 40)
>> modparam("tm", "fr_inv_timer", 35)
>> modparam("tm", "wt_timer", 5)
>> modparam("tm", "fr_inv_timer_avp", "inv_timeout")
>>
>> route {
>>      if (is_user_in("Request-URI", "voicemail")) {
>>                setflag(4);
>>        };
>>
>>        if (lookup("location") | lookup("aliases")) {
>>                if (method == "INVITE" && isflagset(4)) {
>>                log (1, "++++++++++++voicemail***********************");
>>                t_on_failure("1");
>>                avp_write("i:30", "inv_timeout");
>>            }
>>                route(2);
>>                break;
>>        };
>>
>> }
>>
>> route [2] {
>>        if (uri=~"[@:](192\.168\.|10\.|172\.(1[6-9]|2[0-9]|3[0-1])\.)" &&
>> !search("^Route:")){
>>                sl_send_reply("479", "We don't forward to private IP
>> addresses");
>>                break;
>>        };
>>        if (isflagset(2)) {
>>                force_rtp_proxy();
>>        };
>>        t_on_reply("1");
>>        if (!t_relay()) {
>>                sl_reply_error();
>>        };
>> }
>>
>> failure_route[1] {
>>        log (1, "++++++++++++Failure Route******************");
>>        revert_uri();
>>        rewritehost("XXX.XXX.XXX.XXX");
>>        append_branch();
>>        t_relay_to_udp("XXX.XXX.XXX.XXX", "5060");
>> }
>>
>> but for my second problem I do not find the error
>>
>> 2) if ua1 call ua2 (and ua2 is in the voicemail group) and ua1 hangs up
>> ser forwards to asterisk and the voicemail is run in the background, but
>> instead the call should be cancelled and not forwarded to the voicemail
>>
>> thx
>>
>> regards
>> hofi
>>
>> > I never did figure out exactly what the cause was [sorry], but we were
>> > looking into a secondary carrier and ran into the same problems you
>> > describe below.  We took one of our Cisco AS5350's to their NOC to put
>> > in place of their nextone and everything worked just fine.  You may
>> > want to look at the settings on your inalp.  We were unable to get it
>> > to work with the nextone.  My guess was that it had something to do
>> > with codec translations but I have no data to back that up.  All the
>> > SIP messaging seemed to be there.
>> >
>> > I'd be interested in what fixes this, so if you discover a solution,
>> > please post to the list.
>> >
>> > Thanks.
>> >
>> > dan
>> >
>> >
>> > On Tue, 29 Mar 2005 20:36:08 +0200 (CEST), hofi <raid at hofi.priv.at>
>> wrote:
>> >> hi all
>> >>
>> >> configuration:
>> >>
>> >> inalp gw (pstn) ------> ser ------> asterisk (only voicemail)
>> >>
>> >> the following problems occur:
>> >>
>> >> 1) ser forwards the call to asterisk (if the user is in the voicemail
>> >> group) if the client does not answer after 30 sec.
>> >> from sip to sip is working.
>> >> but if a call comes from the pstn to a sip client, the client rings
>> and
>> >> hangs up after 30 sec. ser then forwards it to the asterisk, but the
>> >> pstn
>> >> call keeps on ringing and no voicemail is to hear.
>> >>
>> >> ser writes the following error
>> >>
>> >> Mar 29 13:24:39 sip /usr/local/sbin/ser[7017]:
>> >> ++++++++++++INVITE******************
>> >> Mar 29 13:24:39 sip /usr/local/sbin/ser[7017]:
>> >> ++++++++++++voicemail***********************
>> >> Mar 29 13:25:19 sip /usr/local/sbin/ser[7022]:
>> >> ++++++++++++Failure Route******************
>> >> Mar 29 13:25:19 sip /usr/local/sbin/ser[7022]:
>> >> ++++++++++++Failure Route******************
>> >> Mar 29 13:25:19 sip /usr/local/sbin/ser[7017]:
>> >> ++++++++++++voicemail***********************
>> >> Mar 29 13:25:19 sip /usr/local/sbin/ser[7016]: ERROR:
>> >> t_should_relay_response: status rewrite by UAS: stored: 408,
>> received:
>> >> 200
>> >> Mar 29 13:25:20 sip /usr/local/sbin/ser[7017]: ERROR:
>> >> t_should_relay_response: status rewrite by UAS: stored: 408,
>> received:
>> >> 200
>> >> Mar 29 13:25:21 sip /usr/local/sbin/ser[7016]: ERROR:
>> >> t_should_relay_response: status rewrite by UAS: stored: 408,
>> received:
>> >> 200
>> >> Mar 29 13:25:24 sip last message repeated 3 times
>> >> Mar 29 13:25:28 sip /usr/local/sbin/ser[7015]:
>> >>  ++++++++++++Loose Route******************
>> >> Mar 29 13:25:28 sip /usr/local/sbin/ser[7014]: contact_parser():
>> Empty
>> >> body Mar 29 13:25:28 sip /usr/local/sbin/ser[7014]: parse_contact():
>> >> Error
>> >> while parsing
>> >> Mar 29 13:25:28 sip /usr/local/sbin/ser[7014]: get_contact_uri: Error
>> >> while parsing Contact body
>> >>
>> >> 2) if ua1 call ua2 (and ua2 is in the voicemail group) and ua1 hangs
>> up
>> >> ser forwards to asterisk and the voicemail is run in the background,
>> but
>> >> instead the call should be cancelled and not forwarded to the
>> voicemail
>> >>
>> >> does anyone know about these problems?
>> >>
>> >> regards
>> >> raid
>> >>
>> >> ser config snip:
>> >>
>> >> loadmodule "/usr/local/lib/ser/modules/sl.so"
>> >> loadmodule "/usr/local/lib/ser/modules/tm.so"
>> >>
>> >> # ------------- tm parameters
>> >> modparam("tm", "fr_timer", 30)
>> >> modparam("tm", "fr_inv_timer", 25)
>> >> modparam("tm", "wt_timer", 5)
>> >> modparam("tm", "fr_inv_timer_avp", "inv_timeout")
>> >>
>> >> route {
>> >>         if (lookup("location") | lookup("aliases")) {
>> >>                 if (is_user_in("Request-URI", "voicemail")) {
>> >>                 log (1,
>> "++++++++++++voicemail***********************");
>> >> t_on_failure("1");
>> >>                 avp_write("i:30", "inv_timeout");
>> >>                 t_relay();
>> >>                 route(2);
>> >>                 break;
>> >>         } else {
>> >>                 log (1, "++++++++++++no
>> voicemail********************");
>> >> route(2);
>> >>                 break;
>> >>                 }
>> >>         }
>> >>
>> >> }
>> >>
>> >> route [2] {
>> >>         if
>> (uri=~"[@:](192\.168\.|10\.|172\.(1[6-9]|2[0-9]|3[0-1])\.)"
>> >> &&
>> >> !search("^Route:")){
>> >>                 sl_send_reply("479", "We don't forward to private IP
>> >> addresses");
>> >>                 break;
>> >>         };
>> >>         if (isflagset(2)) {
>> >>                 force_rtp_proxy();
>> >>         };
>> >>         t_on_reply("1");
>> >>         if (!t_relay()) {
>> >>                 sl_reply_error();
>> >>         };
>> >> }
>> >>
>> >> failure_route[1] {
>> >>         log (1, "++++++++++++Failure Route******************");
>> >>         revert_uri();
>> >>         rewritehostport("XXX.XXX.XXX.XXX:5060");
>> >>         append_branch();
>> >>         t_on_failure("1");
>> >>         t_relay();
>> >>         break();
>> >>
>> >> }
>> >>
>> >> _______________________________________________
>> >> Serusers mailing list
>> >> serusers at lists.iptel.org
>> >> http://lists.iptel.org/mailman/listinfo/serusers
>> >>
>> >
>>
>> _______________________________________________
>> Serusers mailing list
>> serusers at lists.iptel.org
>> http://lists.iptel.org/mailman/listinfo/serusers
>>
>
>
> --
>
> rrgv
>




More information about the sr-users mailing list