• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

CMakeFiles/H07-May-2022-1712

examples/H14-Dec-2021-620429

include/coredumper/H14-Dec-2021-25669

man/H14-Dec-2021-352346

src/H03-May-2022-7,1085,104

test/H03-May-2022-1,243898

.clang-formatH A D14-Dec-2021224 1211

.gitignoreH A D14-Dec-2021310 3331

AUTHORSH A D14-Dec-202123 31

COPYINGH A D14-Dec-20211.4 KiB2925

ChangeLogH A D14-Dec-20214 KiB9676

MakefileH A D14-Dec-20218.3 KiB223116

README.mdH A D14-Dec-20212.2 KiB6649

cmake_install.cmakeH A D14-Dec-20211.5 KiB5141

compileH A D14-Dec-20212.7 KiB10048

test-driverH A D14-Dec-20214.5 KiB14987

README.md

1The coredumper library can be compiled into applications to create
2core dumps of the running program, without having to terminate
3them. It supports both single- and multi-threaded core dumps, even if
4the kernel does not have native support for multi-threaded core files.
5
6This library is primarily intended to simplify debugging of
7long-running services. It is often inacceptable to suspend production
8services by attaching a debugger, nor is it possible to crash the
9service in order to generate a core file.
10
11By modifying an existing service to take advantage of the coredumper
12library, it is possible to expose an interface for obtaining snapshots
13of the running application. The library supports writing of core files
14to disk (e.g. triggered upon reception of a signal) but it can also
15generate in-memory core files.  This makes it possible for web
16services to expose remote access to core files.
17
18The "examples" directory shows how to add a core file feature to an
19existing TFTP server. For an example of how to use on-disk core files,
20take a look at "src/coredump_unittest.c".
21
22The code has been tested on Linux x86/64. It is
23available as a git source archive, and can be build using CMake.
24
25To configure the library, execute CMake first by running:
26
27```
28cmake <src_dir> -DCMAKE_BUILD_TYPE=(Debug|RelWithDebInfo|Release) \
29                -DBUILD_SHARED_LIBS=(ON|OFF) \
30                -DCMAKE_INSTALL_PREFIX=<install_dir> \
31                -DBUILD_TESTING=(ON|OFF)
32                -G<build_system>
33```
34
35All options are optional, and the boolean options default to `ON`.
36The library can be used both in the build tree and at the install location,
37both using `add_subdirectory` and using the exported cmake configurations.
38
39After configuring, run Make/Ninja/anythnig:
40
41```
42ninja
43```
44
45If the tests were built, they can be executed using CTest:
46
47```
48ctest .
49```
50
51The library can be installed using the install target:
52
53```
54ninja install
55```
56The preferred method of using the library is by using the provided
57cmake configuration files. These configuration files can be found at:
58
59 * CMAKE_BUILD_DIR/src/libcoredumper.cmake
60 * CMAKE_INSTALL_DIR/cmake/libcoredumper.cmake
61
62For more information on how to use the library, read the manual pages
63for "GetCoreDump" and "WriteCoreDump".
64
6514 May 2020
66