Operating System - HP-UX
1819796 Members
3120 Online
109607 Solutions
New Discussion юеВ

rc codes in /var/adm/cron/log

 
SOLVED
Go to solution

rc codes in /var/adm/cron/log

Is there a list of the rc codes and their definitions? If so, where could I find them?
example: rc=1
3 REPLIES 3
Dan Hetzel
Honored Contributor
Solution

Re: rc codes in /var/adm/cron/log

Hi Rebecca,

File /usr/include/sys/errno.h lists standard C library error codes, although nothing prevents a program to use its own values.


Quite a lot of programs follow the following rule:
rc=0 >> OK
rc=1 >> fault
rc=2 >> Warning


Best regards,

Dan

Everybody knows at least one thing worth sharing -- mailto:dan.hetzel@wildcroft.com
Lasse Knudsen
Esteemed Contributor

Re: rc codes in /var/adm/cron/log

Do you mean exit codes ?

AFAIK:

0=success
1=error
2=N/A (skip)

Is this what you are looking for.
In a world without fences - who needs Gates ?
James R. Ferguson
Acclaimed Contributor

Re: rc codes in /var/adm/cron/log

Rebecca:

In genearal, for any program, zero (0) denotes success and non-zero) values denote a failure of some kind.

Specifically, for cron, from document #HPUXKBRC00001849:

This list is not all inclusive but are generally some of the more common return codes.

rc=101 no at command file
rc=102 (stat(at_cmdfile,&buf)) was true, so stat(2) returned an error
rc=103 if set uid bit off, original owner has given file to someone else
rc=104 bad job open
rc=105 no audit id
rc=106 couldn't set group /user ids, exiting
rc=107 couldn't open stdin
rc=108 no stdin
rc=109 couldn't open tmp as stdin to sh
rc=110 couldn't open output file or /dev/null
rc=111 testing
rc=112 can't exec sh
rc=113 file locking problem
rc=127 can't fork (this might also be return code from the shell)

...JRF...