CRON(8) System Manager's Manual CRON(8)NAME
cron - clock daemon
SYNOPSIS
/etc/cron
DESCRIPTION
Cron executes commands at specified dates and times according to the instructions in the file /usr/lib/crontab. Since cron never exits, it
should only be executed once. This is best done by running cron from the initialization process through the file /etc/rc; see init(8).
Crontab consists of lines of six fields each. The fields are separated by spaces or tabs. The first five are integer patterns to specify
the minute (0-59), hour (0-23), day of the month (1-31), month of the year (1-12), and day of the week (1-7 with 1=monday). Each of these
patterns may contain a number in the range above; two numbers separated by a minus meaning a range inclusive; a list of numbers separated
by commas meaning any of the numbers; or an asterisk meaning all legal values. The sixth field is a string that is executed by the Shell
at the specified times. A percent character in this field is translated to a new-line character. Only the first line (up to a % or end of
line) of the command field is executed by the Shell. The other lines are made available to the command as standard input.
Crontab is examined by cron every minute.
FILES
/usr/lib/crontab
CRON(8)
Check Out this Related Man Page
CRON(8) System Manager's Manual CRON(8)NAME
cron - clock daemon
SYNOPSIS
auth/cron [-c]
DESCRIPTION
Cron executes commands at specified dates and times according to instructions in the files /cron/user/cron. It runs only on an authentica-
tion server. Option -c causes cron to create /cron/user and /cron/user/cron for the current user; it can be run from any Plan 9 machine.
Blank lines and lines beginning with # in these files are ignored. Entries are lines with fields
minute hour day month weekday host command
Command is a string, which may contain spaces, that is passed to an rc(1) running on host for execution. The first five fields are integer
patterns for
minute 0-59
hour 0-23
day of month 1-31
month of year 1-12
day of week 0-6; 0=Sunday
The syntax for these patterns is
time : '*'
| range
range : number
| number '-' number
| range ',' range
Each number must be in the appropriate range. Hyphens specify inclusive ranges of valid times; commas specify lists of valid time ranges.
To run the job, cron calls host and authenticates remote execution, equivalent to running rx host command (see con(1)). The user's profile
is run with $service set to rx.
Cron is not a reliable service. It skips commands if it cannot reach host within two minutes, or if the cron daemon is not running at the
appropriate time.
EXAMPLES
Here is the job that mails system news.
% cat /cron/upas/cron
# send system news
15 8-17, 21 *** helix /mail/lib/mailnews
%
SOURCE
/sys/src/cmd/auth/cron.c
SEE ALSO con(1), rc(1)CRON(8)
Dear Folks,
i am new to hp-ux, i have a problem scheduling the crontab,
The script is working fine at command prompt, but not working at cron, please find a solution for it ,
here are the logs and my schedule at cron:
log after restarting crontab /var/adm/cron/log
! *** cron started *** ... (11 Replies)
Simple script that removed some files successfully as script sh -x
But not working in crontab, however it fires and writes log files even some count of the files
I set all env and user interaction
The crontab runs in the same user where the files are there.
Script:
## Set the... (11 Replies)
I scheduled a cron job to run @ 1:00 as follows ,
00 01 * * * /app/cbf/CLIF/version-1.0.0.0/scripts/archival.sh
Please find the archival.sh script.
But cron is throwing a mail stating sqlplus command not found
So can anybody suggest what might be the problem ??? (13 Replies)
Hello All,
In SunOS 10, I have some cron jobs and it is running fine but the cron job outputs are not mailing to any acount of the system.
In other OS, we have option like MAILTO variable or /dev/null to disable but in Sun I have no idea how it is disabled by default and how do I... (13 Replies)
I am using Solaris 9. I wish to run my script every 1 minute inteval. Though i can run it using below entry in crontab.
* * * * /export/home/username/script/file_exist_&_run.sh
in short above script will check whether a specific file exist in a directory. If it found it will inovke another... (10 Replies)
Hi,
I'm totally new to shell scripting. I need help in my crontab script. I'm trying to read some values from user (username, log file directory, server) and then use those value to create a crontab for log rotation after some interval of time.
creating crontabs manually isn't big deal.... (11 Replies)
I need to write the cron job for the following scenario, Please help me out
The CRON job runs sometime at night on Saturday and checks if there are more than eight files in the /PROCESSED folder. Any files over and above eight are deleted based on ascending order of date (eight most recent... (10 Replies)
Hi,
I am programming a Western Digital ShareSpace network disk system.
I installed a cron from ipkg. (explained here: mybookworld.wikidot.com/sharespace ShareSpace - Hacking WD MyBook World Ed)
Cron runs:
/etc $ ps -fe | grep cron
6082 root 616 S < /opt/sbin/cron
18635 root ... (15 Replies)
Hi guys. This is my first post so bear with me.
I'm trying to get cron to run a shell script in my home directory (/home/server) that checks the temperature of my HDD. The script works fine, however I can't run it in cron. I've checked the syslog and I have only seen two errors:
- Exited with... (11 Replies)
Hi,
I wanted to grep string "ERROR" and "WORNING" after last occurrence of String "Starting" only and wanted to display two lines after searched ERROR and WORNING string and one line before. I have following cronjob log file "errorlog" file and I have written the code for same in Unix as below... (17 Replies)
Hello everybody ,
I launched cron to execute a task every hour but the job takes more than hour that's why I'm getting more than 1000 cron processes running at the same time !!!
My question is how to tell cron not to execute unless the job terminated in order to have only one process running .... (14 Replies)
hi all,
I created a sh script to import some tables from mysql to hive.
No problem launching it manually, but if I schedule via crontab it returns me an error in the following part:
#create an array containing all the tables for $dbname
query="SELECT table_name FROM information_schema.tables'... (10 Replies)
Team,
Hope you all are doing fine
I have one admin server which is being used dedicately to run cron jobs on hourly basis, fetching the details from Database which is in a different server.These cronjob are run on every hourly/5 minutes basis depending as per end user requirement.The script... (12 Replies)
Hi All,.
need your expertise, is there a way to create a script that will run with specific time without using cron. because i dont have access in cron.
TIA (19 Replies)