Daniel Floeckinger Posted May 6, 2007 Report Posted May 6, 2007 I am trying to do the following: Currently we are connected to 2 telcos of which one hosts our tel. number. We want to receive calls thru telco1 and send calls to both depending on the prefix. Incomming calls (Telco1): Extension dialed -> route to the selected extension number. No extension or unknown extension -> route to extension 25 Outgoing calls (Telco2): Everything comming from the PBX should be routed to Telco2 except calls from Extension 15 (fax) which should be routed thru telco1. (Telco2 is not able to switch to T38). Prefix of a external line should be 0. How can i do that? Thanks in advance! Quote
Vodia PBX Posted May 7, 2007 Report Posted May 7, 2007 Incoming calls on Telco1: Set in the "Extension" field of the trunk: "!(.*)!\1!u!25!" (see http://wiki.pbxnsip.com/index.php/Inbound_Calls_on_Trunk). If your operator sends the extension in the To-header, choose "!(.*)!\1!t!25!". Outgoing calls: Create two dial plans. Make Plan1 your default dial plan for the domain (http://wiki.pbxnsip.com/index.php/Domain_Settings#Default_Dial_Plan), and assign Plan2 to the fax extension. Both plans just use the star as the pattern (no replacement) and route to the Telco1 and Telco2, respectively (see http://wiki.pbxnsip.com/index.php/Dial_Plan). If you want, you can use a pattern like 0* as a prefix for the dial plan. However, my suggestion is not to use any prefixes. Just make the numbers diallable as they are - on a cell phone you also don't use a prefix to dial a number. That makes the address book much easier and you can call back missed calls. Quote
Daniel Floeckinger Posted May 7, 2007 Author Report Posted May 7, 2007 Does not work.... Here is a trace from our VOIP-ISDN Gateway Can you see the "To: <sip:192.168.16.11>" ? There is no extension! [52:49.90] i[04]: pstnrcv setup dad DF: oad 06641607997 cc 40 id 44d027 c/c=4/1 [52:49.92] i[04]: pstnrcv get_voipcfg <DF> compr <A> [52:49.93] x[04]: sip_send 754 192.168.16.11:5060 [52:49.95] x[04]: INVITE sip:192.168.16.11 SIP/2.0 [52:49.96] x[04]: Max-Forwards: 50 [52:49.98] x[04]: Via: SIP/2.0/UDP 192.168.16.12:5060;rport;branch=z9hG4bK60536325956379204269682 [52:49.99] x[04]: From: <sip:06641607997@192.168.16.12>;tag=676933635591324563097352172832 [52:50.01] x[04]: To: <sip:192.168.16.11> [52:50.03] x[04]: Call-ID: 856397878008217682549955350971@192.168.16.12 [52:50.04] x[04]: CSeq: 1 INVITE [52:50.06] x[04]: P-Asserted-Identity: tel:06641607997 [52:50.07] x[04]: Contact: <sip:06641607997@192.168.16.12> [52:50.09] x[04]: User-Agent: TELES.VoIPBOX 13.0b 885 [52:50.10] x[04]: Allow: INVITE,ACK,CANCEL,BYE,UPDATE,REGISTER,PRACK,INFO,NOTIFY,REFER [52:50.12] x[04]: Timestamp: 1178524369 [52:50.14] x[04]: Content-Type: application/sdp [52:50.15] x[04]: Content-Length: 187 [52:50.17] x[04]: v=0 [52:50.18] x[04]: o=- 39 1 IN IP4 192.168.16.12 [52:50.20] x[04]: s=- [52:50.21] x[04]: c=IN IP4 192.168.16.12 [52:50.23] x[04]: t=0 0 [52:50.24] x[04]: m=audio 29000 RTP/AVP 8 101 [52:50.26] x[04]: a=rtpmap:8 PCMA/8000 [52:50.28] x[04]: a=ptime:20 [52:50.29] x[04]: a=rtpmap:101 telephone-event/8000 [52:50.31] x[04]: a=fmtp:101 0-15 [52:50.32] x[04]: sipsnd invite dad cr 27 to 192.168.16.11 rc 754 [52:50.34] y[04]: sip_recvfrom 312 192.168.16.11:5060 [52:50.35] y[04]: SIP/2.0 100 Trying [52:50.37] y[04]: Via: SIP/2.0/UDP 192.168.16.12:5060;rport=5060;branch=z9hG4bK60536325956379204269682 [52:50.37] y[04]: From: <sip:06641607997@192.168.16.12>;tag=676933635591324563097352172832 [52:50.40] y[04]: To: <sip:192.168.16.11>;tag=bf22502ab2 [52:50.42] y[04]: Call-ID: 856397878008217682549955350971@192.168.16.12 [52:50.43] y[04]: CSeq: 1 INVITE [52:50.45] y[04]: Content-Length: 0 [52:50.46] y[04]: siprcv trying from 192.168.16.11 cr 27 [52:50.48] y[04]: sip_recvfrom 599 192.168.16.11:5060 [52:50.49] y[04]: SIP/2.0 404 Not Found [52:50.51] y[04]: Via: SIP/2.0/UDP 192.168.16.12:5060;rport=5060;branch=z9hG4bK60536325956379204269682 [52:50.53] y[04]: From: <sip:06641607997@192.168.16.12>;tag=676933635591324563097352172832 [52:50.54] y[04]: To: <sip:192.168.16.11>;tag=bf22502ab2 [52:50.56] y[04]: Call-ID: 856397878008217682549955350971@192.168.16.12 [52:50.57] y[04]: CSeq: 1 INVITE [52:50.59] y[04]: Contact: <sip:sippbx@192.168.16.11:5060;transport=udp> [52:50.60] y[04]: Supported: 100rel, replaces, norefersub [52:50.62] y[04]: Allow-Events: refer [52:50.64] y[04]: Allow: INVITE, ACK, CANCEL, BYE, REFER, OPTIONS, PRACK, INFO, PUBLISH, NOTIFY, SUBSCRIBE, MESSAGE [52:50.65] y[04]: Accept: application/sdp [52:50.67] y[04]: User-Agent: FL-Connect IP-PBX/2.0.3.1715 [52:50.68] y[04]: Content-Length: 0 [52:50.70] y[04]: siprcv terminate (404) from 192.168.16.11 cr 27 [52:50.71] x[04]: sip_send 513 192.168.16.11:5060 [52:50.73] x[04]: ACK sip:sippbx@192.168.16.11:5060;transport=udp SIP/2.0 [52:50.74] x[04]: Max-Forwards: 50 [52:50.76] x[04]: Via: SIP/2.0/UDP 192.168.16.12:5060;rport=5060;branch=z9hG4bK60536325956379204269682 [52:50.78] x[04]: From: <sip:06641607997@192.168.16.12>;tag=676933635591324563097352172832 [52:50.79] x[04]: To: <sip:192.168.16.11>;tag=bf22502ab2 [52:50.81] x[04]: Contact: <sip:06641607997@192.168.16.12> [52:50.82] x[04]: User-Agent: TELES.VoIPBOX 13.0b 885 [52:50.84] x[04]: Call-ID: 856397878008217682549955350971@192.168.16.12 [52:50.85] x[04]: CSeq: 1 ACK [52:50.87] x[04]: Allow: INVITE,ACK,CANCEL,BYE,UPDATE,REGISTER,PRACK,INFO,NOTIFY,REFER [52:50.89] x[04]: Content-Length: 0 [52:50.90] x[04]: sipsnd ack cr 27 to 192.168.16.11 rc 513 Quote
Vodia PBX Posted May 8, 2007 Report Posted May 8, 2007 Ehhhh.... I would say the PSTN gateway should know which number is being called. There must be something in the gateway that should be configured in order to do this. There is nothing like an "anonymous destination"... Alternatively, you can try the pattern "!(.*)!\1!t! 25" (see the space between the two party of this pattern). Then the PBX should route the call to 25 if the pattern resolution does not come up with a match. Quote
Daniel Floeckinger Posted May 8, 2007 Author Report Posted May 8, 2007 Oh... then welcome to Europe! The Gateway only sends the extension number. Nothing else. And if there is no extension number it is annonymous. Thats normal here. BTW, your pattern does not work. Quote
Vodia PBX Posted May 8, 2007 Report Posted May 8, 2007 Well, in most countries is it quite normal that the From header contains something anonymous - typically if the caller does not want to reveal the identity. However in this case the To-header is "anonymous". I don't get the use-case here. Does the caller not want to say which number he wants to talk to? Maybe you can make the gateway send the whole "DID" number (don't strip the prefix) - then we are able to route it somehow. Might be a kind of workaround to get it working with the current version, then later we might have to think about routing calls without extension numbers. Quote
Daniel Floeckinger Posted May 9, 2007 Author Report Posted May 9, 2007 In Austria and Germany, all you get from the Telco is a ISDN Telephone number. It is up to you if you use it for a PBX or not. We, for example have +437242351088. If a customer dials this number he reaches our PBX. The PBX waits for 3 seconds if a extension number is send or not. This is done by overlap dialing in the ISDN B-Channel. If a extension is dialed, the PBX routes to the extension. If nothing is dialed, or the extension is unknown, it connects to the operator or whatever. Thats how it works here. I have no influence in that but maybe i can change the incommig number in the gateway. I need to check. , Thanks anyways. Quote
Vodia PBX Posted May 10, 2007 Report Posted May 10, 2007 Overlap dialling and SIP - ouch... We know this problem very well. Cell phones work (the do not do overlap dialling), regular ISTN phones don't get through. But I believe you can still address the problem by using the whole number and then send it either directly to the extension or to an auto attendant. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.