While it normally isn’t a good idea to have core dumps enabled on a production server, sometimes that is the only way to debug a problem.
There are several things which are needed to be done to enable core dumps on a modern Linux. The attached script does this automatically for you. It has been tested on Redhat & CentOS systems
To enable core dumps, either log in or su to root, and type:
To disable them, type:
Be aware that Bash has it’s own ulimit value, so if you want to change the value in your current shell OR call this inside a shell script, type:
. /path/to/script/setcore.sh on
. /path/to/script/setcore.sh off
setcore.zip (1.5 KiB, 570 hits)