Sponsored Content
Top Forums Shell Programming and Scripting Script that will look the same as Cron Post 303037794 by Chubler_XL on Tuesday 13th of August 2019 02:02:07 PM
Old 08-13-2019
Quote:
Originally Posted by meister29
thank you very much sir. i will take note of that. from here i will create my own. thx thx..
Be a little careful how you schedule jobs with this concept, as only one job will run at a time and if another job is due and a long running job hasn't finished yet the other job will not be run. Also if the machine is restarted or you script is killed then the jobs will not be run.

Cron is still your preferred option hear, as all these sort of issues, and others we haven't thought of yet, are dealt with out of the box.
This User Gave Thanks to Chubler_XL For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Cron Script Q

When logged in as root if I type "env" there are a bunch of environment settings including one for CLASSPATH. However, I ran a cron script that ran this command "env > cronEnv". I noticed that the environment variables were entirely different inside the script. There wasn't even a CLASSPATH... (2 Replies)
Discussion started by: doublek321
2 Replies

2. UNIX for Dummies Questions & Answers

Cron + Script = No Output?

I've got an *extremely* simple script I want to run every minute: #!/bin/sh ping -c 1 192.168.1.20 > ~/onlinestatus.txt So, the script is called "status", it's executable, and in the correct path, etc. In a terminal window (I'm using Mac OS X), I can type status, and it will create... (4 Replies)
Discussion started by: jmf77
4 Replies

3. AIX

problem with a script and the cron

hello I use a script to give me the number of users, at each hour. this script read a file where there is the number of users for each hour and for each month (so 12 files per year). If i execute the script (root), it is ok, i have xxx users for each hour. if I put the script in the cron... (1 Reply)
Discussion started by: pascalbout
1 Replies

4. Shell Programming and Scripting

script not working in CRON

guys i have written a very simple script .it runs manually well. but when i put it in cron,it doesn't give the desired output. script looks like this: #! /usr/bin/sh #script for loading data in table using ctl file/Abhijeet K/08.07.2006 /svm_wl1/. .profile cd... (5 Replies)
Discussion started by: abhijeetkul
5 Replies

5. Solaris

Need to cron the script

I want to cron one script which should run every second Thursday (in general Nth occurence of any day) of every month. I am not getting the exact idea of doing this; Please guide. Regards, (3 Replies)
Discussion started by: jaiankur
3 Replies

6. Shell Programming and Scripting

how to run script? call other script? su to another user? make a cron?

Good morning. I am searching for "how-to"'s for some particular questions: 1. How to write a script in HP-UX 11. 2. How to schedule a script. 3. How to "call" scripts from the original script. 4. How to su to another user from within a script. This is the basics of what the... (15 Replies)
Discussion started by: instant000
15 Replies

7. Solaris

Script for cron

Dear All, I have an assignment about collecting /var/adm/messages on each server running Solaris 9. All these servers will be installed with a script that collect all the messages in cron. All the messages will be collected by a single server. I have a script to collect all the messages, but... (2 Replies)
Discussion started by: frankoko
2 Replies

8. Shell Programming and Scripting

cron a script

This has to be the ultimate newbie question... I have a script that works well. To run it, I cut and paste it into a putty session. Is there a way to put the script into a file and just run that file -- like a DOS batch file? I'd like to schedule the file to run daily. Thanks,... (3 Replies)
Discussion started by: landog
3 Replies

9. UNIX for Dummies Questions & Answers

Execution problem with Cron: Script works manually but not w/Cron. Why?

Hello gurus, I am making what I think is a simple db2 call from within a shell script but I am having difficulty producing the desired report when I run the script shown below from a shell script in cron. For example, my script and the crontab file setup is shown below: #!/bin/ksh db2... (3 Replies)
Discussion started by: okonita
3 Replies

10. Shell Programming and Scripting

Script in cron

I have a script that require input from terminal at some point (either a,b or c) How can I cron the script and automatically assume c as the input. (2 Replies)
Discussion started by: aydj
2 Replies
QSTAT(1)						User Contributed Perl Documentation						  QSTAT(1)

NAME
qstat - display job/partition information in a familiar pbs format SYNOPSIS
qstat [-f] [-a|-i|-r] [-n [-1]] [-G|-M] [-u user_list] [-? | --help] [--man] [job_id...] qstat -Q [-f] qstat -q DESCRIPTION
The qstat command displays information about jobs. OPTIONS
-a Displays all jobs in a single-line format. See the STANDARD OUTPUT section for format details. -i Displays information about idle jobs. This includes jobs which are queued or held. -f Displays the full information for each selected job in a multi-line format. See the STANDARD OUTPUT section for format details. -G Display size information in gigabytes. -M Show size information, disk or memory in mega-words. A word is considered to be 8 bytes. -n Displays nodes allocated to a job in addition to the basic information. -1 In combination with -n, the -1 option puts all of the nodes on the same line as the job id. -r Displays information about running jobs. This includes jobs which are running or suspended. -u user_list Display job information for all jobs owned by the specified user(s). The format of user_list is: user_name[,user_name...]. -? | --help brief help message --man full documentation STANDARD OUTPUT
Displaying Job Status If the -a, -i, -f, -r, -u, -n, -G, and -M options are not specified, the brief single-line display format is used. The following items are displayed on a single line, in the specified order, separated by white space: the job id the job name the job owner the cpu time used the job state C - Job is completed after having run E - Job is exiting after having run. H - Job is held. Q - job is queued, eligible to run or routed. R - job is running. T - job is being moved to new location. W - job is waiting for its execution time (-a option) to be reached. S - job is suspended. the queue that the job is in If the -f option is specified, the multi-line display format is used. The output for each job consists of the header line: Job Id: job identifier followed by one line per job attribute of the form: attribute_name = value If any of the options -a, -i, -r, -u, -n, -G or -M are specified, the normal single-line display format is used. The following items are displayed on a single line, in the specified order, separated by white space: the job id the job owner the queue the job is in the job name the session id (if the job is running) the number of nodes requested by the job the number of cpus or tasks requested by the job the amount of memory requested by the job either the cpu time, if specified, or wall time requested by the job, (in hh:mm) the job state The amount of cpu time or wall time used by the job (in hh:mm) EXIT STATUS
On success, qstat will exit with a value of zero. On failure, qstat will exit with a value greater than zero. perl v5.14.2 2012-04-10 QSTAT(1)
All times are GMT -4. The time now is 05:11 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy