coredump settings

Jim Hayward jimhayward at earthlink.net
Sun Oct 24 12:08:19 UTC 2004


On Sat, 2004-10-23 at 05:03 -0700, Vaibhav Deshpande wrote:
> One of my application programs (C++) is giving segmentation fault and
> I'm not able to get core dump of running process.
>  
> What settings I need to do to get core dumps?
>  

core dumps are turned off by default in /etc/profile. You can make per
user changes by editing your ~/.bash_profile. 

Look for the line, ulimit -S -c 0 > /dev/null 2>&1, you can either
comment out the entire line to set no limit on the size of the core
files or set your own maximum size.

This disables core dumps by setting there maximum size to zero
ulimit -S -c 0. The rest of the line, > /dev/null 2>&1, deletes the zero
length file by redirecting the output to /dev/null.

Instead of using core dumps it would be just as easy to run your
application under gdb.

Regards,
	Jim H
-- 
Jim Hayward <jimhayward at earthlink.net>
GPG Key available at: http://keyserver.noreply.org
gpg --recv-keys --keyserver keyserver.noreply.org 0x85A92DCC
GPG Fingerprint: 1AA9 AEC9 BFDF FF7A E4F8 90C7 4947 3A41 85A9 2DCC 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://listman.redhat.com/archives/redhat-install-list/attachments/20041024/c53a10fb/attachment.sig>


More information about the Redhat-install-list mailing list