Operating System - HP-UX
1834935 Members
2331 Online
110071 Solutions
New Discussion

Re: How to make a process to generate core file.

 
sunil m. r
Occasional Contributor

How to make a process to generate core file.

Hi,
I am running a process which crashes after running for long. It does not produce any core
files in its working directory. But I need a core file for analysis. Is there any specific setting to be done on the system to make the process produce a core file? The process crashes after showing the message "Segmentation Fault".

Thanks in advance for any help or suggestions.

Regards
Sunil
3 REPLIES 3
Umapathy S
Honored Contributor

Re: How to make a process to generate core file.

Sunil,

Check the env settings for the application. ulimit gives details about those settings. Its available only on sh and not on ksh.
try ulimit -a to list the settings and change the coredump size to any value using ulimit -c.
man sh-posix for more details
HTH,
Umapathy

Also, please assign points to those who help you. Go to your previous threads and do that. This will motivate others to help you more.
Arise Awake and Stop NOT till the goal is Reached!
Bhuvaneswari Selvaraj
Valued Contributor

Re: How to make a process to generate core file.

Hi,

You need to send the signal SIGQUIT to the process to make it dump core.

Segmentation fault can occur due to many reasons, I guess only debugging can help you. Try using gdb, that will help you a lot.
Jeff Schussele
Honored Contributor

Re: How to make a process to generate core file.

Hi Sunil,

Sending a
kill -3 PID
to the process will cause it to core dump.

Rgds,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!