Docs: Commands to create coredump not working as expected
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 68/100
- Issue type
- Documentation
- Clarity
- Mostly clear
- Activity status
- Quiet
- Tech stack
- linux
- Domain
- documentation
Research direction
Start with the linked documentation's “GDB core dump” section and reproduce the command sequence on the reported environment. Update the instructions so the documented workflow matches the expected coredump behavior, then verify that a coredump is created as described.
Written by the indexing model from the issue text.
Description
Describe the bug
As described in #10825 I tried to generate a coredump using the command-chain provided in the docs
To Reproduce
Doing gdb -p 1962071 and then
(gdb) r
(gdb) generate-core-file
instead restarted/killed the icinga2 process, so that no core-dump could be generated.
Here is the complete output of running those commands
# gdb -p 1962071
GNU gdb (GDB) Red Hat Enterprise Linux 8.2-20.el8
Copyright (C) 2018 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 "x86_64-redhat-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
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".
Attaching to process 1962071
[New LWP 1962072]
[New LWP 1962073]
[New LWP 1962074]
[New LWP 1962075]
[New LWP 1962076]
[New LWP 1962077]
[New LWP 1962078]
[New LWP 1962079]
[New LWP 1962084]
[New LWP 1962103]
[New LWP 1962104]
[New LWP 1962105]
[New LWP 1962106]
[New LWP 1962107]
[New LWP 1962108]
[New LWP 1962109]
[New LWP 1962110]
[New LWP 1962111]
[New LWP 1962112]
[New LWP 1962113]
[New LWP 1962114]
[New LWP 1962115]
[New LWP 1962116]
[New LWP 1962117]
[New LWP 1962118]
[New LWP 1962119]
[New LWP 1962139]
[New LWP 1962147]
[New LWP 1962148]
[New LWP 1962149]
[New LWP 1962150]
Missing separate debuginfo for /usr/lib64/icinga2/sbin/icinga2
Try: yum --enablerepo='*debug*' install /usr/lib/debug/.build-id/f9/0c5c1299e6a46865250455aaa1396df6bc5511.debug
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
0x00007ce1790040a8 in nanosleep () from /lib64/libc.so.6
Missing separate debuginfos, use: yum debuginfo-install boost-atomic-1.66.0-13.el8.x86_64 boost-chrono-1.66.0-13.el8.x86_64 boost-context-1.66.0-13.el8.x86_64 boost-coroutine-1.66.0-13.el8.x86_64 boost-date-time-1.66.0-13.el8.x86_64 boost-filesystem-1.66.0-13.el8.x86_64 boost-iostreams-1.66.0-13.el8.x86_64 boost-program-options-1.66.0-13.el8.x86_64 boost-regex-1.66.0-13.el8.x86_64 boost-system-1.66.0-13.el8.x86_64 boost-thread-1.66.0-13.el8.x86_64 bzip2-libs-1.0.6-28.el8_10.x86_64 glibc-2.28-251.el8_10.31.x86_64 libblkid-2.32.1-48.el8_10.x86_64 libcap-2.48-6.el8_10.1.x86_64 libedit-3.1-23.20170329cvs.el8.x86_64 libgcc-8.5.0-28.el8_10.x86_64 libgcrypt-1.8.5-7.el8_6.x86_64 libgpg-error-1.31-1.el8.x86_64 libicu-60.3-2.el8_1.x86_64 libmount-2.32.1-48.el8_10.x86_64 libselinux-2.9-11.el8_10.x86_64 libuuid-2.32.1-48.el8_10.x86_64 lz4-libs-1.8.3-5.el8_10.x86_64 ncurses-libs-6.1-10.20180224.el8.x86_64 openssl-libs-1.1.1k-15.el8_6.x86_64 pcre2-10.32-3.el8_6.x86_64 sssd-client-2.9.4-5.el8_10.4.x86_64 zlib-1.2.11-25.el8.x86_64
(gdb) r
The program being debugged has been started already.
Start it from the beginning? (y or n) y
Starting program: /usr/lib64/icinga2/sbin/icinga2
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[New Thread 0x7ffff01d1700 (LWP 1970182)]
[Thread 0x7ffff01d1700 (LWP 1970182) exited]
[New Thread 0x7ffff01d1700 (LWP 1970183)]
[New Thread 0x7fffef9d0700 (LWP 1970184)]
[Thread 0x7ffff01d1700 (LWP 1970183) exited]
[Thread 0x7fffef9d0700 (LWP 1970184) exited]
[New Thread 0x7fffef9d0700 (LWP 1970185)]
[New Thread 0x7ffff01d1700 (LWP 1970186)]
[Thread 0x7fffef9d0700 (LWP 1970185) exited]
[Thread 0x7ffff01d1700 (LWP 1970186) exited]
[New Thread 0x7ffff01d1700 (LWP 1970187)]
[Thread 0x7ffff01d1700 (LWP 1970187) exited]
[New Thread 0x7ffff01d1700 (LWP 1970188)]
[New Thread 0x7fffef9d0700 (LWP 1970189)]
[Thread 0x7fffef9d0700 (LWP 1970189) exited]
[Thread 0x7ffff01d1700 (LWP 1970188) exited]
process 1970175 is executing new program: /usr/lib64/icinga2/sbin/icinga2
Missing separate debuginfo for /usr/lib64/icinga2/sbin/icinga2
Try: yum --enablerepo='*debug*' install /usr/lib/debug/.build-id/f9/0c5c1299e6a46865250455aaa1396df6bc5511.debug
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[New Thread 0x7ffff7fd1700 (LWP 1970190)]
[Thread 0x7ffff7fd1700 (LWP 1970190) exited]
[New Thread 0x7ffff7fd1700 (LWP 1970191)]
[New Thread 0x7ffff7f90700 (LWP 1970192)]
[Thread 0x7ffff7fd1700 (LWP 1970191) exited]
[Thread 0x7ffff7f90700 (LWP 1970192) exited]
[New Thread 0x7ffff7f90700 (LWP 1970193)]
[New Thread 0x7ffff7fd1700 (LWP 1970194)]
[Thread 0x7ffff7f90700 (LWP 1970193) exited]
[Thread 0x7ffff7fd1700 (LWP 1970194) exited]
[New Thread 0x7ffff7fd1700 (LWP 1970195)]
[Thread 0x7ffff7fd1700 (LWP 1970195) exited]
[New Thread 0x7ffff7fd1700 (LWP 1970196)]
[New Thread 0x7ffff7f90700 (LWP 1970197)]
[Thread 0x7ffff7f90700 (LWP 1970197) exited]
[New Thread 0x7ffff7fd1700 (LWP 1970198)]
[Thread 0x7ffff7fd1700 (LWP 1970196) exited]
[New Thread 0x7ffff7f90700 (LWP 1970199)]
[New Thread 0x7ffff7f4f700 (LWP 1970200)]
[New Thread 0x7ffff7f0e700 (LWP 1970201)]
[New Thread 0x7ffff7ecd700 (LWP 1970202)]
[New Thread 0x7ffff7e8c700 (LWP 1970203)]
[New Thread 0x7ffff7e4b700 (LWP 1970204)]
[New Thread 0x7ffff01d1700 (LWP 1970205)]
icinga2 - The Icinga 2 network monitoring daemon (version: r2.16.0-1)
Usage:
icinga2 <command> [<arguments>]
Supported commands:
* api setup (setup for API)
* ca list (lists pending certificate signing requests)
* ca remove (removes an outstanding certificate request)
* ca restore (restores a removed certificate request)
* ca sign (signs an outstanding certificate request)
* console (Icinga console)
* daemon (starts Icinga 2)
* feature disable (disables specified feature)
* feature enable (enables specified feature)
* feature list (lists all available features)
* node setup (set up node)
* node wizard (wizard for node setup)
* object list (lists all objects)
* pki new-ca (sets up a new CA)
* pki new-cert (creates a new CSR)
* pki request (requests a certificate)
* pki save-cert (saves another Icinga 2 instance's certificate)
* pki sign-csr (signs a CSR)
* pki ticket (generates a ticket)
* pki verify (verify TLS certificates: CN, signed by CA, is CA; Print certificate)
* variable get (gets a variable)
* variable list (lists all variables)
Global options:
-h [ --help ] show this help message
-V [ --version ] show version information
--color use VT100 color codes even when stdout is not a
terminal
-D [ --define ] arg define a constant
-I [ --include ] arg add include search directory
-x [ --log-level ] arg specify the log level for the console log.
The valid value is either debug, notice,
information (default), warning, or critical
-X [ --script-debugger ] whether to enable the script debugger
Report bugs at <https://github.com/Icinga/icinga2>
Get support: <https://icinga.com/support/>
Documentation: <https://icinga.com/docs/>
Icinga home page: <https://icinga.com/>
[Thread 0x7ffff7e4b700 (LWP 1970204) exited]
[Thread 0x7ffff01d1700 (LWP 1970205) exited]
[Thread 0x7ffff7e8c700 (LWP 1970203) exited]
[Thread 0x7ffff7ecd700 (LWP 1970202) exited]
[Thread 0x7ffff7f0e700 (LWP 1970201) exited]
[Thread 0x7ffff7f4f700 (LWP 1970200) exited]
[Thread 0x7ffff7f90700 (LWP 1970199) exited]
[Thread 0x7ffff7fd1700 (LWP 1970198) exited]
[Inferior 1 (process 1970175) exited normally]
Missing separate debuginfos, use: yum debuginfo-install boost-atomic-1.66.0-13.el8.x86_64 boost-chrono-1.66.0-13.el8.x86_64 boost-context-1.66.0-13.el8.x86_64 boost-coroutine-1.66.0-13.el8.x86_64 boost-date-time-1.66.0-13.el8.x86_64 boost-filesystem-1.66.0-13.el8.x86_64 boost-iostreams-1.66.0-13.el8.x86_64 boost-program-options-1.66.0-13.el8.x86_64 boost-regex-1.66.0-13.el8.x86_64 boost-system-1.66.0-13.el8.x86_64 boost-thread-1.66.0-13.el8.x86_64 bzip2-libs-1.0.6-28.el8_10.x86_64 glibc-2.28-251.el8_10.31.x86_64 libblkid-2.32.1-48.el8_10.x86_64 libcap-2.48-6.el8_10.1.x86_64 libedit-3.1-23.20170329cvs.el8.x86_64 libgcc-8.5.0-28.el8_10.x86_64 libgcrypt-1.8.5-7.el8_6.x86_64 libgpg-error-1.31-1.el8.x86_64 libicu-60.3-2.el8_1.x86_64 libmount-2.32.1-48.el8_10.x86_64 libselinux-2.9-11.el8_10.x86_64 libuuid-2.32.1-48.el8_10.x86_64 lz4-libs-1.8.3-5.el8_10.x86_64 ncurses-libs-6.1-10.20180224.el8.x86_64 openssl-libs-1.1.1k-15.el8_6.x86_64 pcre2-10.32-3.el8_6.x86_64 zlib-1.2.11-25.el8.x86_64
(gdb) generate-core-file
You can't do that without a process to debug.
# coredumpctl list
No coredumps found.
Expected behavior
That this creates a coredump.
Was able to do that with gcore <pid>.
Your Environment
Include as many relevant details about the environment you experienced the problem in
- Version used (
icinga2 --version): 2.16.0 - Operating System and version: RHEL8.10
- Dominant language
- C++
- Stars
- 2.2k
- Forks
- 616
- Avg merge
- 5d 6h
- Merged PRs (30d)
- 10
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Icinga/icinga2
-
area/itl
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
-
area/windows
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
-
area/documentation
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
area/itl
Difficulty 1/5 Under an hour Newbie friendliness 65/100
-
area/distributed good first issue
Difficulty 1/5 Under an hour Newbie friendliness 78/100
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 90/100
AXERA-TECH/ax-llm#77 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 90/100
games-on-whales/wolf#509 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
-
bug-unconfirmed
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
NVIDIA/cuda-samples#453 ·