#616 Opensips crashes when EXEC-Module is loaded

1.8.x
open-invalid
modules (454)
5
2013-03-07
2013-02-25
Christian Lahme
No

If you try to configure

loadmodule \"exec.so\"

you will get something similiar to this in your logs:

CRITICAL:core:receive_fd: EOF on 10
INFO:core:handle_sigs: child process 9969 exited by a signal 11
INFO:core:handle_sigs: core was generated
INFO:core:handle_sigs: terminating due to SIGCHLD

Discussion

  • modparam("exec", "async", 1) needs to be set ... -> SOLVED!

     
  • Razvan Crainea
    Razvan Crainea
    2013-02-25

    Hi, Christian!

    Can you tell me the OpenSIPS version you are using? Also, does it crash during startup or during message processing?

    Best regards,
    Răzvan

     
  • Hi Răzvan,

    if async is not set, it crashes in Version 1.8.2.

    BR

    Chris

     
  • and it crashes at startup ...

     
  • Hello,

    Could you please post here the 'bt full' output from the core file ?

    If you need help in properly generating a core file or extracting the backtrace from it, follow the steps described at http://www.opensips.org/Resources/DocsTsCrash

    Best Regards,
    Vlad

     
  • #0 exec_async_proc (rank=<value optimized out>) at exec.c:160
    pid = <value optimized out>
    status = 0
    cmd = <value optimized out>
    prev = <value optimized out>
    __FUNCTION__ = "exec_async_proc"
    #1 0x0000000000468a13 in start_module_procs () at sr_module.c:585
    m = 0x7fe378c13340
    n = <value optimized out>
    l = <value optimized out>
    x = <value optimized out>
    __FUNCTION__ = "start_module_procs"
    #2 0x000000000042a491 in main_loop (argc=<value optimized out>, argv=<value optimized out>) at main.c:818
    i = <value optimized out>
    pid = <value optimized out>
    si = 0x0
    startup_done = 0x0
    chd_rank = 0
    rc = <value optimized out>
    load_p = 0x0
    #3 main (argc=<value optimized out>, argv=<value optimized out>) at main.c:1541
    cfg_log_stderr = <value optimized out>
    cfg_stream = <value optimized out>
    c = <value optimized out>
    r = 0
    tmp = 0x7fffa49e2f79 ""
    tmp_len = <value optimized out>
    port = <value optimized out>
    proto = <value optimized out>
    options = 0x4ebf28 "f:cCm:M:b:l:n:N:rRvdDETSVhw:t:u:g:P:G:W:o:"
    ret = -1
    seed = 2443337210
    rfd = <value optimized out>
    __FUNCTION__ = "main"

     
  • Chris, this is really strange - the crash shows that an aux process (of the exec modules) was started (the exec_async_proc process). This process is intended to start only if async is enabled (which by default is disabled) .

    If you look in modules/exec/exec_mod.c file, the mod_init() function (line 120) : if "async" is not enabled, the exports.procs = 0 setting will take care and prevent the aux process to be started.

    Are you sure you do not have some patching on the exec module ?

    Regards,
    Bogdan

     
    • assigned_to: nobody --> bogdan_iancu
    • status: open --> open-invalid
     
  • Are you able to reproduce this on any other machine ? if so, it is possible to get access to such machine to investigate ?

    Regards,
    Bogdan

     
  • I will do a machine on saturday and send you all creds.