Solved

core does not get generated in linux

Posted on 2012-04-11
4
443 Views
Last Modified: 2012-04-12
Hello
This is URGENT!!!
core file is not getting generated for a process(pid: 1234), after running "kill -9 1234" or "kill -11 1234"


machine is:
Linux abc.def.xyz.org 2.6.18-164.2.1.el5xen #1 SMP Mon Sep 21 04:45:50 EDT 2009 x86_64 x86_64 x86_64 GNU/Linux

ulimit -a is:
core file size          (blocks, -c) unlimited
data seg size           (kbytes, -d) unlimited
scheduling priority             (-e) 0
file size               (blocks, -f) unlimited
pending signals                 (-i) 32768
max locked memory       (kbytes, -l) 32
max memory size         (kbytes, -m) unlimited
open files                      (-n) 1024
pipe size            (512 bytes, -p) 8
POSIX message queues     (bytes, -q) 819200
real-time priority              (-r) 0
stack size              (kbytes, -s) 10240
cpu time               (seconds, -t) unlimited
max user processes              (-u) 32768
virtual memory          (kbytes, -v) unlimited
file locks                      (-x) unlimited


cat /proc/1234/limits is:
Max cpu time              unlimited            unlimited            seconds
Max file size             unlimited            unlimited            bytes
Max data size             unlimited            unlimited            bytes
Max stack size            10485760             unlimited            bytes
Max core file size        unlimited            unlimited            bytes
Max resident set          unlimited            unlimited            bytes
Max processes             32768                32768                processes
Max open files            1024                 1024                 files
Max locked memory         32768                32768                bytes
Max address space         unlimited            unlimited            bytes
Max file locks            unlimited            unlimited            locks
Max pending signals       32768                32768                signals
Max msgqueue size         819200               819200               bytes
Max nice priority         0                    0


PLease help

Sham
0
Comment
Question by:mohet01
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 68

Expert Comment

by:woolmilkporc
ID: 37832266
Hi,

"kill -9" will never force a core dump.

Try "kill -6"  ("ABRT") instead.

If this doesn't work try "kill -3" ("QUIT").

wmp
0
 

Author Comment

by:mohet01
ID: 37832354
if the sigsegv is generated due to code problem, how to generate core?
Sham
0
 
LVL 68

Accepted Solution

by:
woolmilkporc earned 500 total points
ID: 37832529
Your program should always generate a core dump when a SEGV occurs, unless its SUID root
(permissions -rws...... and owner root).

In this case special coding is required, see this thread:

http://fixunix.com/unix/398999-forcing-core-dump-sigsegv-setuid-program-linux.html

Or remove the setuid bit and run the program as root, if required (and if you're allowed to do so).
0
 

Author Closing Comment

by:mohet01
ID: 37837000
perfect
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Templates For Beginners Or How To Encourage The Compiler To Work For You Introduction This tutorial is targeted at the reader who is, perhaps, familiar with the basics of C++ but would prefer a little slower introduction to the more ad…
Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
The goal of this video is to provide viewers with basic examples to understand and use conditional statements in the C programming language.
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question