Solved

Controlling core file location & name

Posted on 1997-12-12
7
218 Views
Last Modified: 2010-04-21
I have a shell script that starts several processes as
background processes.  Currently when one of them cores it
writes the core file to the same location with the core
filename.  Is there a way to force the core to a particular
directory with a specified name?
0
Comment
Question by:jlargent
[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
  • 3
  • 2
  • 2
7 Comments
 
LVL 84

Expert Comment

by:ozo
ID: 2008281
cd /name1; process1 &
cd /name2; process2 &

0
 

Author Comment

by:jlargent
ID: 2008282
That's ok for a few processes, but in my situation there
are more than 10 and I would rather not have multiple
directories if there is any other way.  Also, the processes
live in a common directory so the cmd would be:
cd /name1; /path/process1 &
cd /name2; /path/process2 &
I'm not sure if the core file would be dumped in the
"name1" directory or the "path" directory.
thanks
0
 

Author Comment

by:jlargent
ID: 2008283
Adjusted points to 200
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 51

Accepted Solution

by:
ahoffmann earned 200 total points
ID: 2008284
core file is in the name1 directory.
You must patch your kernel to satisfy your goal.
Sorry for bad news.
0
 

Author Comment

by:jlargent
ID: 2008285
Is patching the kernal the standard way to handle this?
Has this problem never been addressed by anyone else. Is
really common practise that all core files are created
in one area with the same name (thus overwriting previous
core files)?
0
 
LVL 84

Expert Comment

by:ozo
ID: 2008286
cd /name1; /path/process1 || mv core core1.$$ &

(assuming that process1 doesn't fail other than by core dump)
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 2008287
> Has this problem never been addressed by anyone else.
Well, may be that there are millions of coredumps. But it seems that there is noone who whants to fix them simultaneously :)
My answer or ozo's comment.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

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

Suggested Solutions

Title # Comments Views Activity
how to check for shares on HP-UX 1 75
Unix Question 19 55
unix solaris snoop command 6 138
spectrum scale snapshot  resotre/mount 1 58
Introduction Regular patching is part of a system administrator's tasks. However, many patches require that the system be in single-user mode before they can be installed. A cluster patch in particular can take quite a while to apply if the machineā€¦
Every server (virtual or physical) needs a console: and the console can be provided through hardware directly connected, software for remote connections, local connections, through a KVM, etc. This document explains the different types of consolā€¦
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.
Suggested Courses

737 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