Check out my first novel, midnight's simulacra!

Core: Difference between revisions

From dankwiki
No edit summary
No edit summary
Line 13: Line 13:
* /proc/sys/fs/suid_dumpable
* /proc/sys/fs/suid_dumpable
* /proc/PID/coredump_filter allows memory map-specific coredump generation settings
* /proc/PID/coredump_filter allows memory map-specific coredump generation settings
==[[gcc]]==

Revision as of 09:48, 5 April 2010

  • Produce a corefile for a running process with gcore(1)
  • The RLIMIT_CORE rlimit specifies the maximum size of a corefile (use 0 to disable corefile generation)

FreeBSD

  • sysctl kern.corefile controls naming mechanisms. See the core(5) man page.
  • sysctl kern.sugid_coredump controls whether processes with different effective and real U/GIDs produce corefiles
  • See savecore(8) and crashinfo(8) for further FreeBSD-specific capabilities

Linux

  • /proc/sys/kernel/core_pattern allows core naming to be configured (since Linux 2.6 and 2.4.21), and corefiles to be piped to programs. See the core(5) man page.
  • /proc/sys/kernel/core_uses_pid controls whether the PID is appended to the corefile's name
  • The prctl flag PR_SET_DUMPABLE allows process-specific coredump generation settings
  • /proc/sys/fs/suid_dumpable
  • /proc/PID/coredump_filter allows memory map-specific coredump generation settings

gcc