The customer is changing their digital trunk to an IP trunk. Currently, a digital trunk is in working. The carrier provides a modem with an IP address pointing to a SIP/Proxy server through which incoming and outgoing calls are routed. Currently, outgoing calls are working through a PJSIP trunk on port 5060. However, incoming calls are not working despite the incoming routing being fully configured with the carrier’s IDE.
I’ve made several changes to the trunk configuration, but for some reason the invite is permanently ignored by PBXAct.
The configuration is as follows: IPv4 Address: 10.195.161.77
IPv4 Subnet Mask: 255.255.224.0 IPv4
Default Gateway: 10.195.160.1
SIP/Proxy: 10.187.128.35
Header: 2297909860
DID: 9860
10 digits for outgoing calls 4 digits for incoming call
Probably being blocked by the Linux firewall on your FreePBX box. tcpdump captures before the inbound firewall, and is showing retransmissions, with no responses. You haven’t provided the Asterisk logs.
As @david55 said, because your box is responding to each INVITE packet with an ICMP Port unreachable. What is strange is that with default settings, Asterisk would be sending OPTIONS (qualify) requests to the trunk every minute, and the replies thereto would keep most firewalls open for at least a minute. If Asterisk is running in a VM, it’s also possible that the issue is with the firewall on the host, or the networking setup (if not bridged).
Also strange is that we see replies to REGISTER requests from extensions, but not the requests. Did you use a capture filter that is blocking them?
If you still have trouble and post another .pcap, capture for at least a minute so we can see qualify activity.
I really appreciate your answers.
I probably need to give more context to the problem.
It’s a physical server located on the client’s premises. The server has two network cards. One points to the customer network
172.1.1.2
and the second IP address
10.195.161.77
is connected directly to a modem provided by the carrier so we can connect to their trunk accross their equipment
In order to avoid any issues with firewall, I disabled the firewall and fail2ban. For now, all traffic can get in and get out without problems.
I am attaching the Asterisk log with a pcap capture of more than a minute. I made three calls to the number 2297909860
After spoke with carrier, they recommend use CHAN_SIP , something that I was able to made. Even they gave me some configuration examples, however we are having the same behavior.
outbound calls works but not inbound.
After testing I noticed that asteriks logs do not have anything about incomming call, thats mean that even invite are not abel to reach asterisk.
Trunks stastus seeems to be ok on asterisk CLI
I took a trace and after invite server respond port are not reachable on modem side.
The customer is changing their digital trunk to an IP trunk. Currently, a digital trunk is in working. The carrier provides a modem with an IP address pointing to a SIP/Proxy server through which incoming and outgoing calls are routed. Currently, outgoing calls are working through a CHAN_SIP trunk on port 5060. However, incoming calls are not working despite the incoming routing being fully configured with the carrier’s IDE.
I’ve made several changes to the trunk configuration, but for some reason the invite is permanently ignored by PBXAct.
It’s a physical server located on the client’s premises. The server has two network cards. One points to the customer network
172.1.1.2
and the second IP address
10.195.161.77
is connected directly to a modem provided by the carrier so we can connect to their trunk accross their equipment
In order to avoid any issues with firewall, I disabled the firewall and fail2ban. For now, all traffic can get in and get out without problems.
Carrier configuration is as follows:
IPv4 Address: 10.195.161.77
IPv4 Subnet Mask: 255.255.224.0 IPv4
Default Gateway: 10.195.160.1
SIP/Proxy: 10.187.128.35
Header: 2297909860
DID: 9860
10 digits for outgoing calls 4 digits for incoming call
After spoke with carrier, they recommend use CHAN_SIP , something that I was able to made. Even they gave me some configuration examples, however we are having the same behavior.
outbound calls works but not inbound.
After testing I noticed that asteriks logs do not have anything about incomming call, thats mean that even invite are not abel to reach asterisk.
Trunks stastus seeems to be ok on asterisk CLI
I took a trace and after invite server respond port are not reachable on modem side.
Thank you David, just quck question, why is showinbg ICMP protocol?
is asking about the way to communicate but their equipment is not responding from the port 5060?
if you can give me some quck explination will be gralty to understand the information to solve the issue
ICMP is Internet Control Message Protocol, and is used, amongst other things, to signal that the destination address is unreachable. That can literally be the case, if no process is listening on the port, but firewalls also use it to confuse an attacker as to whether they were blocked, or the service they are attacking does not exist.
You are talking about incoming calls, so this ICMP is coming from your machine. Most likely that is because the Linux firewall is blocking the traffic, but could also be because you are not actually listening on port 5060.
Firewall and fail2ban are disabled, so, seems that my PBX does not have open port 5060 to receive the call?
in my trunk configuration that I am sharing have the port 5060 and even the trunk is ok.
How can I verify that my PBX is not receiving call to the specifed port?
From a Linux shell prompt (e.g. accessed using ssh) run “netstat -lupn” and look for references to port 5060.
If you find one, from a root shell, run “iptables -L”, to confirm the firewall state.
You say that PJSP is on port 5060, but you have provided a configuration for chan_sip, not for chan_pjsip. That can’t also be on 5060, unless both are bound to specific, different, interfaces..
This is not a complete configuration. I suspect that it is actually bound to 5160, which is what FreePBX does if both drivers are enabled. You should use just chan_pjsip. The 5060 in your configuration is the remote port number.
thanks for your answer.
Today I switched ports on Asterisk configuration, setting default chan_sip to port 5060 and moving PJSIP to 5160. Inbound calls started to work properly.
So far I know CHANSIP is not supported anymore and not really sure why TOTALPLAY, Mexican carrier are not able to support on their configuration PJSIP
Thanks for all support