Jump to content

connect remote office through vpn


lirees

Recommended Posts

i would connect two offices through a vpn connection, but I have many problems

 

i have create two trunk gateway in this way:

 

office1 ( 172.16.10.210 )

Name: office2

Type: sip gateway

Direction: in and out

Trunk Destination: generic sip server

State: enabled

Account: 123

Domain: 192.168.1.60

Username: 123

Password: ****

Proxy Address: 192.168.1.60

 

office2 ( 192.168.1.60 )

Name: office1

Type: sip gateway

Direction: in and out

Trunk Destination: generic sip server

State: enabled

Account: 123

Domain: 172.16.10.210

Username: 123

Password: ****

Proxy Address: 172.16.10.210

 

the extension in the office1 is 2xx and in the office2 is 3xx

 

the dial plan for office1 is :

pref 100

Trunk office2

Pattern: 3xx

Replacement: *

 

the dial plan for office2 is :

pref 100

Trunk office1

Pattern: 2xx

Replacement: *

 

when i make a call from office1 to office2 and viceversa i give this error :

[5] 2011/02/04 11:35:48:	SIP Rx udp:192.168.1.50:5060:
INVITE sip:200@172.16.10.210;user=phone SIP/2.0
Via: SIP/2.0/UDP 192.168.1.50:5060;branch=z9hG4bK-b92a3ef5cc37de1cd2c5a3beef75589d;rport
From: "poa" <sip:300@192.168.1.50;user=phone>;tag=18523
To: <sip:200@172.16.10.210;user=phone>
Call-ID: 9e1eef98@pbx
CSeq: 12399 INVITE
Max-Forwards: 70
Contact: <sip:123@192.168.1.50:5060;transport=udp>
Supported: 100rel, replaces, norefersub
Allow-Events: refer
Allow: INVITE, ACK, CANCEL, BYE, REFER, PRACK, INFO, UPDATE
Accept: application/sdp
User-Agent: snom-PBX/2011-4.2.0.3981
P-Asserted-Identity: "vm" <sip:123@172.16.10.210>
Content-Type: application/sdp
Content-Length: 327

v=0
o=- 17786 17786 IN IP4 192.168.1.50
s=-
c=IN IP4 192.168.1.50
t=0 0
m=audio 55380 RTP/AVP 0 8 9 2 3 101
a=rtpmap:0 pcmu/8000
a=rtpmap:8 pcma/8000
a=rtpmap:9 g722/8000
a=rtpmap:2 g726-32/8000
a=rtpmap:3 gsm/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=rtcp-xr:rcvr-rtt=all voip-metrics
a=sendrecv

[5] 2011/02/04 11:35:48:	Last message repeated 2 times
[5] 2011/02/04 11:35:48:	SIP Tx udp:192.168.1.50:5060:

SIP/2.0 100 Trying
Via: SIP/2.0/UDP 192.168.1.50:5060;branch=z9hG4bK-b92a3ef5cc37de1cd2c5a3beef75589d;rport=5060
From: "poa" <sip:300@192.168.1.50;user=phone>;tag=18523
To: <sip:200@172.16.10.210;user=phone>;tag=d2057dfc98
Call-ID: 9e1eef98@pbx
CSeq: 12399 INVITE
Content-Length: 0

[5] 2011/02/04 11:35:48:	Received incoming call without trunk information and user has not been found
[5] 2011/02/04 11:35:48:	SIP Tx udp:192.168.1.50:5060:

SIP/2.0 404 Not Found
Via: SIP/2.0/UDP 192.168.1.50:5060;branch=z9hG4bK-b92a3ef5cc37de1cd2c5a3beef75589d;rport=5060
From: "poa" <sip:300@192.168.1.50;user=phone>;tag=18523
To: <sip:200@172.16.10.210;user=phone>;tag=d2057dfc98
Call-ID: 9e1eef98@pbx
CSeq: 12399 INVITE
Contact: <sip:200@172.16.10.210:5060>
Supported: 100rel, replaces, norefersub
Allow-Events: refer
Allow: INVITE, ACK, CANCEL, BYE, REFER, PRACK, INFO, UPDATE
Accept: application/sdp
User-Agent: snom-PBX/2011-4.2.0.3981
Content-Length: 0

[5] 2011/02/04 11:35:48:	SIP Rx udp:192.168.1.50:5060:
ACK sip:200@172.16.10.210;user=phone SIP/2.0
Via: SIP/2.0/UDP 192.168.1.50:5060;branch=z9hG4bK-b92a3ef5cc37de1cd2c5a3beef75589d;rport
From: "poa" <sip:300@192.168.1.50;user=phone>;tag=18523
To: <sip:200@172.16.10.210;user=phone>;tag=d2057dfc98
Call-ID: 9e1eef98@pbx
CSeq: 12399 ACK
Max-Forwards: 70
Contact: <sip:123@192.168.1.50:5060;transport=udp>
P-Asserted-Identity: "vm" <sip:123@172.16.10.210>
Content-Length: 0

 

i have not found any document about connect two office through a vpn connection

 

thanks

Link to comment
Share on other sites

The PBX does not care if it is VPN, public Internet, private addresses or whatever. The key point is if addresses are routable and from the log above that seems to be the case (no problem).

 

In the example above, you say the PBX is on 192.168.1.60, but the packet is received from 192.168.1.50. Thats why the PBX cannot match the incoming call to a trunk. Simple typo?

 

 

Link to comment
Share on other sites

is not a typo error, you're right, the ip of the office2 is 192.168.1.50 i have configure the trunk with the wrong ip .

now i call the extension without problem but if i try to call a external numer form the exstension of office2 through the line of the office1 i give : 404 Not Found

 

could be a problem of the dial plan ??

 

DP office1

pref 70

trunk office2

Pattern 3xx

Replacement *

 

pref 100

trunk voip

Pattern *

Replacement *

 

this is the log :

 

[5] 2011/02/04 17:47:27:	SIP Rx udp:192.168.1.50:5060:
INVITE sip:348xxxxxxx@172.16.10.210;user=phone SIP/2.0
Via: SIP/2.0/UDP 192.168.1.50:5060;branch=z9hG4bK-30872cdc61a2b347876c6989f20f9f0f;rport
From: "poa" <sip:300@192.168.1.50;user=phone>;tag=56613
To: <sip:348xxxxxxx@172.16.10.210;user=phone>
Call-ID: 240994b8@pbx
CSeq: 7987 INVITE
Max-Forwards: 70
Contact: <sip:123@192.168.1.50:5060;transport=udp>
Supported: 100rel, replaces, norefersub
Allow-Events: refer
Allow: INVITE, ACK, CANCEL, BYE, REFER, PRACK, INFO, UPDATE
Accept: application/sdp
User-Agent: snom-PBX/2011-4.2.0.3981
P-Asserted-Identity: "vm" <sip:123@172.16.10.210>
Content-Type: application/sdp
Content-Length: 327

v=0
o=- 14816 14816 IN IP4 192.168.1.50
s=-
c=IN IP4 192.168.1.50
t=0 0
m=audio 50782 RTP/AVP 0 8 9 2 3 101
a=rtpmap:0 pcmu/8000
a=rtpmap:8 pcma/8000
a=rtpmap:9 g722/8000
a=rtpmap:2 g726-32/8000
a=rtpmap:3 gsm/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=rtcp-xr:rcvr-rtt=all voip-metrics
a=sendrecv
[5] 2011/02/04 17:47:27:	Identify trunk (IP address/port and domain match) 12
[5] 2011/02/04 17:47:27:	SIP Rx udp:192.168.1.50:5060:
INVITE sip:348xxxxxxx@172.16.10.210;user=phone SIP/2.0
Via: SIP/2.0/UDP 192.168.1.50:5060;branch=z9hG4bK-30872cdc61a2b347876c6989f20f9f0f;rport
From: "poa" <sip:300@192.168.1.50;user=phone>;tag=56613
To: <sip:348xxxxxxx@172.16.10.210;user=phone>
Call-ID: 240994b8@pbx
CSeq: 7987 INVITE
Max-Forwards: 70
Contact: <sip:123@192.168.1.50:5060;transport=udp>
Supported: 100rel, replaces, norefersub
Allow-Events: refer
Allow: INVITE, ACK, CANCEL, BYE, REFER, PRACK, INFO, UPDATE
Accept: application/sdp
User-Agent: snom-PBX/2011-4.2.0.3981
P-Asserted-Identity: "vm" <sip:123@172.16.10.210>
Content-Type: application/sdp
Content-Length: 327

v=0
o=- 14816 14816 IN IP4 192.168.1.50
s=-
c=IN IP4 192.168.1.50
t=0 0
m=audio 50782 RTP/AVP 0 8 9 2 3 101
a=rtpmap:0 pcmu/8000
a=rtpmap:8 pcma/8000
a=rtpmap:9 g722/8000
a=rtpmap:2 g726-32/8000
a=rtpmap:3 gsm/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=rtcp-xr:rcvr-rtt=all voip-metrics
a=sendrecv
[5] 2011/02/04 17:47:27:	SIP Tx udp:192.168.1.50:5060:
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 192.168.1.50:5060;branch=z9hG4bK-30872cdc61a2b347876c6989f20f9f0f;rport=5060
From: "poa" <sip:300@192.168.1.50;user=phone>;tag=56613
To: <sip:348xxxxxxx@172.16.10.210;user=phone>;tag=d661df1270
Call-ID: 240994b8@pbx
CSeq: 7987 INVITE
Content-Length: 0

[5] 2011/02/04 17:47:27:	Domain trunk pm@172.16.10.210 could not identify user for 348xxxxxxx
[5] 2011/02/04 17:47:27:	SIP Tx udp:192.168.1.50:5060:
SIP/2.0 404 Not Found
Via: SIP/2.0/UDP 192.168.1.50:5060;branch=z9hG4bK-30872cdc61a2b347876c6989f20f9f0f;rport=5060
From: "poa" <sip:300@192.168.1.50;user=phone>;tag=56613
To: <sip:348xxxxxxx@172.16.10.210;user=phone>;tag=d661df1270
Call-ID: 240994b8@pbx
CSeq: 7987 INVITE
Contact: <sip:123@172.16.10.210:5060;transport=udp>
Supported: 100rel, replaces, norefersub
Allow-Events: refer
Allow: INVITE, ACK, CANCEL, BYE, REFER, PRACK, INFO, UPDATE
Accept: application/sdp
User-Agent: snom-PBX/2011-4.2.0.3981
Content-Length: 0

[5] 2011/02/04 17:47:27:	SIP Rx udp:192.168.1.50:5060:
ACK sip:348xxxxxxx@172.16.10.210;user=phone SIP/2.0
Via: SIP/2.0/UDP 192.168.1.50:5060;branch=z9hG4bK-30872cdc61a2b347876c6989f20f9f0f;rport
From: "poa" <sip:300@192.168.1.50;user=phone>;tag=56613
To: <sip:348xxxxxxx@172.16.10.210;user=phone>;tag=d661df1270
Call-ID: 240994b8@pbx
CSeq: 7987 ACK
Max-Forwards: 70
Contact: <sip:123@192.168.1.50:5060;transport=udp>
P-Asserted-Identity: "vm" <sip:123@172.16.10.210>
Content-Length: 0

 

i can configure the sla or the blf of the remote extension ??

Link to comment
Share on other sites

Make sure that your 3xx series extensions do not interfere with 348xxxxxxx numbers. If you want to go to PSTN (not to the other office), then make sure you have the proper dial plan setup. You can either the outside numbers with 1, so that you dial 1348xxxxxxx and the dial plan can have a pattern with 1*.

 

Otherwise, you can have some complex pattern (regular expressions) for pattern matching to chose the right trunk.

http://kiwi.pbxnsip.com/index.php/Dial_Plan

Link to comment
Share on other sites

I do not know if it's correct but i solved by changing the configuration of the both trunk in this way :

Accept Redirect: yes

Assume that call comes from user: 203 for office1 and 303 for office2

 

the extension 203 and 303 are a dummy user, in this way i can call form the office1 through the pstn and voip line of the office2 and viceversa

 

now i should check with the blf of the snom320 in the office1 the status of the telephon in the office2, is it possible??? can i check also the sla ??

 

thanks

Link to comment
Share on other sites

now i should check with the blf of the snom320 in the office1 the status of the telephon in the office2, is it possible??? can i check also the sla ??

 

That would be a hack. You could set the snom 320 up in both offices (two identities) and use one identity just to monitor the status in the other domain.

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...