[OpenSIPS-Users] sipcapture segfaults when capturing on raw interface in all 2.x versions of opensips

Bogdan-Andrei Iancu bogdan at opensips.org
Thu May 10 13:24:51 EDT 2018


Hi Michael,

What is the exact OpenSIPs revision you have (do 'opensips -V') ?

Also, could you extract the backtrace from the corefile ?

Best regards,

Bogdan-Andrei Iancu

OpenSIPS Founder and Developer
   http://www.opensips-solutions.com
OpenSIPS Summit 2018
   http://www.opensips.org/events/Summit-2018Amsterdam

On 05/08/2018 01:22 AM, Michael Ulitskiy wrote:
> Hello,
>
> I'm trying to use opensips with sipcature module to collect sip messaging on a
> mirror port and feed it to homer database. Unfortunately it segfaults. I've
> tried to use all latest 2.x versions with the same result. 1.11.11 seems to
> work fine, but is missing necessary features. Since homer provides sample
> configs for opensips 2.2.x all below is for opensips-2.2.6.
>
> Here's excerpt from the log right before the crash:
>
> May  7 18:05:43 [10752] DBG:core:_parse_to: display={},
> ruri={sip:19179620875 at 66.114.x.y}
> May  7 18:05:43 [10752] CRITICAL:sipcapture:ip_addr2a: unknown address family
> 841889590
> May  7 18:05:43 [10752] CRITICAL:sipcapture:ip_addr2a: unknown address family
> 825112118
> May  7 18:05:43 [10752] DBG:sipcapture:w_sip_capture: src_ip: [67.2]
> May  7 18:05:43 [10752] DBG:sipcapture:w_sip_capture: dst_ip: [66.1]
> May  7 18:05:43 [10752] DBG:sipcapture:w_sip_capture: dst_port: [5060]
> May  7 18:05:43 [10752] DBG:sipcapture:w_sip_capture: src_port: [5060]
> May  7 18:05:43 [10750] DBG:core:handle_sigs: status = 139
> May  7 18:05:43 [10750] INFO:core:handle_sigs: child process 10752 exited by a
> signal 11
> May  7 18:05:43 [10750] INFO:core:handle_sigs: core was generated
> May  7 18:05:43 [10750] INFO:core:handle_sigs: terminating due to SIGCHLD
>
> As you can see opensips was unable to parse address family and source and
> destination ip. The capture is done on vlan interface - bond0.9. Can it be the
> reason?
>
> Here's is config:
>
> memlog=0
> debug_mode=1
> listen=udp:127.0.0.1:5060
> children=5
> dns=no
> mpath="/usr/local/opensips/lib/opensips/modules"  #path to modules
> db_default_url="postgres://user:password@localhost:5432/sipcapture"
>
> loadmodule "db_postgres.so"
> modparam("db_postgres", "exec_query_threshold", 100000)
> loadmodule "sipmsgops.so"
> loadmodule "sipcapture.so"
> modparam("sipcapture", "db_url",
> "postgres://user:password@localhost:5432/sipcapture")
> modparam("sipcapture", "table_name", "sip_capture")
> modparam("sipcapture", "hep_capture_on", 0)
> modparam("sipcapture", "raw_moni_capture_on", 1)
> modparam("sipcapture", "raw_interface", "bond0.990")
> modparam("sipcapture", "promiscious_on", 1)
> modparam("sipcapture", "raw_socket_listen", "10.0.0.1:5060-5160")
> modparam("sipcapture", "raw_moni_bpf_on", 1)
> modparam("sipcapture", "capture_on", 1)
>
> route {
>
>          if (!is_method("OPTIONS|REGISTER|NOTIFY|SUBSCRIBE")) {
>                  sip_capture();
>          }
>
> }
>   
> onreply_route {
>          if (!is_method("OPTIONS|REGISTER|NOTIFY|SUBSCRIBE")) {
>                  sip_capture();
>          }
> }
>
> I can provide core if somebody wants to look at it. Just not sure if this list
> would allow such a large attachment.
>
> Please let me know if you have any idea how to fix it.
> Thanks,
>
> Michael
>
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users




More information about the Users mailing list