numastat <pid> fails with double free or corruption
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
The Ubuntu-power-systems project |
Fix Released
|
Medium
|
Canonical Server | ||
numactl (Ubuntu) |
Fix Released
|
Medium
|
Canonical Server | ||
Xenial |
Invalid
|
Undecided
|
Unassigned | ||
Bionic |
Invalid
|
Undecided
|
Unassigned | ||
Cosmic |
Invalid
|
Medium
|
Unassigned | ||
Disco |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
while trying to get stat of the guest process (configured with hugepages), numastat fails
=======
Environment details
=======
# uname -a
Linux lep8b 4.8.0-30-generic #32-Ubuntu SMP Fri Dec 2 03:43:46 UTC 2016 ppc64le ppc64le ppc64le GNU/Linu
=====
Issue
=====
2016-12-14 07:02:56,396 process L0368 INFO | Running 'numastat 61257'
2016-12-14 07:02:56,402 process L0462 DEBUG| [stderr] *** Error in `numastat': double free or corruption (out): 0x00000100265005a0 ***
2016-12-14 07:02:56,403 process L0462 DEBUG| [stdout]
2016-12-14 07:02:56,403 process L0482 INFO | Command 'numastat 61257' finished with -6 after 0.00309896469116s
2016-12-14 07:02:56,403 process L0462 DEBUG| [stdout] Per-node process memory usage (in MBs) for PID 61257 (qemu-system-ppc)
2016-12-14 07:02:56,404 process L0462 DEBUG| [stderr] ======= Backtrace: =========
2016-12-14 07:02:56,404 process L0462 DEBUG| [stderr] /lib/powerpc64l
2016-12-14 07:02:56,404 process L0462 DEBUG| [stderr] /lib/powerpc64l
2016-12-14 07:02:56,404 process L0462 DEBUG| [stderr] /lib/powerpc64l
2016-12-14 07:02:56,405 process L0462 DEBUG| [stderr] /lib/powerpc64l
2016-12-14 07:02:56,405 process L0462 DEBUG| [stderr] numastat(
2016-12-14 07:02:56,405 process L0462 DEBUG| [stderr] numastat(
2016-12-14 07:02:56,405 process L0462 DEBUG| [stderr] /lib/powerpc64l
2016-12-14 07:02:56,405 process L0462 DEBUG| [stderr] /lib/powerpc64l
2016-12-14 07:02:56,405 process L0462 DEBUG| [stderr] ======= Memory map: ========
2016-12-14 07:02:56,405 process L0462 DEBUG| [stderr] 401d0000-401e0000 r-xp 00000000 08:92 40325510 /usr/bin/numastat
2016-12-14 07:02:56,405 process L0462 DEBUG| [stderr] 401e0000-401f0000 r--p 00000000 08:92 40325510 /usr/bin/numastat
2016-12-14 07:02:56,406 process L0462 DEBUG| [stderr] 401f0000-40200000 rw-p 00010000 08:92 40325510 /usr/bin/numastat
2016-12-14 07:02:56,406 process L0462 DEBUG| [stderr] 10026500000-
2016-12-14 07:02:56,406 process L0462 DEBUG| [stderr] 3fff9a6b0000-
2016-12-14 07:02:56,406 process L0462 DEBUG| [stderr] 3fff9a860000-
2016-12-14 07:02:56,406 process L0462 DEBUG| [stderr] 3fff9a870000-
2016-12-14 07:02:56,406 process L0462 DEBUG| [stderr] 3fff9a880000-
2016-12-14 07:02:56,406 process L0462 DEBUG| [stderr] 3fff9a8b0000-
2016-12-14 07:02:56,407 process L0462 DEBUG| [stderr] 3fff9a8c0000-
2016-12-14 07:02:56,407 process L0462 DEBUG| [stderr] 3fff9a8e0000-
2016-12-14 07:02:56,407 process L0462 DEBUG| [stderr] 3fff9a920000-
2016-12-14 07:02:56,407 process L0462 DEBUG| [stderr] 3fff9a930000-
2016-12-14 07:02:56,407 process L0462 DEBUG| [stderr] 3fffdd320000-
=============
Recreation Steps
=============
1. Configure host with hugepages
2. Start a guest and attach following memory device xml,
<?xml version='1.0' encoding='UTF-8'?>
<memory model="
3. Set the rules in guest
4. execute numastat of guest pid
Expected Result :
Provide PID numastat
# numastat 55119
Per-node process memory usage (in MBs) for PID 55119 (qemu-system-ppc)
Huge 0.00 0.00 0.00
Heap 2.00 0.38 0.00
Stack 0.00 0.00 0.00
Private 31800.12 183.06 0.00
---------------- --------------- --------------- ---------------
Total 31802.12 183.44 0.00
Huge 0.00 0.00
Heap 0.00 15.25
Stack 0.00 0.06
Private 0.00 33169.31
---------------- --------------- ---------------
Total 0.00 34345.00
*** Error in `numastat': free(): invalid next size (fast): 0x000001003f2c0580 ***
======= Backtrace: =========
/lib/powerpc64l
/lib/powerpc64l
/lib/powerpc64l
numastat(
numastat(
numastat(
/lib/powerpc64l
/lib/powerpc64l
======= Memory map: ========
5adc0000-5add0000 r-xp 00000000 08:92 40325510 /usr/bin/numastat
5add0000-5ade0000 r--p 00000000 08:92 40325510 /usr/bin/numastat
5ade0000-5adf0000 rw-p 00010000 08:92 40325510 /usr/bin/numastat
1003f2c0000-
3fff827e0000-
3fff82990000-
3fff829a0000-
3fff829b0000-
3fff829e0000-
3fff829f0000-
3fff82a10000-
3fff82a50000-
3fff82a60000-
3fffc3b90000-
Aborted
== Comment: #2 - SEETEENA THOUFEEK <email address hidden> - 2016-12-15 03:31:48 ==
root@lep8b:/proc# dpkg -l | grep numa
ii libnuma1:ppc64el 2.0.11-1ubuntu2 ppc64el Libraries for controlling NUMA policy
ii numactl 2.0.11-1ubuntu2 ppc64el NUMA scheduling and memory placement tool
root@lep8b:/proc# uname -r
4.8.0-30-generic
Added the numa version and kernel version.
.
Mirroring to Ubuntu team to cherry pick this patch.
tags: | added: patch server-next |
Changed in numactl (Ubuntu): | |
status: | Triaged → Incomplete |
tags: | removed: bugnameltc-149964 patch server-next severity-medium |
tags: | added: bugnameltc-149964 severity-medium |
Changed in ubuntu-power-systems: | |
status: | New → Incomplete |
importance: | Undecided → Medium |
assignee: | nobody → Canonical Server Team (canonical-server) |
tags: | added: triage-g |
tags: |
added: targetmilestone-inin1810 removed: targetmilestone-inin--- |
Changed in ubuntu-power-systems: | |
status: | Incomplete → Triaged |
Changed in ubuntu-power-systems: | |
status: | Triaged → Incomplete |
Default Comment by Bridge