Sponsored Content
Full Discussion: Core file location
Operating Systems HP-UX Core file location Post 302672439 by mohtashims on Monday 16th of July 2012 11:04:06 AM
Old 07-16-2012
Question Core file location

Hi,
Regarding core dump on HP-UX.

Code:
 
more /etc/rc.config.d/savecrash
#!/sbin/sh
# @(#) $Revision: 80.1 $
# Savecrash configuration
#
#
# SAVECRASH:    Set to 0 to disable saving system crash dumps.
SAVECRASH=1

# SAVECRASH_DIR:Directory name for system crash dumps.  Note: the filesystem
#               in which this directory is located should have as much free
#               space as your system has RAM.
SAVECRASH_DIR=/var/adm/crash
#SAVECRASH_DIR=/tmp

# CHUNK_SIZE:   size of single crash image file (i.e. how big you want
#               each of image.n.x, image.n.x+1, etc. to be)
#               If not specified, savecrash will choose one based on the
#               physical memory size of the system. Can be specified in
....
.....
......

Why does my HPUX then generate the core file @ some strange location and not in the startup script directory for that process nor in "SAVECRASH_DIR=/var/adm/crash" ?
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

copy files from one location to similar location

I need help in forming a script to copy files from one location which has a sub directory structure to another location with similar sub directory structure, say location 1, /home/rick/tmp_files/1-12/00-25/ here 1-12 are the number of sub directories under tmp_files and 00-25 are sub... (1 Reply)
Discussion started by: pharos467
1 Replies

2. Shell Programming and Scripting

Bash copy file contents into an existing file at a specific location

Hi all I need to copy the entire contents of one file into an existing file at a specific location. I know the exact line number where I need to put it. It appears I would use either sed or awk to do this, but I have been unsuccessful so far: File A line 1 line 2 line 3 line 4 ... (6 Replies)
Discussion started by: gshepherd7
6 Replies

3. Shell Programming and Scripting

Put one string from one location to another location in a file

Hi Everyone, I have 1.txt here a b c' funny"yes"; d e The finally output is: here a b c d e' funny"yes"; (1 Reply)
Discussion started by: jimmy_y
1 Replies

4. Shell Programming and Scripting

Shell Script for Copy files from one location to another location

Create a script that copies files from one specified directory to another specified directory, in the order they were created in the original directory between specified times. Copy the files at a specified interval. (2 Replies)
Discussion started by: allways4u21
2 Replies

5. Shell Programming and Scripting

File created in a different location instead of desired location on using crontab

Hi, I am logging to a linux server through a user "user1" in /home directory. There is a script in a directory in 'root' for which all permissions are available including the directory. This script when executed creates a file in the directory. When the script is added to crontab, on... (1 Reply)
Discussion started by: archana.n
1 Replies

6. Shell Programming and Scripting

How to copy a file from one location to another location?

I have file file1.txt in location 'loc1'. Now i want a copy of this file in location 'loc2' with a new file called test.txt. Please help me how to do this in shell script. (1 Reply)
Discussion started by: vel4ever
1 Replies

7. Shell Programming and Scripting

How to find a existing file location and directory location in Solaris box?

Hi This is my third past and very impressed with previous post replies Hoping the same for below query How to find a existing file location and directory location in solaris box (1 Reply)
Discussion started by: buzzme
1 Replies

8. Shell Programming and Scripting

Help with copying the list of files from one location to other location

A) I would like to achive following actions using shell script. can someone help me with writing the shell script 1) Go to some dir ( say /xyz/logs ) and then perform find operation in this dir and list of subdir using find . -name "*" -print | xargs grep -li 1367A49001CP0162 >... (1 Reply)
Discussion started by: GG2
1 Replies

9. Shell Programming and Scripting

Shell script to read specified value from file and echo to the same location to other file.

Hello. I want to to backup some "default:" values from a file do some other job and after restore that "default:" values back. The problem is that the source and destination file has a lot of default: strings in it but with different values... So.. Here is an example: A part of my source... (6 Replies)
Discussion started by: ausdim
6 Replies

10. Shell Programming and Scripting

Curl to download file from subdivx.com after following location without knowing the file name/extens

This question could be specific to the site subdivx.com In the past, I've been able to download a file following location using cURL but there is something about subdivx.com that's different and can't figure out how to get it to work. I tried the following directly in the terminal with no... (5 Replies)
Discussion started by: MoonD
5 Replies
savecrash(1M)															     savecrash(1M)

NAME
savecrash - save a crash dump of the operating system SYNOPSIS
dumpdevice offset] sysfile] minfree] chunksize] tapedevice] [dirname] DESCRIPTION
saves the crash dump information of the system (assuming one was made when the system crashed) and writes a reboot message in the shutdown log file. dirname is the name of the existing directory in which to store the crash dump; the default is saves the crash image and related files in the directory The trailing n in the directory name is a number that increases by one every time is run with the same dirname. This number is kept in the file which is created if it does not already exist. Usually, creates the file in the crash directory from the crash dump header, copies all kernel modules that were loaded in memory at the time of the crash, and copies all dump device contents into crash image files. When writes out a crash dump directory, it checks the space available on the file system containing dirname. will not use that portion of the file system space which is reserved for the superuser. Additional space on the file system can be reserved for other uses with min- free, where minfree is the amount of additional space to reserve. This option is useful for ensuring enough file system space for normal system activities after a panic. If there is insufficient space in the file system for the portions of the crash dump that need to be saved, will save as much as will fit in the available space. (Priority is given to the index file, then to the kernel module files, and then to the physical memory image.) The dump will be considered saved, and will not attempt to save it again, unless there was insufficient space for any of the physical mem- ory image. (See the description of option also writes a reboot message in the shutdown log file if one exists. (If a shutdown log file does not exist, does not create one.) If the system crashes as a result of a kernel panic, also records the panic string in the shutdown log. By default, when the primary paging device is not used as one of the dump devices or after the crash image on the primary paging device has been saved, runs in the background. This reduces system boot-up time by allowing the system to be run with only the primary paging device. It is possible for dump devices to be used also as paging devices. If determines that a dump device is already enabled for paging, and that paging activity has already taken place on that device, a warning message will indicate that the dump may be invalid. If a dump device has not already been enabled for paging, prevents paging from being enabled to the device by creating the file does not enable the device for paging if the device is locked in (see swapon(1M) for more details). As finishes saving the image from each dump device, it updates the file and optionally executes to enable paging on the device. Options and Operands The command recognizes the following options and operands. dirname The name of the existing directory in which to store the crash dump; the default is Mark the dump in the dump device as saved, without performing any other action. The option is useful for manually inhibiting dump actions called by Run in the foreground only. By default, runs in the background when the primary paging device does not contain an unsaved portion of the crash image. Turning this option on increases system boot-up time, but guarantees that the dump has been saved when control returns to the caller. Logs the panic information to as described above, but does not actually save the dump. The dump is marked as saved so that future invocations of do not create duplicate log entries. Only preserves swap-endangered dump device contents into crash image files. Swap-endangered dump devices are those devices that are also configured as swap devices by the system. If all dump devices are configured as swap devices, the entire dump will be preserved in the crash directory. If no swap devices are used as dump devices (dedicated dump devices), only the file and kernel modules will be copied into the crash directory. Resaves a dump that a previous invocation of has marked as already saved. This is useful if the first invocation did ran out of space, and enough space has since been freed to try again. Enables additional progress messages and diagnostics. will compress all physical memory image files and kernel module files in the dump directory. This option is ignored if the dump image on the dump device is already compressed. See crashconf(2). In this case, a warning message will be printed. will not compress any files in the dump directory. If neither nor is specified and the amount of free disk space is less than the total dump size, will compress the image files. dumpdevice is the name of the device containing the header of the raw crash image. The console messages from the time of the panic will iden- tify the major and minor numbers of this device. This option, in combination with can be used to tell where to find the dump in the rare instances that doesn't know where to look. offset is the offset in kBytes, relative to the beginning of the device specified with above, of the header of the raw crash image. The console messages from the time of the panic will identify this offset. This option, in combination with can be used to tell where to find the dump in the rare instances that doesn't know where to look. sysfile is the name of a file containing the image of the system that produced the core dump (that is, the system running when the crash occurred). If this option is not specified, gets the file name from the dump itself. If the file containing the image of the sys- tem that caused the crash has changed, use this option to specify the new file name. minfree is the amount of free space (in kBytes) that must be available for ordinary user files in the file system into which the dump will be saved, in addition to space reserved for the superuser. If necessary, only part of the dump will be saved to achieve this requirement. calculates the amount of disk space available when it starts saving the dump. Any space used by other processes while dump is being saved is not taken into account. minfree may be specified in bytes kilobytes megabytes or gigabytes The default minfree value is zero, and the default unit is kilo- bytes. chunksize is the size (default kBytes) of a single physical memory image file before compression. The kByte value must be a multiple of page size (divisible by 4) and between 64 and 1048576. chunksize may be specified in units of bytes kilobytes megabytes or gigabytes Larger numbers increase compression efficiency at the expense of both time and debugging time. If is not specified, a default is chosen based on the physical memory size and the amount of available file system space. If the dump image on the dump device is compressed, then the chunksize specification is only used as a size limit for the images copied into the file system. See crash- conf(2). If the size specified is smaller than the chunk size used for compression while dumping, then a warning message will be printed and the compression chunk size used by the dump will be used to create the file system images. tapedevice is the tape device where the crash dump will be written. Crash dumps that are written to tape are written using a format. The crash dump tape can be read using tar(1). When the option is specified, the option is not allowed and the whole dump is always preserved. In addition, and are not allowed and is ignored. Also, when is specified, will not perform any compression. When dirname is specified with the option, dirname is the name of the existing directory where the file is created; the default directory is The file is the first file that is written out to the dump tape. This file is written a second time once all the dump files have been written. The first copy of the file only contains crash dump header information and its filename on tape is It does not contain information for the module and image files. When writing to tape, the tape device must be online otherwise the command will fail with an error. Additionally, when reaches end-of-tape, it will prompt the user for the next tape. Any tape errors encountered will result in a generic tape error. Defines the interaction between and opt can be one of the following values: Do not run from (default) Call each time finishes saving the image from each dump device. This option provides the most efficient use of paging space. Only call when finishes saving the image file from all dump devices. If this option is used, no additional paging space other than the primary paging space is available until the complete crash dump image is saved. This option provides a second chance to retrieve the crash image if fails on first attempt. For compatibility with earlier syntax, the values of and can be used in place of and respectively. This usage is obsolescent. RETURN VALUE
Upon exit, returns the following values: A crash dump was found and saved, or has preserved dump information from the primary swap device and is continuing to run in the background to complete its tasks. A crash dump could not be saved due to an error. No crash dump was found to save. A partial crash dump was saved, but there was insufficient space to preserve the complete dump. The savecrash process continued in the background, see the file for actual results. WARNINGS
relies on the expectation that device numbers have the same meaning (point to the same devices) at the time the system dumps and at the time the dump is saved. If, after a crash, the system was booted from a different boot device in order to run it is possible that this expectation will not be met. If so, may save an incomplete or incorrect dump or may fail to save a dump at all. Such cases cannot be reliably detected, so there may be no warning or error message. If encounters an error while running in the background (such as running out of space), it will not be easily detectable by the caller. If the caller must ensure that the operation was successful, for example before writing to a dump device, the caller should specify to force to run in the foreground, and should then examine the exit status of the process when it finishes. AUTHOR
was developed by HP and the University of California, Berkeley. FILES
shutdown log savecrash startup configuration file savecrash startup file crash dump number default kernel image saved by savecrash SEE ALSO
adb(1), tar(1), crashutil(1M), crashconf(1M), swapon(1M). savecrash(1M)
All times are GMT -4. The time now is 10:05 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy