too many hops

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|

too many hops

kostenftw
im trying to establish connection between 2 phones
user1: 43384001
user2: 43384002

i have user 2 added to usrloc with the cmd:

opensipsctl ul add 43384003 sip:+1043384003*[hidden email]
which is an asterisk server that handles calls in a specific way.

but when i try to call i get "too many hops"

this is my invite handling

if (method=="INVITE")
    {
        t_relay();
        exit;
    };

do i need some sort of line added to include using usrloc
--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Fwd: too many hops

kostenftw


im trying to establish connection between 2 phones
user1: 43384001
user2: 43384002

i have user 2 added to usrloc with the cmd:

opensipsctl ul add 43384003 sip:+1043384003*[hidden email]
which is an asterisk server that handles calls in a specific way.

but when i try to call i get "too many hops"

this is my invite handling

if (method=="INVITE")
    {
        t_relay();
        exit;
    };

do i need some sort of line added to include using usrloc


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: too many hops

Laszlo
In reply to this post by kostenftw
If you added an usrloc entry, then you will need to use some kind of locaton lookup and then route accordingly.

- Laszlo


2014-03-10 11:03 GMT+01:00 Mike Claudi Pedersen <[hidden email]>:
im trying to establish connection between 2 phones
user1: 43384001
user2: 43384002

i have user 2 added to usrloc with the cmd:

opensipsctl ul add 43384003 sip:+1043384003*[hidden email]
which is an asterisk server that handles calls in a specific way.

but when i try to call i get "too many hops"

this is my invite handling

if (method=="INVITE")
    {
        t_relay();
        exit;
    };

do i need some sort of line added to include using usrloc
--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users




--

--
Kind regards,
Laszlo Bekesi
http://voipfreak.net

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: too many hops

Stefano Pisani
In reply to this post by kostenftw
It seems an addressing issue.
Could you post your opensips.cfg?
Are you able to log the sip session using ngrep? Post it.

Il 10/03/2014 11.03, Mike Claudi Pedersen ha scritto:
im trying to establish connection between 2 phones
user1: 43384001
user2: 43384002

i have user 2 added to usrloc with the cmd:

opensipsctl ul add 43384003 sip:+1043384003*[hidden email]
which is an asterisk server that handles calls in a specific way.

but when i try to call i get "too many hops"

this is my invite handling

if (method=="INVITE")
    {
        t_relay();
        exit;
    };

do i need some sort of line added to include using usrloc
--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: too many hops

kostenftw
In reply to this post by Laszlo
could you please give an example?


2014-03-10 11:08 GMT+01:00 Laszlo <[hidden email]>:
If you added an usrloc entry, then you will need to use some kind of locaton lookup and then route accordingly.

- Laszlo


2014-03-10 11:03 GMT+01:00 Mike Claudi Pedersen <[hidden email]>:
im trying to establish connection between 2 phones
user1: 43384001
user2: 43384002

i have user 2 added to usrloc with the cmd:

opensipsctl ul add 43384003 sip:+1043384003*[hidden email]
which is an asterisk server that handles calls in a specific way.

but when i try to call i get "too many hops"

this is my invite handling

if (method=="INVITE")
    {
        t_relay();
        exit;
    };

do i need some sort of line added to include using usrloc
--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users




--

--
Kind regards,
Laszlo Bekesi
http://voipfreak.net

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users




--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: too many hops

kostenftw
In reply to this post by Stefano Pisani
the log are only spammed with subscriptions


2014-03-10 11:09 GMT+01:00 Stefano Pisani <[hidden email]>:
It seems an addressing issue.
Could you post your opensips.cfg?
Are you able to log the sip session using ngrep? Post it.

Il 10/03/2014 11.03, Mike Claudi Pedersen ha scritto:
im trying to establish connection between 2 phones
user1: 43384001
user2: 43384002

i have user 2 added to usrloc with the cmd:

opensipsctl ul add 43384003 sip:+1043384003*[hidden email]
which is an asterisk server that handles calls in a specific way.

but when i try to call i get "too many hops"

this is my invite handling

if (method=="INVITE")
    {
        t_relay();
        exit;
    };

do i need some sort of line added to include using usrloc
--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users




--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users

cfg.txt (20K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: too many hops

Liviu Chircu
In reply to this post by kostenftw
Hello Mike,

Instead of simply relaying initial INVITEs, you should also add some registrar logic. You need at least something like this:

if (!lookup("location")) {
        t_reply("404", "Not Found");
        exit;
}

A successful registrar lookup will also rewrite the R-URI of your requests. Read more about it here [1].

[1]: http://www.opensips.org/html/docs/modules/1.11.x/registrar.html#id294027

Best regards,
Liviu Chircu
OpenSIPS Developer
http://www.opensips-solutions.com
On 03/10/2014 12:03 PM, Mike Claudi Pedersen wrote:
im trying to establish connection between 2 phones
user1: 43384001
user2: 43384002

i have user 2 added to usrloc with the cmd:

opensipsctl ul add 43384003 sip:+1043384003*[hidden email]
which is an asterisk server that handles calls in a specific way.

but when i try to call i get "too many hops"

this is my invite handling

if (method=="INVITE")
    {
        t_relay();
        exit;
    };

do i need some sort of line added to include using usrloc
--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: too many hops

kostenftw
if i just add a user and a usrloc to my usrloc database
eg.

opensipsctl add user1 1234
opensipsctl ul add user1 [hidden email]

how do i in the simplest manner rewrite the call?
so when i call user1 from user2, it rewrites user1 to [hidden email]

if i could just understand how this part is written in the config i think i'll find the rest much easier

 


2014-03-10 11:56 GMT+01:00 Liviu Chircu <[hidden email]>:
Hello Mike,

Instead of simply relaying initial INVITEs, you should also add some registrar logic. You need at least something like this:

if (!lookup("location")) {
        t_reply("404", "Not Found");
        exit;
}

A successful registrar lookup will also rewrite the R-URI of your requests. Read more about it here [1].

[1]: http://www.opensips.org/html/docs/modules/1.11.x/registrar.html#id294027

Best regards,
Liviu Chircu
OpenSIPS Developer
http://www.opensips-solutions.com
On 03/10/2014 12:03 PM, Mike Claudi Pedersen wrote:
im trying to establish connection between 2 phones
user1: 43384001
user2: 43384002

i have user 2 added to usrloc with the cmd:

opensipsctl ul add 43384003 sip:+1043384003*[hidden email]
which is an asterisk server that handles calls in a specific way.

but when i try to call i get "too many hops"

this is my invite handling

if (method=="INVITE")
    {
        t_relay();
        exit;
    };

do i need some sort of line added to include using usrloc
--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users




--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: too many hops

kostenftw
nevermind, i found out that i forgot to add the user... only added the user location. now it works as intended


2014-03-10 12:08 GMT+01:00 Mike Claudi Pedersen <[hidden email]>:
if i just add a user and a usrloc to my usrloc database
eg.

opensipsctl add user1 1234
opensipsctl ul add user1 [hidden email]

how do i in the simplest manner rewrite the call?
so when i call user1 from user2, it rewrites user1 to [hidden email]

if i could just understand how this part is written in the config i think i'll find the rest much easier

 


2014-03-10 11:56 GMT+01:00 Liviu Chircu <[hidden email]>:

Hello Mike,

Instead of simply relaying initial INVITEs, you should also add some registrar logic. You need at least something like this:

if (!lookup("location")) {
        t_reply("404", "Not Found");
        exit;
}

A successful registrar lookup will also rewrite the R-URI of your requests. Read more about it here [1].

[1]: http://www.opensips.org/html/docs/modules/1.11.x/registrar.html#id294027

Best regards,
Liviu Chircu
OpenSIPS Developer
http://www.opensips-solutions.com
On 03/10/2014 12:03 PM, Mike Claudi Pedersen wrote:
im trying to establish connection between 2 phones
user1: 43384001
user2: 43384002

i have user 2 added to usrloc with the cmd:

opensipsctl ul add 43384003 sip:+1043384003*[hidden email]
which is an asterisk server that handles calls in a specific way.

but when i try to call i get "too many hops"

this is my invite handling

if (method=="INVITE")
    {
        t_relay();
        exit;
    };

do i need some sort of line added to include using usrloc
--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users




--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk



--
Med venlig hilsen
ipnordic A/S

Mike Claudi Pedersen
Tekniker

Telefon: 79301033
www.ipnordic.dk

_______________________________________________
Users mailing list
[hidden email]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users