public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug corefiles/16092] New: The 'gdb' 'gcore' command ignores coredump_filter, and 'madvise(,,MADV_DONTDUMP)'.
@ 2013-10-26 12:28 jbyers.sf at gmail dot com
  2013-10-26 12:29 ` [Bug corefiles/16092] " jbyers.sf at gmail dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: jbyers.sf at gmail dot com @ 2013-10-26 12:28 UTC (permalink / raw)
  To: gdb-prs

http://sourceware.org/bugzilla/show_bug.cgi?id=16092

            Bug ID: 16092
           Summary: The 'gdb' 'gcore' command ignores coredump_filter, and
                    'madvise(,,MADV_DONTDUMP)'.
           Product: gdb
           Version: 7.6
            Status: NEW
          Severity: normal
          Priority: P2
         Component: corefiles
          Assignee: unassigned at sourceware dot org
          Reporter: jbyers.sf at gmail dot com

The 'gdb' 'gcore' command ignores coredump_filter, and
'madvise(,,MADV_DONTDUMP)'.

On Linux x86_64, using 'gdb' version:

  GNU gdb (GDB) Red Hat Enterprise Linux (7.2-60.el6_4.1)

and also the latest version of 'gdb' '7.6.1' built from
source, the 'gcore' command used to take a "live" core of a
process ignores the Linux '/proc/PID/coredump_filter' bit
settings, and also 'mmap'ed memory madvise(,,MADV_DONTDUMP)'
settings and always dumps all of the address space
regardless of attempts to limit it.

Note that crash cores do not do this, and obey the filter
and madvise settings.

This is a real problem when the memory allocations are
large, and especially when there are large files mapped, but
sparsely accessed. Using 'gdb' and 'gcore' caused the
complete file to be read in and included it is also included
in the core.

There may be cases where overriding the coredump_filter and
'madvise(,,MADV_DONTDUMP)' are useful, but there should also
be a way to obey these settings and not have monstrously
huge 'gcore' generated core files.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-03-31 23:36 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-26 12:28 [Bug corefiles/16092] New: The 'gdb' 'gcore' command ignores coredump_filter, and 'madvise(,,MADV_DONTDUMP)' jbyers.sf at gmail dot com
2013-10-26 12:29 ` [Bug corefiles/16092] " jbyers.sf at gmail dot com
2013-11-13  6:23 ` jan.kratochvil at redhat dot com
2014-05-23  9:32 ` jan.kratochvil at redhat dot com
2015-03-05 21:44 ` sergiodj at redhat dot com
2015-03-31 23:40 ` cvs-commit at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).