Sponsored Content
Full Discussion: Cronjob
Top Forums UNIX for Beginners Questions & Answers Cronjob Post 303013925 by MadeInGermany on Friday 2nd of March 2018 04:53:57 AM
Old 03-02-2018
Set it to daily, and let the cron job skip every second time.
Example:
Code:
59 23 * * *  tf=/tmp/tf; if [ -d $tf ]; then rmdir $tf; /path/to/realcronjob; else mkdir $tf; fi

As root the protected /var/run/ is safer than /tmp/.
These 2 Users Gave Thanks to MadeInGermany For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Cronjob

Please can someone help me. I need to set up a cron job to measure CPU usage, Disk I/O and memory usage over a period of 1 minute along with the number of users logged into the system. I also need to send it to another user besides myself every hour. Please can someone help me! Thanks. (4 Replies)
Discussion started by: gerwhelan
4 Replies

2. HP-UX

CronJob

Dear Guru, I have submitted some cronjobs that has been running for quite sometimes. However, today I counter some cronjob did not run. Can you please explain what causes this to happen. Any system setting that limit number of cronjob per minutes to be started, etc? Thanks. Kelly (1 Reply)
Discussion started by: hcng08
1 Replies

3. UNIX for Dummies Questions & Answers

cronjob

hi iam new at unix.iam running a cronjob,which i want to run on the first day of every month at 1AM.this is what i have specified: 00 01 1 * * is this corect? (1 Reply)
Discussion started by: wiz83
1 Replies

4. Solaris

at vs cronjob

HI, What is the differnece between at / con job? thanks in advance. (1 Reply)
Discussion started by: mokkan
1 Replies

5. Shell Programming and Scripting

Cronjob

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)
Discussion started by: MisterKhan
11 Replies

6. AIX

cronjob

Hi, I want to schedule a script on daily basis in morning 8:00 A.M and 5:00 P.M , how can i achieve this, i want the parameter 0 ? * * * what will be the second parameter in my case. Regards (1 Reply)
Discussion started by: maooah
1 Replies

7. UNIX for Dummies Questions & Answers

how to cancel a cronjob if the cronjob still running

hi everyone I'm newbie in this forum hope I can get some help here :) I have a command in crontab that executed every 1 minute sometime this command need more than 1 minute to finish the problem is, the crontab execute this command although it's not finish processing yet and causing the system... (7 Replies)
Discussion started by: 2j4h
7 Replies

8. UNIX for Dummies Questions & Answers

Cronjob help

Hi I am very new to linux. I want to run a cronjob every 15 minutes that checks a directory for files. If the directory contains more than ten files I want it to send an email to me. All I have is this... */15 * * * * ls -l | wc -l | | mail -s "This is just a test" I would... (2 Replies)
Discussion started by: LinuxNewb
2 Replies

9. Shell Programming and Scripting

Cronjob not exexcuting!

I have a script named email_kill.sh which kills the EMAIlL engine process. See the below content: #! /usr/bin/ksh -x PID=`ps -eaf | grep "AREmail" | tail -1 | awk '{print $2}'` echo "$PID" kill -9 "$PID" For this script to execute every hour I made a cronjob: 0... (2 Replies)
Discussion started by: nixhead
2 Replies

10. UNIX for Dummies Questions & Answers

cronjob

Is the cronjob below can run only first wednesday of every month? 30 5 1-7 * 3 command please tell me (3 Replies)
Discussion started by: Anjan1
3 Replies
ECACCESS-FILE-RMDIR(1p) 				User Contributed Perl Documentation				   ECACCESS-FILE-RMDIR(1p)

NAME
ecaccess-file-rmdir - Remove a Directory on the ECaccess File System SYNOPSIS
ecaccess-file-rmdir -version|-help|-manual ecaccess-file-rmdir [-debug] ecaccess-file DESCRIPTION
Allow removing the Directory ecaccess-file on the ECaccess File System. The ecaccess-file is in the form [domain:][/user-id/]path. Please read the "Shell commands -> File Management" section of the "ecaccess" guide for more information on the ECaccess File System. ARGUMENTS
ecaccess-file Then name of the ECaccess Directory to remove. OPTIONS
-version Display version number and exits. -help Print a brief help message and exits. -manual Prints the manual page and exits. -debug Display the SOAP messages exchanged. EXAMPLES
ecaccess-file-rmdir c1a:/c1a/tmp/systems/xyz/test-dir Remove the test-dir Directory in the "/c1a/tmp/systems/xyz" directory on c1a. SEE ALSO
ecaccess-file-delete, ecaccess-file-get, ecaccess-file-mget, ecaccess-file-modtime, ecaccess-file-mput, ecaccess-file-chmod, ecaccess-file- copy, ecaccess-file-dir, ecaccess-file-mdelete, ecaccess-file-mkdir, ecaccess-file-move, ecaccess-file-put, ecaccess-file-size and ecaccess. perl v5.14.2 2012-04-16 ECACCESS-FILE-RMDIR(1p)
All times are GMT -4. The time now is 04:22 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy