Can I use IAX to connect two servers together, so that it looks like this:
Phone1 making call to phone2 on another server:
Phone to Server1: SIP
Server1 to server2: IAX
Server2 to Phone2: SIP
???
Cuz I can’t find any good and cheap IAX phones…
Can I use IAX to connect two servers together, so that it looks like this:
Phone1 making call to phone2 on another server:
Phone to Server1: SIP
Server1 to server2: IAX
Server2 to Phone2: SIP
???
Cuz I can’t find any good and cheap IAX phones…
Yes, that would be pretty much a standard way to do things. It’s fairly trivial to configure. You just need configure some kind of dial code or something, to route the calls to the other server.
For example, you could prefix calls to extensions on the other server with “99” and then have an extension like this in your dialplan:
exten => _99.,1,Dial(SIP/${EXTEN:2}@otherserver)
That’s only the bare bones of it, of course. You’ll need to do all the configuration as normal.
oh… LOL
All this time I’ve been going nuts trying to find cheap IAX supporting phones, then i discover i dont even need them!
But, one question…you say:
exten => _99.,1,Dial(SIP/${EXTEN:2}@otherserver)
shouldn’t i then specify Dial(IAX2/${EXTEN:2}@otherserver)???
since i would be using iax to connect them?
Would I config the other servers in IAX.conf still?
[quote=“Computer Guru”]exten => _99.,1,Dial(SIP/${EXTEN:2}@otherserver)
shouldn’t i then specify Dial(IAX2/${EXTEN:2}@otherserver)???
since i would be using iax to connect them?[/quote]
If you want to use IAX2 to connect them, then yeah, you’d have a Dial(IAX2/…) command instead of a SIP one. The above was just an example of the approach you’d take to doing it, not an indication of how it must be done. I just quickly pasted this in - without thinking about the SIP/IAX2 thing. If i was doing it, i’d use IAX2 between two asterisk servers.
If you’re connecting with IAX2, yes. If with SIP, no.
Also, of course, you don’t really have to have a “prefix” which you dial to connect to phones at another location, you can make it completely transparent by using unique extension numbers at each place.
For example extensions 1000 to 2999 could be routed to server ‘A’, 3000 to 4999 to server ‘B’, 5000 to 5999 to server ‘C’, 6000 to 9999 to ‘D’, with numbers starting with 0 reserved for special purposes, e.g. outside lines, voicemail, etc. It’s not very complicated to implement a dialplan like that.
I realize that… I’m beginning to like asterisk very much …
Thanks guys…
Yeah, it’s pretty amazing, ey?
By the way, i just thought i should correct the Dial(IAX2…) statement above. It’s a different format from SIP Dial() statements. Rather than
Dial(IAX2/${EXTEN:2}@otherserver)
it should be
Dial(IAX2/username:@otherserver/{EXTEN:2})
Just to avoid confusion.
Hey thanks!
That was going to be my question right now… Lifesavers all of you!