LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices

Reply
 
LinkBack Search this Thread
Old 04-03-2013, 06:52 PM   #1
khandu
Member
 
Registered: Sep 2003
Posts: 62

Rep: Reputation: 0
Unhappy Core dump not being generated in RHEL 6.4


Hi

New to linux here but after reading a bit..

We have a process being run by "user1". It crashes and we can see a segfault in the /var/log/messages

Other settings of the server are
Quote:
[10:13:28]user1 hostname:~$cat /proc/sys/kernel/core_pattern
/srv/home/user1/core.%p.%e.%t
[10:13:34]user1 hostname:~$cat /proc/sys/kernel/core_uses_pid
1
[10:13:57]user1 hostname:~$ulimit -a
core file size (blocks, -c) unlimited
data seg size (kbytes, -d) unlimited
scheduling priority (-e) 0
file size (blocks, -f) unlimited
pending signals (-i) 127462
max locked memory (kbytes, -l) 64
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) 1024
virtual memory (kbytes, -v) unlimited
file locks (-x) unlimited
Still we cannot find any core dump file to send to vendor for diagnostics..

How can we fix this??
 
Old 04-03-2013, 07:57 PM   #2
ShadowCat8
Member
 
Registered: Nov 2004
Location: Arcadia, CA
Distribution: Gentoo, Sabayon, (RedHat4.x-9.x, FedoraCore 1.x-4.x, Debian Potato-Sarge, LFS 6.0, etc.)
Posts: 209

Rep: Reputation: 43
Greetings,

Just for a little clarification, when you say that it is crashing, is it locking the system up as well? In other words, are you having to reboot the system to recover from the crash?

Let us know.
 
Old 04-03-2013, 08:43 PM   #3
khandu
Member
 
Registered: Sep 2003
Posts: 62

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by ShadowCat8 View Post
Greetings,

Just for a little clarification, when you say that it is crashing, is it locking the system up as well? In other words, are you having to reboot the system to recover from the crash?

Let us know.
Just the application is freezing / crashing.. System is fine..

Just confused why coredump is not generated with all those settings...

doing a manual coredump via gdb command.. but not core dump automatically does not help when we are not monitoring.
 
Old 04-04-2013, 04:17 AM   #4
Satyaveer Arya
Senior Member
 
Registered: May 2010
Location: Dehradun, Uttarakhand, India
Distribution: RHEL, CentOS, Debian, Oracle Solaris 10
Posts: 1,412

Rep: Reputation: 303Reputation: 303Reputation: 303Reputation: 303
khandu,

Checkout these two links, it may help you-

http://honglus.blogspot.in/2010/06/h...-dump-for.html
http://www.cyberciti.biz/tips/linux-core-dumps.html
 
Old 04-04-2013, 11:42 AM   #5
ShadowCat8
Member
 
Registered: Nov 2004
Location: Arcadia, CA
Distribution: Gentoo, Sabayon, (RedHat4.x-9.x, FedoraCore 1.x-4.x, Debian Potato-Sarge, LFS 6.0, etc.)
Posts: 209

Rep: Reputation: 43
Okay,

@Satyaveer Arya: Good info.

And, another thing that you could do to really get to the root cause of the issue would be to use strace.

Running something like this could show you what is happening as the process makes any open, close, read or write system calls:
Code:
 ~ $ strace -o <output_file.txt> -e trace=open,close,read,write -p<process ID#>
This will attach strace to the process you give to the -p option. If you want to capture everything that happens when the program runs, you can use this:
Code:
 ~ $ strace -o <output_file.txt> -e trace=all <program executable> [<any args to the program>]
WARNING: Capturing everything can lead to VERY large trace output files!

And, lastly, to capture *just* the process management type calls (e.g. fork, wait, and exec), you can use the following:
Code:
 ~ $ strace -o <output_file.txt> -e trace=process <program executable> [<any args to the program>]
There are many options and ways to use strace to figure out where trouble may lie in the running of a given program, so definitely check man strace to use the other options if you don't find the core issue with my suggestions above.

HTH. Let us know.

Last edited by ShadowCat8; 04-04-2013 at 11:44 AM.
 
Old 04-04-2013, 04:02 PM   #6
khandu
Member
 
Registered: Sep 2003
Posts: 62

Original Poster
Rep: Reputation: 0
Ok.. One more confusion..

I have edited /etc/sysctl.conf to have the following line

Quote:
kernel.core_pattern = /tmp/core.%e.%p
When I execute sysctl -p it changes for the user.. But after reboot for a user if I do
Quote:
$cat /proc/sys/kernel/core_pattern
|/usr/libexec/abrt-hook-ccpp %s %c %p %u %g %t %e
It reverts back.. Although the above line is still in /etc/sysctl.conf..

How do I make this stick for all users.. Don't want to do sysctl -p everytime
 
Old 04-05-2013, 08:28 AM   #7
Satyaveer Arya
Senior Member
 
Registered: May 2010
Location: Dehradun, Uttarakhand, India
Distribution: RHEL, CentOS, Debian, Oracle Solaris 10
Posts: 1,412

Rep: Reputation: 303Reputation: 303Reputation: 303Reputation: 303
khandu,

How did you edit the file? Using sysctl -w command or by opening the sysctl.conf file using any editor?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I dump an abstract syntax tree generated by gcc into a .dot file? asdrubalivan Programming 1 04-03-2013 08:50 PM
Creating a core dump from raw ram dump? cyent Programming 2 08-15-2010 05:57 PM
File generated autimatically in RHEL 3.0 ! shipon_97 Linux - Newbie 1 08-02-2010 09:27 AM
Core dump issues. Program crashes but does not generate core dump file sabeel_ansari Programming 1 10-07-2009 04:23 PM
Core dump in Ubuntu 8.04 (Empty core file) vineet7kumar Linux - Newbie 1 01-17-2009 05:52 PM


All times are GMT -5. The time now is 03:35 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration