SBC: "Connection is terminated by peer"

Discussion in '3CX Phone System - General' started by mamo, Sep 27, 2016.

Thread Status:
Not open for further replies.
  1. mamo

    Joined:
    Aug 22, 2016
    Messages:
    35
    Likes Received:
    1
    I am trying to set up an SBC on a raspberry pi (Raspberry Pi 2 Model B, fresh installation with NOOBS 1.9.2 installer).
    At first, I found errors in the log file, stating problems with the DNS server. I did some research and found this very helpful post. After enabling wait for network at boot, the DNS errors disappeared. However, now I get a new error, I have no Idea how to solve. It says: "Connection is terminated by peer".

    On the server-side I am unable to to find any error. I double-checked my network settings and everything seems to be as it should (according to the admin manual). Also the Android-App (which to my knowledge should use the same ports) works flawless from the remote location, in which I am trying to set up the SBC. Probably this could be counted as proof that port forwarding and firewall is configured correctly. The event log in the 3CX management console does not show anything at all that is related to the SBC.

    Here is the complete log from the SBC:
    Code:
     INFO | 20160927-011430.421 | 3CXTunnel | RESIP:TRANSACTION | 652 | 1995902976 | TuSelector.cxx:84 | Stats message
     WARNING | 20160927-011430.422 | 3CXTunnel | RESIP:STATS | 652 | 1995902976 | StatisticsMessage.cxx:98 | RESIP:TRANSACTION#012TU summary: 0 TRANSPORT 0 TRANSACTION 0 CLIENTTX 0 SERVERTX 0 TIMERS 0#012Transaction summary: reqi 0 reqo 0 rspi 0 rspo 0#012Details: INVi 0/S0/F0 INVo 0/S0/F0 ACKi 0 ACKo 0 BYEi 0/S0/F0 BYEo 0/S0/F0 CANi 0/S0/F0 CANo 0/S0/F0 MSGi 0/S0/F0 MSGo 0/S0/F0 OPTi 0/S0/F0 OPTo 0/S0/F0 REGi 0/S0/F0 REGo 0/S0/F0 PUBi 0/S0/F0 PUBo 0/S0/F0 SUBi 0/S0/F0 SUBo 0/S0/F0 NOTi 0/S0/F0 NOTo 0/S0/F0 REFi 0/S0/F0 REFo 0/S0/F0 INFi 0/S0/F0 INFo 0/S0/F0 PRAi 0/S0/F0 PRAo 0/S0/F0 SERi 0/S0/F0 SERo 0/S0/F0 UPDi 0/S0/F0 UPDo 0/S0/F0#012Retransmissions: INVx 0 finx 0 nonx 0 BYEx 0 CANx 0 MSGx 0 OPTx 0 REGx 0 PUBx 0 SUBx 0 NOTx 0 REFx 0 INFx 0 PRAx 0 SERx 0 UPDx 0
     NOTICE | 20160927-011439.432 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:388 | === Statistics:#012  Keep-alives: recv 0, sent 1#012  Transfers:   recv last 16021 ms ago,#011total 0 bytes#012               sent last 16065 ms ago,#011total 0 bytes#012===
     DEBUG | 20160927-011454.449 | 3CXTunnel | RESIP:TRANSPORT | 652 | 1995902976 | InternalTransport.cxx:99 | Creating fd=19 V4/TCP
     DEBUG | 20160927-011454.449 | 3CXTunnel | RESIP:TRANSPORT | 652 | 1995902976 | InternalTransport.cxx:107 | Binding to 0.0.0.0
     NOTICE | 20160927-011454.450 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:99 | TCP socket (19) is created and bound to [ V4 0.0.0.0:46506 UNKNOWN_TRANSPORT target domain=unspecified mFlowKey=0 ]#015#012   MAC=B8:27:EB:20:90:22; MAC hash = 3378044988
     NOTICE | 20160927-011454.450 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:136 | Trying to resolve tunnel connection to destination's FQDN replaced.3cx.de
     INFO | 20160927-011454.450 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:7 | [DNS] Resolving SRV records for _3cxtunnel._tcp.replaced.3cx.de
     STACK | 20160927-011454.450 | 3CXTunnel | RESIP:DNS | 652 | 1995902976 | dns/DnsStub.cxx:454 | DNS query of:_3cxtunnel._tcp.replaced.3cx.de SRV
     DEBUG | 20160927-011454.450 | 3CXTunnel | RESIP:DNS | 652 | 1995902976 | dns/DnsStub.cxx:67 | _3cxtunnel._tcp.replaced.3cx.de (SRV) --> p=10 w=0 replaced.3cx.de:5090
     DEBUG | 20160927-011454.450 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:138 | [DNS] Got DNS SRV result for _3cxtunnel._tcp.replaced.3cx.de: status = 0
     INFO | 20160927-011454.451 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:58 | [DNS} Got SRV record: target replaced.3cx.de:5090; priority=10, weight=0
     INFO | 20160927-011454.451 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:89 | [DNS] Resolving IP address(es) for replaced.3cx.de
     STACK | 20160927-011454.451 | 3CXTunnel | RESIP:DNS | 652 | 1995902976 | dns/DnsStub.cxx:454 | DNS query of:replaced.3cx.de A
     DEBUG | 20160927-011454.451 | 3CXTunnel | RESIP:DNS | 652 | 1995902976 | dns/DnsStub.cxx:49 | replaced.3cx.de(A)--> 54.192.224.172
     DEBUG | 20160927-011454.452 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:149 | [DNS] Got DNS A result for replaced.3cx.de: status = 0
     INFO | 20160927-011454.455 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:123 | [DNS] Resolved host name replaced.3cx.de to [54.192.224.172]
     NOTICE | 20160927-011454.458 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:231 | Making TCP connection to [ V4 54.192.224.172:5090 TCP target domain=unspecified mFlowKey=0 ]
     STACK | 20160927-011454.461 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:329 | FdSet timeout = 999
     DEBUG | 20160927-011454.565 | 3CXTunnel | TUNL | 652 | 1995902976 | security.cpp:995 | Ready to send, send q size = 0
     NOTICE | 20160927-011454.566 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:397 | Tunnel connection to [ V4 54.192.224.172:5090 TCP target domain=unspecified mFlowKey=0 ] is accepted
     ALERT | 20160927-011454.566 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:448 | Sending first packet from [ V4 0.0.0.0:46506 UNKNOWN_TRANSPORT target domain=unspecified mFlowKey=0 ] to [ V4 54.192.224.172:5090 TCP target domain=unspecified mFlowKey=0 ]
     DEBUG | 20160927-011454.586 | 3CXTunnel | TUNL | 652 | 1995902976 | security.cpp:566 | Creating SSL BIO on socket 19
     NOTICE | 20160927-011454.587 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:505 | Sending keep-alive. Stats: KA sent: 1, KA recv: 0
     STACK | 20160927-011454.587 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:329 | FdSet timeout = 1000
     INFO | 20160927-011454.627 | 3CXTunnel | TUNL | 652 | 1995902976 | security.cpp:1218 | Keep-alive received
     STACK | 20160927-011454.628 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:329 | FdSet timeout = 959
     WARNING | 20160927-011454.629 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:419 | Tunnel connection to [ V4 54.192.224.172:5090 TCP target domain=unspecified mFlowKey=0 ] is disconnected; error: Connection is terminated by peer - while begin to read a packet from tunnel
     ERR | 20160927-011454.629 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:258 | Bridge [3CXh SBC] failure 'Connection is terminated by peer - while begin to read a packet from tunnel' on TCP connection: TunnelTcp::process
     NOTICE | 20160927-011454.630 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:388 | === Statistics:#012  Keep-alives: recv 1, sent 1#012  Transfers:   recv last 2 ms ago,#011total 8 bytes#012               sent last 42 ms ago,#011total 63 bytes#012===
     WARNING | 20160927-011454.630 | 3CXTunnel | TUNL | 652 | 1995902976 | Bridge.cpp:225 | Tunnel disconnected. Terminating all active calls.
     NOTICE | 20160927-011511.648 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:388 | === Statistics:#012  Keep-alives: recv 0, sent 1#012  Transfers:   recv last 17021 ms ago,#011total 0 bytes#012               sent last 17061 ms ago,#011total 0 bytes#012===
     DEBUG | 20160927-011525.665 | 3CXTunnel | RESIP:TRANSPORT | 652 | 1995902976 | InternalTransport.cxx:99 | Creating fd=19 V4/TCP
     DEBUG | 20160927-011525.665 | 3CXTunnel | RESIP:TRANSPORT | 652 | 1995902976 | InternalTransport.cxx:107 | Binding to 0.0.0.0
     NOTICE | 20160927-011525.665 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:99 | TCP socket (19) is created and bound to [ V4 0.0.0.0:44653 UNKNOWN_TRANSPORT target domain=unspecified mFlowKey=0 ]#015#012   MAC=B8:27:EB:20:90:22; MAC hash = 3378044988
     NOTICE | 20160927-011525.666 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:136 | Trying to resolve tunnel connection to destination's FQDN replaced.3cx.de
     INFO | 20160927-011525.666 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:7 | [DNS] Resolving SRV records for _3cxtunnel._tcp.replaced.3cx.de
     STACK | 20160927-011525.666 | 3CXTunnel | RESIP:DNS | 652 | 1995902976 | dns/DnsStub.cxx:454 | DNS query of:_3cxtunnel._tcp.replaced.3cx.de SRV
     DEBUG | 20160927-011525.666 | 3CXTunnel | RESIP:DNS | 652 | 1995902976 | dns/DnsStub.cxx:67 | _3cxtunnel._tcp.replaced.3cx.de (SRV) --> p=10 w=0 replaced.3cx.de:5090
     DEBUG | 20160927-011525.666 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:138 | [DNS] Got DNS SRV result for _3cxtunnel._tcp.replaced.3cx.de: status = 0
     INFO | 20160927-011525.666 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:58 | [DNS} Got SRV record: target replaced.3cx.de:5090; priority=10, weight=0
     INFO | 20160927-011525.666 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:89 | [DNS] Resolving IP address(es) for replaced.3cx.de
     STACK | 20160927-011525.667 | 3CXTunnel | RESIP:DNS | 652 | 1995902976 | dns/DnsStub.cxx:454 | DNS query of:replaced.3cx.de A
     DEBUG | 20160927-011525.667 | 3CXTunnel | RESIP:DNS | 652 | 1995902976 | dns/DnsStub.cxx:49 | replaced.3cx.de(A)--> 54.192.224.172
     DEBUG | 20160927-011525.668 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:149 | [DNS] Got DNS A result for replaced.3cx.de: status = 0
     INFO | 20160927-011525.670 | 3CXTunnel | TUNL | 652 | 1995902976 | Dns.cpp:123 | [DNS] Resolved host name replaced.3cx.de to [54.192.224.172]
     NOTICE | 20160927-011525.672 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:231 | Making TCP connection to [ V4 54.192.224.172:5090 TCP target domain=unspecified mFlowKey=0 ]
     STACK | 20160927-011525.674 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:329 | FdSet timeout = 1000
     DEBUG | 20160927-011525.789 | 3CXTunnel | TUNL | 652 | 1995902976 | security.cpp:995 | Ready to send, send q size = 0
     NOTICE | 20160927-011525.790 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:397 | Tunnel connection to [ V4 54.192.224.172:5090 TCP target domain=unspecified mFlowKey=0 ] is accepted
     ALERT | 20160927-011525.790 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:448 | Sending first packet from [ V4 0.0.0.0:44653 UNKNOWN_TRANSPORT target domain=unspecified mFlowKey=0 ] to [ V4 54.192.224.172:5090 TCP target domain=unspecified mFlowKey=0 ]
     DEBUG | 20160927-011525.804 | 3CXTunnel | TUNL | 652 | 1995902976 | security.cpp:566 | Creating SSL BIO on socket 19
     NOTICE | 20160927-011525.805 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:505 | Sending keep-alive. Stats: KA sent: 1, KA recv: 0
     STACK | 20160927-011525.805 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:329 | FdSet timeout = 1000
     INFO | 20160927-011525.854 | 3CXTunnel | TUNL | 652 | 1995902976 | security.cpp:1218 | Keep-alive received
     STACK | 20160927-011525.854 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:329 | FdSet timeout = 951
     WARNING | 20160927-011525.856 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:419 | Tunnel connection to [ V4 54.192.224.172:5090 TCP target domain=unspecified mFlowKey=0 ] is disconnected; error: Connection is terminated by peer - while begin to read a packet from tunnel
     ERR | 20160927-011525.856 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:258 | Bridge [3CXh SBC] failure 'Connection is terminated by peer - while begin to read a packet from tunnel' on TCP connection: TunnelTcp::process
     NOTICE | 20160927-011525.857 | 3CXTunnel | TUNL | 652 | 1995902976 | TunnelTcp.cpp:388 | === Statistics:#012  Keep-alives: recv 1, sent 1#012  Transfers:   recv last 2 ms ago,#011total 8 bytes#012               sent last 51 ms ago,#011total 63 bytes#012===
     WARNING | 20160927-011525.857 | 3CXTunnel | TUNL | 652 | 1995902976 | Bridge.cpp:225 | Tunnel disconnected. Terminating all active calls.
    *Domain and IP changed for privacy reason.
     
  2. mamo

    Joined:
    Aug 22, 2016
    Messages:
    35
    Likes Received:
    1
    Update: I "solved" the problem by using an old version of Raspbian (http://downloads.raspberrypi.org/NOOBS/ ... 015-05-12/).
    Of course, having to use an outdated OS, it is far from perfect, but well... at least it works, which is the most important thing right now. Hoping to see an updated version with better compatibility in the near future.
     
Thread Status:
Not open for further replies.