Crash report

=== REDIS BUG REPORT START: Cut & paste starting from here ===
410:M 11 Jul 2023 14:29:07.643 # Redis 5.0.5 crashed by signal: 11
410:M 11 Jul 2023 14:29:07.643 # Crashed running the instruction at: 0x7f995d3797ad
410:M 11 Jul 2023 14:29:07.643 # Accessing address: 0x1
410:M 11 Jul 2023 14:29:07.643 # Failed assertion: <no assertion failed> (<no file>:0)

------ STACK TRACE ------
EIP:
/lib64/libc.so.6(time+0xd)[0x7f995d3797ad]

Backtrace:
/usr/bin/redis-server *:6379 [cluster](logStackTrace+0x41)[0x475101]
/usr/bin/redis-server *:6379 [cluster](sigsegvHandler+0x96)[0x475786]
/lib64/libpthread.so.0(+0xf7e0)[0x7f995d6807e0]
/lib64/libc.so.6(time+0xd)[0x7f995d3797ad]
/usr/bin/redis-server *:6379 [cluster](aeProcessEvents+0x202)[0x42a402]
/usr/bin/redis-server *:6379 [cluster](aeMain+0x2b)[0x42a6db]
/usr/bin/redis-server *:6379 [cluster](main+0x4c4)[0x426db4]
/lib64/libc.so.6(__libc_start_main+0xfd)[0x7f995d2fbd5d]
/usr/bin/redis-server *:6379 [cluster][0x426fcd]

------ INFO OUTPUT ------
# Server^M
redis_version:5.0.5^M
redis_git_sha1:000000000^M
redis_git_dirty:1^M
redis_build_id:e64cddb4efd4e763^M
redis_mode:cluster^M
os:Linux 3.10.0-862.3.0.0.el7.ksyun.x86_64 x86_64^M
arch_bits:64^M
multiplexing_api:epoll^M
atomicvar_api:atomic-builtin^M
gcc_version:7.3.1^M
process_id:410^M
run_id:a3314893d5d66ecd833345a6c2d3a432f16b9a1b
tcp_port:6379^M
uptime_in_seconds:2809133^M
uptime_in_days:32^M
hz:10^M
configured_hz:10^M
lru_clock:11335347^M
executable:/usr/bin/redis-server^M
config_file:/etc/redis/redis.conf
。。。
------ REGISTERS ------
410:M 11 Jul 2023 14:29:07.648 #
RAX:0000000064acf6b3 RBX:00007f995ceb3800
RCX:0000000000000000 RDX:0000000000000027
RDI:0000000000000000 RSI:0000000000000028
RBP:0000000000000001 RSP:00007ffc6ed98b90
R8 :00007f994c6dff05 R9 :000000000000000f
R10:000000000000000f R11:0000000000000005
R12:00007f995ce270a0 R13:0000000000000001
R14:0000000000000001 R15:0000000000000340
RIP:00007f995d3797ad EFL:0000000000010206
CSGSFS:0000000000000033
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b9f) -> 0000000000426db4
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b9e) -> 0000000000000199
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b9d) -> 000000000042a6db
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b9c) -> 00007f995ce27003
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b9b) -> 0000000001ccb340
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b9a) -> 00007ffc6ed98d68
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b99) -> 00007ffc6ed98d48
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b98) -> 00000000000000d7
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b97) -> 00007f995ce270a0
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b96) -> 00007ffc6ed98d48
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b95) -> 000000000009d140
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b94) -> 0000000064acf6b3
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b93) -> 0000000b00000000
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b92) -> 0000000000000000
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b91) -> 000000000042a402
410:M 11 Jul 2023 14:29:07.648 # (00007ffc6ed98b90) -> 00007f995ce270a0

------ DUMPING CODE AROUND EIP ------
Symbol: time (base: 0x7f995d3797a0)
Module: /lib64/libc.so.6 (base 0x7f995d2dd000)
$ xxd -r -p /tmp/dump.hex /tmp/dump.bin
$ objdump --adjust-vma=0x7f995d3797a0 -D -b binary -m i386:x86-64 /tmp/dump.bin
------
410:M 11 Jul 2023 14:29:11.850 # dump of function (hexdump of 141 bytes):
4883ec0848c7c0000460ffffd04883c408c390909090909090909090909090904883ec08488b05756a2f0048c1c811644833042530000000ffd03d01f0ffff73054883c408c3488b0dbb172f0031d24829c26489114883c8ffebe69090909090b8a40000000f05483d01f0ffff7301c3488b0d91172f0031d24829c26489114883c8ffebea9090909090909090

=== REDIS BUG REPORT END. Make sure to include from START to END. ===

       Please report the crash by opening an issue on github:

           http://github.com/antirez/redis/issues

  Suspect RAM error? Use redis-server --test-memory to verify it.

gdb bt show

warning: no loadable sections found in added symbol-file system-supplied DSO at 0x7ffc6edd0000
Core was generated by `/usr/bin/redis-server *:6379 [cluster]                                        '.
Program terminated with signal 11, Segmentation fault.
#0  0x00007f995d30f907 in kill () from /lib64/libc.so.6
Missing separate debuginfos, use: debuginfo-install glibc-2.12-1.166.el6_7.7.x86_64 libgcc-4.4.7-16.el6.x86_64
(gdb) bt
#0  0x00007f995d30f907 in kill () from /lib64/libc.so.6
#1  0x000000000047588e in sigsegvHandler (sig=11, info=Unhandled dwarf expression opcode 0xf3
) at debug.c:1349
#2  <signal handler called>
#3  0x00007f995d3797ad in time () from /lib64/libc.so.6
#4  0x000000000042a402 in processTimeEvents (eventLoop=0x7f995ce270a0, flags=11) at ae.c:274
#5  aeProcessEvents (eventLoop=0x7f995ce270a0, flags=11) at ae.c:469
#6  0x000000000042a6db in aeMain (eventLoop=0x7f995ce270a0) at ae.c:501
#7  0x0000000000426db4 in main (argc=<value optimized out>, argv=0x7ffc6ed98d48) at server.c:4394
(gdb) info r
rax            0x0  0
rbx            0xb  11
rcx            0xffffffffffffffff   -1
rdx            0x19a    410
rsi            0xb  11
rdi            0x19a    410
rbp            0x8d 0x8d
rsp            0x7ffc6ed97de8   0x7ffc6ed97de8
r8             0x0  0
r9             0x7369646572206573   8316288573785531763
r10            0x7ffc6ed97b70   140722168232816
r11            0x206    518
r12            0xd  13
r13            0x7f994fdfdd49   140296446795081
r14            0x7f9959454005   140296604434437
r15            0x340    832
rip            0x7f995d30f907   0x7f995d30f907 <kill+7>
eflags         0x206    [ PF IF ]
cs             0x33 51
ss             0x2b 43
ds             0x0  0
es             0x0  0
fs             0x0  0
gs             0x0  0
(gdb) 

Additional information compile env:gcc 7.3.1 on centos 6.7 docker images using redhat scl install

  1. running in centos 6.7 LXC (linux container) env
  2. can't reproduce ,some others redis don't occur ,

Comment From: bugwz

@heyone-top hi~

I haven't encountered this issue before, but I can provide some ideas and suggestions:

  1. The problem seems to occur during the time function call, which is quite strange. It is possible that another external program mistakenly executed kill -11, causing this issue.
  2. I suggest evaluating the feasibility of upgrading Redis.