Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate coredump failed: double free or corruption (!prev) #2

Open
TyphoonWu opened this issue Apr 14, 2022 · 3 comments
Open

Generate coredump failed: double free or corruption (!prev) #2

TyphoonWu opened this issue Apr 14, 2022 · 3 comments

Comments

@TyphoonWu
Copy link

Gcore version: v1.6.3
Crash utility version: 8.0.0

Failed logs:
crash> extend gcore.so
crash-8.0.0/extensions/gcore.so: shared object loaded
crash> set 4615
PID: 4615
COMMAND: "Binder:1413_4"
TASK: ffffff89354a3780 [THREAD_INFO: ffffff89354a3780]
CPU: 1
STATE: TASK_INTERRUPTIBLE
crash> bt
PID: 4615 TASK: ffffff89354a3780 CPU: 1 COMMAND: "Binder:1413_4"
#0 [ffffffc02c7ebb50] __switch_to at ffffffd3c2c73768
#1 [ffffffc02c7ebbb0] __schedule at ffffffd3c4802470
#2 [ffffffc02c7ebc10] schedule at ffffffd3c4802b24
#3 [ffffffc02c7ebc30] futex_wait_queue_me at ffffffd3c2e93344
#4 [ffffffc02c7ebd30] futex_wait at ffffffd3c2e8de90
#5 [ffffffc02c7ebda0] do_futex at ffffffd3c2e8dc3c
#6 [ffffffc02c7ebde0] __arm64_sys_futex at ffffffd3c2e96d70
#7 [ffffffc02c7ebe50] el0_svc_common at ffffffd3c2c8ddd8
#8 [ffffffc02c7ebe90] el0_svc at ffffffd3c4446388
#9 [ffffffc02c7ebea0] el0_sync_handler at ffffffd3c44462fc
#10 [ffffffc02c7ebfe0] el0_sync at ffffffd3c2c12070
PC: 0000006fef32df34 LR: 0000006fef332800 SP: 0000006f2a603670
X29: 0000006f2a603690 X28: 0000000000000000 X27: 0000000000000585
X26: 0000006f2a604000 X25: 0000000000000019 X24: 0000006f2a604000
X23: 0000006f2a603fb0 X22: 0000000000000089 X21: b400006f4ce695c0
X20: 0000000000000000 X19: 0000000000000000 X18: 0000006f1f3c0000
X17: 0000006fef32df10 X16: 0000006fef3a6ca8 X15: 000000463f3a907d
X14: 000000000075e714 X13: 000000007fffffff X12: 0000006ff72e2030
X11: 0000000000000000 X10: 0000000000000009 X9: 0000000000000089
X8: 0000000000000062 X7: 7f7f7f7f7f7f7f7f X6: 00000000ffffffff
X5: 00000000ffffffff X4: 0000000000000000 X3: 0000000000000000
X2: 0000000000000000 X1: 0000000000000089 X0: b400006f4ce695c0
ORIG_X0: b400006f4ce695c0 SYSCALLNO: 62 PSTATE: 40001000
crash> gcore -v 0
double free or corruption (!prev)
Aborted

@d-hatayama
Copy link
Collaborator

Thanks for your report and sorry for delayed responce.

Could you provide more information to facilitate investigation? Only possible things are enough.

  • Kernel version
    • If you use some distribution kernel, the corresponding kernel package name and version are preferable.
  • Architecture
    • According to the backtrace, aarch64?
  • Steps to reproduce the issue for me

@YuanyeMa
Copy link

YuanyeMa commented Aug 31, 2022

I had the same problem.
I'm using crash-utils to parse rawdumps captured from Android devices.

Architecture : aarch64
Kernel version : 5.4.147

crash vmlinux --kaslr=0x1444600000 --machdep kimage_voffset=0xffffffd3b4600000,vabits_actual=39 DDRCS0_0.BIN@0x80000000,DDRCS0_1.BIN@0x100000000,DDRCS0_2.BIN@0x180000000,DDRCS1_0.BIN@0x200000000,DDRCS1_1.BIN@0x280000000,DDRCS1_2.BIN@0x300000000 -x

crash 8.0.1
Copyright (C) 2002-2022 Red Hat, Inc.
Copyright (C) 2004, 2005, 2006, 2010 IBM Corporation
Copyright (C) 1999-2006 Hewlett-Packard Co
Copyright (C) 2005, 2006, 2011, 2012 Fujitsu Limited
Copyright (C) 2006, 2007 VA Linux Systems Japan K.K.
Copyright (C) 2005, 2011, 2020-2022 NEC Corporation
Copyright (C) 1999, 2002, 2007 Silicon Graphics, Inc.
Copyright (C) 1999, 2000, 2001, 2002 Mission Critical Linux, Inc.
Copyright (C) 2015, 2021 VMware, Inc.
This program is free software, covered by the GNU General Public License,
and you are welcome to change it and/or distribute copies of it under
certain conditions. Enter "help copying" to see the conditions.
This program has absolutely no warranty. Enter "help warranty" for details.

NOTE: setting kimage_voffset to: 0xffffffd3b4600000

NOTE: setting vabits_actual to: 39

GNU gdb (GDB) 10.2
Copyright (C) 2021 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "--host=x86_64-pc-linux-gnu --target=aarch64-elf-linux".
Type "show configuration" for configuration details.
Find the GDB manual and other documentation resources online at:
http://www.gnu.org/software/gdb/documentation/.

For help, type "help".
Type "apropos word" to search for commands related to "word"...

WARNING: cpu 0: cannot find NT_PRSTATUS note
WARNING: cpu 1: cannot find NT_PRSTATUS note
WARNING: cpu 2: cannot find NT_PRSTATUS note
WARNING: cpu 3: cannot find NT_PRSTATUS note
WARNING: cpu 4: cannot find NT_PRSTATUS note
WARNING: cpu 5: cannot find NT_PRSTATUS note
WARNING: cpu 6: cannot find NT_PRSTATUS note
WARNING: cpu 7: cannot find NT_PRSTATUS note
KERNEL: vmlinux [TAINTED]
DUMPFILES: /var/tmp/ramdump_elf_NPuBp8 [temporary ELF header]
DDRCS0_0.BIN
DDRCS0_1.BIN
DDRCS0_2.BIN
DDRCS1_0.BIN
DDRCS1_1.BIN
DDRCS1_2.BIN
CPUS: 8 [OFFLINE: 6]
DATE: Thu Jan 1 21:11:58 CST 1970
UPTIME: 00:02:43
LOAD AVERAGE: 15.74, 7.87, 3.07
TASKS: 2741
NODENAME: localhost
RELEASE: 5.4.147-qgki-debug-g98eca99d6d1e
VERSION: #1 SMP PREEMPT Tue Aug 16 01:20:04 CST 2022
MACHINE: aarch64 (unknown Mhz)
MEMORY: 11.5 GB
PANIC: "1970:01:01 21:11:31[1:init]Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b"
PID: 1
COMMAND: "init"
TASK: ffffff95c514bd40 [THREAD_INFO: ffffff95c514bd40]
CPU: 7
STATE: TASK_RUNNING (PANIC)

/home/xxx/tools/gz/crash-8.0.1/extensions/gcore.so: shared object loaded
/home/xxx/tools/gz/crash-8.0.1/extensions/snap.so: shared object loaded
/home/xxx/tools/gz/crash-8.0.1/extensions/dminfo.so: shared object loaded
/home/xxx/tools/gz/crash-8.0.1/extensions/echo.so: shared object loaded
crash: /home/xxx/tools/gz/crash-8.0.1/extensions/eppic.so: no commands registered: shared object unloaded

crash> set 1
PID: 1
COMMAND: "init"
TASK: ffffff95c514bd40 [THREAD_INFO: ffffff95c514bd40]
CPU: 7
STATE: TASK_RUNNING (PANIC)
crash> bt
PID: 1 TASK: ffffff95c514bd40 CPU: 7 COMMAND: "init"
bt: WARNING: cannot determine starting stack frame for task ffffff95c514bd40
crash> gcore -v 0 1
double free or corruption (!prev)
Aborted

@YuanyeMa
Copy link

YuanyeMa commented Sep 2, 2022

Is it related to the kernel opening zram?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants