Realtime with sip.conf


#1

Has anyone used sip.conf with asterisk realtime and MULTIPLE asterisk boxes sucessfully?

I haven’t quite worked out yet under what conditions it fails, but user A registered with one asterisk server can’t find user B registered with another Asterisk server eventhough BOTH have their contact details updated in sip_buddies. What gives with that? When you make a call, I can see with a network sniffer that the asterisk system does a ‘select * from sip_buddies where username=blah’ so it SHOULD be getting all the contact info for the other user…It’s friggin there!

Anyone got this to work?


#2

you also MUST configure this 2 asterisks to reach each other)


#3

What exactly do you mean by they must be able to reach each other?


#4

situation
asterisk 1 - box A
client 1 - CA
asterisk 2 - box B
client 2 - CB

client CA registers on A
client CB registers on B

in sip.conf
[CA]

context=out

[CB}

context=out
in extensions.conf on A you must write

[out]
exten => 1,1,ChanIsAvail(SIP/CA,j)
exten => 1,2,DIAL(SIP/CA)
exten => 1,101,DIAL(SIP/1@B)

exten => 2,1,ChanIsAvail(SIP/CA,j)
exten => 2,2,DIAL(SIP/CA)
exten => 2,101,DIAL(SIP/2@B)

in extensions.conf on B you must write

[out]
exten => 1,1,ChanIsAvail(SIP/CA,j)
exten => 1,2,DIAL(SIP/CA)
exten => 1,101,DIAL(SIP/1@A)

exten => 2,1,ChanIsAvail(SIP/CA,j)
exten => 2,2,DIAL(SIP/CA)
exten => 2,101,DIAL(SIP/2@B)

and you must on A and B register another box via sip…
then when you dial 1 you reach CA ALWAYS
when you dial 2 you reach CB ALWAYS