10-20-2016
Do you want to "pause" the 2nd invocation of your script if an earlier invocation is still running, or do you want to exit? If you're running a script every 5 minutes that takes more than 5 minutes to run, it would seem that pausing could lead to a large backlog of paused scripts at the end of the day.
You can use ps and grep -c to count the number of times a script is running, but note that you might never reach the condition to escape the paused mode if you ever get to the point where you have one active and two paused copies of your scripts.
You can use a lock file to guarantee that only one script is running at a time. But, if you have more than one paused script, there is no way to specify that multiple paused scripts will acquire the lock in the same order in which the paused processes originally started (if that matters). You could add logic to your code to enforce an execution order if that matters to you.
Both of the above suggestions have been discussed in several threads in this forum before.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi
I want to execute a script on the last day of every month.
I tried using the following line but it failed:
50 23 * * * && cd live/cgi-bin/;perl org_stats_monthly_cron_job.cgi
log shows:
CMD:
Its a Solaris box.
Could someone please help me out?
Thanks in advance. (3 Replies)
Discussion started by: tom123
3 Replies
2. UNIX for Advanced & Expert Users
Hi,
Anyone please let me know how to add an entry for crontab while there are few of entries already in.
When I execute crontab -e, the entries which are added already are displayed. But, I need to add one more entry to the crontab and then after that I need to remove the entry without... (1 Reply)
Discussion started by: minar
1 Replies
3. UNIX for Dummies Questions & Answers
can anybody explain the usage of CRON for adding a cron job. please provide an example also for better understanding !!!
Thanks (1 Reply)
Discussion started by: skyineyes
1 Replies
4. Solaris
hi,
how i woulsd be able to find that my cron job is running or not..
E.g abc (2 Replies)
Discussion started by: sam.whocares
2 Replies
5. Solaris
I run cron in solaris 10 zone. One cron job which syncing files to nfs mounted on container, creates after finishing another cron proccess(/usr/sbin/cron), and after 100 existing cron proccesses next cron job will not start. It's too weird for me, I'm not able to solve this problem. Theoretically... (3 Replies)
Discussion started by: ron76
3 Replies
6. Shell Programming and Scripting
hi,
i have set a cron job to run build in one of the env. it shud basically stop the server,deploy the code and start the server. while starting the server the logs are getting created with the cron account id and not the normal user because of which the server is not coming up. can you please... (4 Replies)
Discussion started by: suryans
4 Replies
7. Solaris
Hi ,
I have removed a cron for particular user , but cron job seems to be running even after the cron entry is removed. The purpose of the cron was to sendmail to user ( it uses mailx utility )
I have restarted cron and sendmail service still user is getting mail alerts from the cron job. And... (4 Replies)
Discussion started by: chidori
4 Replies
8. Shell Programming and Scripting
Hi
I have a requirement to write a shell script,that will check the all commented job in cron job.Please help !! (2 Replies)
Discussion started by: netdbaind
2 Replies
9. Red Hat
Hi everybody,
We have a script which fetch the data from db. Below is the scenario where in the script has to be run by cron.
Schedule script to run every minute from 5min-59min in the first hour of the day and then 0-59 for every other hour.
Please let me know if any info required.
... (3 Replies)
Discussion started by: mastansaheb
3 Replies
10. Shell Programming and Scripting
Hi,
1)
If some job supposed to run on 1st of every month at 7 AM
In cron job when we have a blackout on the 1st ( i.e when 1st falls on a sunday ) how can we make the job run the next business day?
2) How can we run a job on 25th of every quarter 7 AM(jan,apr,jul,oct)
And if 25th... (5 Replies)
Discussion started by: System Admin 77
5 Replies
LEARN ABOUT SUSE
tracker-status-icon
tracker-status-icon(1) User Commands tracker-status-icon(1)
NAME
tracker-status-icon - Miner status and control notification area icon
SYNOPSIS
tracker-status-icon
DESCRIPTION
tracker-status-icon is a tracker-store(1) notification area icon meant to provide a fast way to check the status of Tracker's data miner
and to be able to control those miners with simple commands like pause and resume.
When clicking on the icon, a list of data miners is presented. In this list there is an image to the left which indicates the paused or
non-paused state. There is also a progress bar which indicates how far through the work load the data miner is.
Each miner can be paused/resumed by clicking on it in the menu.
From the context menu, tracker-status-icon allows the user to configure the preferences of tracker-miner-fs using the tracker-preferences
application.
OPTIONS
-?, --help
Show summary of options.
-V, --version
Print version.
FILES
$HOME/.config/tracker/tracker-status-icon.cfg
SEE ALSO
tracker-status-icon.cfg(5), tracker-search-tool(1), tracker-preferences(1), tracker-store(1).
GNU
September 2009 tracker-status-icon(1)