[PATCH 1/2] Cygwin: Make 'ulimit -c' control writing a coredump

Corinna Vinschen corinna-cygwin@cygwin.com
Fri Jan 12 16:36:46 GMT 2024


On Jan 12 14:09, Jon Turney wrote:
> On 11/01/2024 09:42, Corinna Vinschen wrote:
> > I see.  It's a bit unfortunate though, if dumper tries to create
> > a 2 Gigs file which is later truncated, if we're low on disk space.
> > But yeah, disk space isn't much of a problem these days, I guess...
> 
> Assuming there isn't a clear specification of which of these is supposed to
> happen, I think removing is the better choice, since partial coredumps are
> just useless.
> 
> (There's still some potential lossage if the coredump is big enough to fill
> the disk, but less than the (perhaps badly-chosen) ulimit.  But maybe that
> could be fixed by having dumper remove the file if it couldn't be written
> successfully))

The Linux kernel actually writes blocks until the next write would
overrun RLIMIT_CORE.  It would be nice if we could get some similar
behaviour, but that's something for post 3.5.


Corinna


More information about the Cygwin-patches mailing list