Crash at taskprocessor.c:1171

Hi all,

I have debian 10.5 server with asterisk version 16.13.0. I’m using PJSIP .
Occasionally the asterisk crashes, without any warning or error in full file, just segfault in syslog. It’s seem that problem is taskprocessor:
“taskprocessor_push (tps=0x7fd238206a20, t=0x7fd284000cb0) at taskprocessor.c:1171”
Have you guys any idea what to do, to avoid this crashes?
Thank you for any possible suggest

core-thread1.txt
$1 = {si_signo = 11, si_errno = 0, si_code = 1, _sifields = {_pad = {0 <repeats 28 times>}, _kill = {si_pid = 0, si_uid = 0}, _timer = {si_tid = 0, si_overrun = 0, si_sigval = {sival_int = 0, sival_ptr = 0x0}}, _rt = {si_pid = 0, si_uid = 0, si_sigval = {sival_int = 0, sival_ptr = 0x0}}, _sigchld = {si_pid = 0, si_uid = 0, si_status = 0, si_utime = 0, si_stime = 0}, _sigfault = {si_addr = 0x0, _addr_lsb = 0, _addr_bnd = {_lower = 0x0, _upper = 0x0}}, _sigpoll = {si_band = 0, si_fd = 0}}}
Signal Stop Print Pass to program Description
SIGSEGV Yes Yes Yes Segmentation fault

Thread 1 (Thread 0x7fd2c4279700 (LWP 695)):
#0 0x00005600081d2821 in taskprocessor_push (tps=0x7fd238206a20, t=0x7fd284000cb0) at taskprocessor.c:1171
previous_size = 1
was_empty = 0
PRETTY_FUNCTION = “taskprocessor_push”
#1 0x00005600081d287a in ast_taskprocessor_push (tps=0x7fd238206a20, task_exe=0x7fd39fb8465a , datap=0x7fd284011ce0) at taskprocessor.c:1177
#2 0x00007fd39fd61433 in ast_sip_push_task (serializer=0x7fd238206a20, sip_task=0x7fd39fb8465a , task_data=0x7fd284011ce0) at res_pjsip.c:4606
#3 0x00007fd39fb84823 in chan_pjsip_hangup (ast=0x7fd284010d60) at chan_pjsip.c:2566
channel = 0x7fd2840073e0
cause = 486
h_data = 0x7fd284011ce0
PRETTY_FUNCTION = “chan_pjsip_hangup”
#4 0x00005600080aa909 in ast_hangup (chan=0x7fd284010d60) at channel.c:2628
PRETTY_FUNCTION = “ast_hangup”
#5 0x00007fd3e8503594 in wait_for_answer (in=0x7fd2381913f0, out_chans=0x7fd2c42754d0, to=0x7fd2c42754cc, peerflags=0x7fd2c4275838, opt_args=0x7fd2c4274d10, pa=0x7fd2c4274df0, num_in=0x7fd2c42754b0, result=0x7fd2c4274dec, dtmf_progress=0x0, ignore_cc=1, forced_clid=0x7fd2c4274bc0, stored_clid=0x7fd2c4274b70) at app_dial.c:1380
f = 0x0
c = 0x7fd284010d60
o = 0x7fd284022f30
pos = 2
numlines = 1
winner = 0x7fd284010d60
watchers = {0x7fd2381913f0, 0x7fd284010d60, 0x73, 0x7fd3e850e6bf, 0x0, 0x7fd3e850e6c9, 0x0 <repeats 13 times>, 0x3000000028, 0x7fd2c4274430, 0x7fd2c4274370, 0x0 <repeats 49 times>, 0x7fd3eb83b8e6 <__strftime_internal+2262>, 0x0, 0x2, 0x7fd2c4273f20, 0x7fd3eb937b40 <_nl_C_LC_TIME>, 0x7fd2c4273d17, 0x0, 0xf3, 0x0, 0xa00000000, 0x2, 0x0, 0x0, 0x0, 0x0, 0x3100000000000000, 0xc123bd85f7253f00, 0x7fd2c4273bb0, 0x7fd2c4273bb0, 0x104, 0x7fd3d9339790, 0x7fd2c4273d68, 0x5600083454c0 , 0x9, 0x5, 0x383300000007, 0xc123bd85f7253f00, 0x7fd20000003e, 0x7fd284006fb7, 0x7fd2c4273e17, 0x100, 0x7fd3eb93b560 <_nl_global_locale>, 0xf, 0x7fd2c4273e17, 0x7fd3eb83b6ea <__strftime_internal+1754>, 0x0, 0x0, 0x7fd2c4273f20, 0x7fd3eb937b40 <_nl_C_LC_TIME>, 0x7fd2c4273d17, 0x0, 0xf9, 0x1a6c0, 0xaeb93f6f0, 0x7fd3eb900305, 0x8, 0x7fd3eb8041a2 <__libc_calloc+130>, 0x7fd3d93390e3, 0x7fd2c4273cc0, 0x1, 0x7fd284022802, 0x7fd2386a6e72, 0x56000806784e <__ast_repl_calloc+46>, 0x127500, 0x5600082aa590 <PRETTY_FUNCTION.9463>, 0x99700000001, 0x5600082aa2d3, 0x9, 0xc123bd85f7253f00, 0x3531c4273d20, 0x7fd3d93390e3, 0x7fd2c4273d20, 0x7fd3eb83b8e6 <__strftime_internal+2262>, 0x7fd284022802, 0x2, 0x7fd2c4274110, 0x7fd3eb937b40 <_nl_C_LC_TIME>, 0x7fd2c4273f07, 0x0, 0xf3, 0x7fd284006fb0, 0xac4273da0, 0x560000000002, 0x6001629e, 0x0, 0x7fd2c4273f20, 0x56000833ca28 <dateformat+8>, 0x100, 0xc123bd85f7253f00, 0x7fd2c4273da0, 0x7fd2c4273da0, 0x104, 0x7fd3e850e6bf, 0x7fd2c4273f58, 0x5600083454c0 , 0x9, 0x7fd3eb7f77a0 <_IO_vsnprintf+144>, 0x3833fbad8001, 0xc123bd85f7253f00, 0x7fd284029ed8, 0x7fd284006797, 0x7fd2c4274007, 0x100, 0x7fd3eb93b560 <_nl_global_locale>, 0xf, 0x7fd2c4274007, 0x7fd3eb83b6ea <__strftime_internal+1754>, 0x0, 0x0, 0x7fd2c4274110, 0x7fd3eb937b40 <_nl_C_LC_TIME>, 0x7fd2c4273f07, 0x0, 0xf9, 0x1a6c0, 0xaeb93f6f0, 0x7fd3eb900305, 0x8, 0x7fd3eb8041a2 <__libc_calloc+130>, 0x7fd2381916a8, 0x7fd2c4273eb0, 0x5600083454c0 , 0x7fd2840167b9, 0x7fd2386a6e72, 0x56000806784e <__ast_repl_calloc+46>, 0x127500, 0x5600082aa590 <PRETTY_FUNCTION.9463>, 0x99700000001, 0x5600082aa2d3, 0x9, 0xc123bd85f7253f00, 0x3531c4273f10, 0x7fd2381916a8, 0x7fd2c4273f10, 0x5600083454c0 , 0x7fd2840167b9, 0x7fd2386a6e72, 0x5600083454c0 , 0x5600080678c8 <__ast_free+35>, 0x5600082aa590 <PRETTY_FUNCTION.9463>, 0x9d8eb83d2c6, 0x5600082aa2d3, 0x7fd284006790, 0x7fd2c4273f90, 0x5600081c91a4 <ast_strftime_locale+658>, 0x6001629e, 0x0, 0x7fd2c4274110, 0x56000833ca28 <dateformat+8>, 0x100, 0x7fd2c4274000, 0xf09e20bc8, 0x57081c5f83, 0x5800000058, 0x5600082aa483, 0x5600082c06f0 <PRETTY_FUNCTION.16038>, 0x67484006798, 0x5600082bef61, 0xf, 0x7fd284012ae8, 0x7fd284012b18, 0x5600082aa902 <__ast_string_field_empty_buffer+2>, 0x5600081e85f7 <ast_get_tid+30>, 0x7fd284012bb8, 0x2b70000000f, 0x7fd2c4274260, 0x560008239e72 <format_log_message_ap+2694>, 0x7fd200000657, 0x5600082c06f0 <PRETTY_FUNCTION.16038>, 0x7fd3e850ed70 <PRETTY_FUNCTION.19033>, 0xadb0000d9a2, 0x7fd3e850d8a0, 0x500000003, 0x31203531206e614a, 0x38333a38333a30, 0x48, 0x7fd284000020, 0x20, 0x1a6c0, 0x7fd3eb93f6f0 <__libc_multiple_threads>, 0x560008124bb0 <__ast_pthread_mutex_unlock+39>…}
num = {chan = 0x7fd2381913f0, busy = 0, congestion = 0, nochan = 0}
prestart = 0
orig = 60000
peer = 0x0
outgoing = 0x7fd284022f30
single = 1
caller_entertained = 0
featurecode = 0x7fd2c4273770
cc_recall_core_id = -1
is_cc_recall = 0
cc_frame_received = 0
num_ringing = 0
sent_ring = 0
sent_progress = 1
start = {tv_sec = 1610703518, tv_usec = 448153}
PRETTY_FUNCTION = “wait_for_answer”
#6 0x00007fd3e8509cf8 in dial_exec_full (chan=0x7fd2381913f0, data=0x7fd2c4275a20 “PJSIP/393703712919@kam4B,60,b(SSWHandler^headerchange^1(91.208.225.226^91.208.225.228^204.14.245.5:5060^16746^390662286184^))IL(18000000)”, peerflags=0x7fd2c4275838, continue_exec=0x0) at app_dial.c:2837
res = 0
rest = 0x0
cur = 0x0
out_chans = {first = 0x7fd284022f30, last = 0x7fd284022f30}
outgoing = 0x7fd284022f30
tmp = 0x0
peer = 0x22d0a664c38
to = 42277
num = {chan = 0x7fd2381913f0, busy = 0, congestion = 0, nochan = 0}
cause = 0
config = {features_caller = {flags = 0}, features_callee = {flags = 0}, start_time = {tv_sec = 0, tv_usec = 0}, nexteventts = {tv_sec = 0, tv_usec = 0}, feature_start_time = {tv_sec = 0, tv_usec = 0}, feature_timer = 0, timelimit = 0, play_warning = 0, warning_freq = 0, warning_sound = 0x7fd284005b50 “timeleft”, end_sound = 0x0, start_sound = 0x0, flags = 0, end_bridge_callback = 0x0, end_bridge_callback_data = 0x0, end_bridge_callback_data_fixup = 0x0}
calldurationlimit = {tv_sec = 18000, tv_usec = 0}
dtmfcalled = 0x0
dtmfcalling = 0x0
dtmf_progress = 0x0
pa = {sentringing = 0, privdb_val = 0, privcid = ‘000’ <repeats 255 times>, privintro = ‘000’ <repeats 1023 times>, status = “NOANSWER000GS”, ‘000’ <repeats 244 times>}
sentringing = 0
moh = 0
outbound_group = 0x0
result = 0
parse = 0x7fd2c4274480 “PJSIP”
opermode = 0
delprivintro = 0
args = {argc = 3, {argv = {0x7fd2c4274480 “PJSIP”, 0x7fd2c4274499 “60”, 0x7fd2c427449c “b(SSWHandler,headerchange,1(91.208.225.226,91.208.225.228,204.14.245.5:5060,16746,390662286184,)”, 0x0}, {peers = 0x7fd2c4274480 “PJSIP”, timeout = 0x7fd2c4274499 “60”, options = 0x7fd2c427449c “b(SSWHandler,headerchange,1(91.208.225.226,91.208.225.228,204.14.245.5:5060,16746,390662286184,)”, url = 0x0}}}
opts = {flags = 2199023272448}
opt_args = {0x0, 0x560008297344 “in new stack”, 0x7fd200000000 " “, 0x7fd2c4274500 “18000000”, 0x0, 0x7fd3eb936760 <_IO_helper_jumps> “”, 0x0, 0x56000829731b “%s@%s:%d] %s%s%s(”%s%s%s”, “%s%s%s”) %sn", 0x73 <error: Cannot access memory at address 0x73>, 0x560008297310 “Executing [%s@%s:%d] %s%s%s(”%s%s%s", “%s%s%s”) %sn", 0x0, 0x560008297343 “”, 0x0, 0x0, 0x0, 0x0, 0x0, 0x7fd2c427449e “SSWHandler,headerchange,1(91.208.225.226,91.208.225.228,204.14.245.5:5060,16746,390662286184,)”, 0x0, 0x0}
fulldial = 0
num_dialed = 1
ignore_cc = 1
device_name = “PJSIP/kam4B000060060060061b50d”, ‘000’ <repeats 29 times>, “N’304322177000000377377377377377377377377000000000000000000000000r000000000000000000”
forced_clid_name = “001000000000000000000000002”, ‘000’ <repeats 15 times>, “060R’304322177000000 R’304322177000000003001000000000000000000350S’304322177000000Bs)b000V000000240o223353323177000000022361|353323177000”
stored_clid_name = ‘000’ <repeats 16 times>, “060R’304322177000000350v177353323177000000000000000000000000000000Cs)b000V000000hr000000000000000000`g223353323177000000060R’304322177000000210310177353323177000”
force_forwards_only = 0
forced_clid = {name = {str = 0x0, char_set = 1, presentation = 0, valid = 0 ‘000’}, number = {str = 0x0, plan = 0, presentation = 1, valid = 0 ‘000’}, subaddress = {str = 0x0, type = 0, odd_even_indicator = 0 ‘000’, valid = 0 ‘000’}, tag = 0x0}
stored_clid = {name = {str = 0x0, char_set = 1, presentation = 0, valid = 0 ‘000’}, number = {str = 0x7fd2c4274460 “6666#393703712919”, plan = 0, presentation = 0, valid = 1 ‘001’}, subaddress = {str = 0x0, type = 0, odd_even_indicator = 0 ‘000’, valid = 0 ‘000’}, tag = 0x0}
caller = {id = {name = {str = 0x0, char_set = 1, presentation = 0, valid = 0 ‘000’}, number = {str = 0x7fd2c4274460 “6666#393703712919”, plan = 0, presentation = 0, valid = 1 ‘001’}, subaddress = {str = 0x0, type = 0, odd_even_indicator = 0 ‘000’, valid = 0 ‘000’}, tag = 0x0}, ani = {name = {str = 0x0, char_set = 1, presentation = 0, valid = 0 ‘000’}, number = {str = 0x0, plan = 0, presentation = 0, valid = 0 ‘000’}, subaddress = {str = 0x0, type = 0, odd_even_indicator = 0 ‘000’, valid = 0 ‘000’}, tag = 0x0}, priv = {name = {str = 0x0, char_set = 1, presentation = 0, valid = 0 ‘000’}, number = {str = 0x0, plan = 0, presentation = 0, valid = 0 ‘000’}, subaddress = {str = 0x0, type = 0, odd_even_indicator = 0 ‘000’, valid = 0 ‘000’}, tag = 0x0}, ani2 = 0}
max_forwards = 20
PRETTY_FUNCTION = “dial_exec_full”
#7 0x00007fd3e850c3ba in dial_exec (chan=0x7fd2381913f0, data=0x7fd2c4275a20 “PJSIP/393703712919@kam4B,60,b(SSWHandler^headerchange^1(91.208.225.226^91.208.225.228^204.14.245.5:5060^16746^390662286184^))IL(18000000)”) at app_dial.c:3323
peerflags = {flags = 0}
#8 0x0000560008156d56 in pbx_exec (c=0x7fd2381913f0, app=0x56000a664bc0, data=0x7fd2c4275a20 “PJSIP/393703712919@kam4B,60,b(SSWHandler^headerchange^1(91.208.225.226^91.208.225.228^204.14.245.5:5060^16746^390662286184^))IL(18000000)”) at pbx_app.c:492
res = 1
u = 0x7fd284015b20
saved_c_appl = 0x0
saved_c_data = 0x0
PRETTY_FUNCTION = “pbx_exec”
#9 0x0000560008141a38 in pbx_extension_helper (c=0x7fd2381913f0, con=0x0, context=0x7fd238191db0 “from-proxy”, exten=0x7fd238191e00 “6666#393703712919”, priority=37, label=0x0, callerid=0x7fd23810c010 “390662286184”, action=E_SPAWN, found=0x7fd2c4278ccc, combined_find_spawn=1) at pbx.c:2947
e = 0x56000a4e1750
app = 0x56000a664bc0
substitute = 0x7fd2c4275920 “PJSIP/{EXTEN:{TPFL}}@{SSWPeer},60,b(SSWHandler^headerchange^1({X-ACQ-FromProxy}^{X-ACQ-FromGw}^{X-ACQ-FromSIP}^{AccId}^{FPAI}^${PAIPrivacy}))IL(18000000)”
q = {incstack = {0x0 <repeats 512 times>}, stacklen = 0, status = 5, swo = 0x0, data = 0x0, foundcontext = 0x7fd238191db0 “from-proxy”}
passdata = “PJSIP/393703712919@kam4B,60,b(SSWHandler^headerchange^1(91.208.225.226^91.208.225.228^204.14.245.5:5060^16746^390662286184^))IL(18000000)000060)000060)”, ‘000’ <repeats 5433 times>…
matching_action = 0
PRETTY_FUNCTION = “pbx_extension_helper”
#10 0x0000560008145bc7 in ast_spawn_extension (c=0x7fd2381913f0, context=0x7fd238191db0 “from-proxy”, exten=0x7fd238191e00 “6666#393703712919”, priority=37, callerid=0x7fd23810c010 “390662286184”, found=0x7fd2c4278ccc, combined_find_spawn=1) at pbx.c:4206
#11 0x00005600081468df in __ast_pbx_run (c=0x7fd2381913f0, args=0x0) at pbx.c:4380
digit = 0
invalid = 0
timeout = 0
dst_exten = “000^Dt322177000000034ew353323177”, ‘000’ <repeats 18 times>, “210215’304322177000000220215’304322177000000000000000000000000000000230215’304322177”, ‘000’ <repeats 18 times>, “300215’304322177”, ‘000’ <repeats 42 times>, “240215’304322177000000250215’304322177000000260215’304322177000000270215’304322177000000ȍ’304322177000000000000000000000000000000 000000000000000000000240260312353323177”, ‘000’ <repeats 26 times>…
pos = 0
found = 1
res = 0
autoloopflag = 0
error = 0
pbx = 0x7fd28400d950
callid = 0
PRETTY_FUNCTION = “__ast_pbx_run”
#12 0x000056000814814e in pbx_thread (data=0x7fd2381913f0) at pbx.c:4704
c = 0x7fd2381913f0
#13 0x00005600081e5a0a in dummy_start (data=0x7fd23800b7b0) at utils.c:1249
__cancel_buf = {__cancel_jmp_buf = {{__cancel_jmp_buf = {0, -5662792260626748583, 140548127856558, 140548127856559, 140543210788608, 140541870497360, -5662792260668691623, -2104271729799402663}, __mask_was_saved = 0}}, __pad = {0x7fd2c4278ed0, 0x0, 0xc123bd85f7253f00, 0x7fd3ebcb6368 <__pthread_keys+8>}}
__cancel_routine = 0x56000805d560 <ast_unregister_thread>
__cancel_arg = 0x7fd2c4279700
__not_first_call = 0
ret = 0x7fd274445e50
a = {start_routine = 0x560008148129 <pbx_thread>, data = 0x7fd2381913f0, name = 0x7fd238076d10 “pbx_thread”, ’ ’ <repeats 11 times>, “started at [ 4730] pbx.c ast_pbx_start()”}
PRETTY_FUNCTION = “dummy_start”
#14 0x00007fd3ebca1fa3 in start_thread (arg=) at pthread_create.c:486
ret =
pd =
now =
unwind_buf = {cancel_jmp_buf = {{jmp_buf = {140543210788608, 5677966273219324761, 140548127856558, 140548127856559, 140543210788608, 140541870497360, -5662792260628845735, -5662177388227663015}, mask_was_saved = 0}}, priv = {pad = {0x0, 0x0, 0x0, 0x0}, data = {prev = 0x0, cleanup = 0x0, canceltype = 0}}}
not_first_call =
#15 0x00007fd3eb8784cf in clone () at …/sysdeps/unix/sysv/linux/x86_64/clone.S:95

I would first suggest upgrading to the latest release of 16. If the problem is still experienced then you’d need to file an issue[1] with the backtrace, as well as console log, and details about your usage of Asterisk.

[1] https://issues.asterisk.org/jira

Thank you, I will upgrade and let you know about results.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.