LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
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
  Search this Thread
Old 06-26-2009, 09:41 AM   #1
felbvts
Member
 
Registered: Mar 2009
Posts: 38

Rep: Reputation: 3
How do I redirect core dumps?


Hello,

I am running a RHEL 5.3 server with a gig of free space in root.
I would like to redirect core dumps to another filesystem on my server. I have searched and cannot find a solution that works. ( i have seen that I should alter /proc/sys/kernel - I am not able to write to the file.) Any suggests are welcome.

Thanks in advance.
Jennifer
 
Old 06-26-2009, 09:57 AM   #2
colucix
LQ Guru
 
Registered: Sep 2003
Location: Bologna
Distribution: CentOS 6.5 OpenSuSE 12.3
Posts: 10,509

Rep: Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983Reputation: 1983
You have to be root to do that. Just specify the path in this way:
Code:
echo "/path/to/some/dir/core" > /proc/sys/kernel/core_pattern
To keep this behavior after a reboot you have to add the following lines to /etc/sysctl.conf:
Code:
# Setup a directory to save core files into
kernel.core_pattern = /path/to/some/dir/core
The first line is not really necessary, just a comment to keep track of the modification.
 
Old 06-29-2009, 01:40 AM   #3
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
Actually, you use the netdump tools as provided by RH : http://kbase.redhat.com/faq/docs/DOC-6913
 
Old 06-29-2009, 08:31 AM   #4
felbvts
Member
 
Registered: Mar 2009
Posts: 38

Original Poster
Rep: Reputation: 3
Thank you! colucix and chrism01

I will give it a try.....


Although I'm not sure netdump is appropriate in this case. The app team is generating the core dumps to debug a problem. I thought netdump was primarily for the OS - I am I wrong?
 
Old 06-29-2009, 11:17 PM   #5
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
Yeah, that's true; its primarily for the kernel. Might also be usable for others, not sure.
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
RPM Dumps Core chingkhuba Red Hat 6 04-15-2009 02:03 AM
Core dumps amitktd Solaris / OpenSolaris 2 05-31-2007 12:39 AM
Turning on Core dumps lostinvietnam Linux - Kernel 3 02-09-2007 01:15 AM
Ps dumps core in linux 2.4.22 rbecker Linux - General 2 01-04-2006 11:43 AM
Reading Core Dumps bru Linux - General 3 05-07-2004 07:19 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

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

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration