- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - OpenVMS
- >
- Re: Batch job completes before start time?
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 06:36 AM
тАО07-30-2007 06:36 AM
$ submit/noid/que=sys$batch/log=sys_log:g_sub_eod.log /nonoti/noprin/parameters=('env')/after="tomorrow+07:00:00" sys_com:g_sub_eod.com
The entry in the queue indicates a 7am start.
Entry Jobname Username Blocks Status
----- ------- -------- ------ ------
156 G_SUB_EOD XXXXXX Holding until 31-JUL-2007 07:00:00
On idle batch queue XXX$BATCH
Submitted 30-JUL-2007 07:00:00.27 /KEEP /LOG=DSA102:[XXXXXX.][NEWS.PROD.LOG]G_SUB_EOD.LOG; /PARAM=("PROD") /NOPRINT /PRIORITY=100
File: _DSA102:[XXXXXX.NEWS.PROD.COM]G_SUB_EOD.COM;8
The mod and creation times on the last few logs shows
G_SUB_EOD.LOG;1008 30-JUL-2007 06:57:43.68 30-JUL-2007 06:57:47.62
G_SUB_EOD.LOG;1007 29-JUL-2007 06:57:44.54 29-JUL-2007 06:57:48.33
G_SUB_EOD.LOG;1006 28-JUL-2007 06:57:45.44 28-JUL-2007 06:57:48.97
G_SUB_EOD.LOG;1005 27-JUL-2007 06:57:46.31 27-JUL-2007 06:57:50.05
Inside the logs the termination time
XXXXXX job terminated at 30-JUL-2007 06:57:47.61
Is there something simple I am missing? Have you had this issue before? Any help is appreciated. The 3 mins early is causing a problem with their calculations.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 06:44 AM
тАО07-30-2007 06:44 AM
Re: Batch job completes before start time?
Andy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 07:11 AM
тАО07-30-2007 07:11 AM
Re: Batch job completes before start time?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 07:25 AM
тАО07-30-2007 07:25 AM
Re: Batch job completes before start time?
I concur with Andy. Has the time been checked on all members of the cluster?
- Bob Gezelter, http://www.rlgsc.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 07:40 AM
тАО07-30-2007 07:40 AM
Re: Batch job completes before start time?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 07:59 AM
тАО07-30-2007 07:59 AM
Re: Batch job completes before start time?
The 3 mins early is causing a problem with their calculations."
------------------------
The correct thing to do is to make sure your clocks are synchronized.
The simple fix if they want to make sure the job does not start before the local clock has reached 7:00, is to pass the next run time as one of the parameters, and when it starts to run, have the job wait until that time.
For example:
Add "$ wait "''p2'" to beginning of g_sub_eod.com
Do something like to following to get time of next run.
$ this_proc = f$environment("procedure")
$! if you want latest version instead of current version
$ this_proc = f$element(0,";",this_proc) ! assumes ";" only valid as version seperator
$ next_run = f$cvtime("TOMORROW+07:00:00","ABSOLUTE")
$ submit 'this_proc'/noid/que=sys$batch/log=sys_log:g_sub_eod.log /nonoti/noprin/parameters=('env',"''next_run'")/after="''next_run'"
NOTE WELL: This is using an undocumented behaviour of wait, specifically waiting for an absolute time. For this to work, you must pass 2 parameters, with a space between the date and the time.
I.e.
$ wait 30-JUL-2007 15:40:00.00 ! trailing digits are significant, if omitted, the fields from the current time will be used.
This does not solve the problem of the job starting 3 minutes late, if the node running the queue manager is 3 minutes slower than the clock on which the job runs.
Here's an example using wait in the undocumented fashion.
In these examples, I typed show time into the typeahead buffer while the wait was in progress.
$ wait 30-jul-2007:15:35 ! the blank between date and time is required.
%DCL-W-IVDTIME, invalid delta time - use DDDD-HH:MM:SS.CC format
\0 30-JUL-2007:15:35\
$ wait 30-jul-2007 15:35 ! entered at 15:34:24
SIGMA::JON 15:34:35 (DCL) CPU=00:01:50.92 PF=50635 IO=345965 MEM=268
SIGMA::JON 15:34:44 (DCL) CPU=00:01:50.92 PF=50635 IO=345966 MEM=268
SIGMA::JON 15:34:55 (DCL) CPU=00:01:50.92 PF=50635 IO=345967 MEM=268
SIGMA::JON 15:35:16 (DCL) CPU=00:01:50.92 PF=50635 IO=345968 MEM=268
$ show time
30-JUL-2007 15:35:24
$ wait 30-jul-2007 15:36:00.00
$
SIGMA::JON 15:36:39 (DCL) CPU=00:01:50.93 PF=50636 IO=345979 MEM=269
$ wait 30-jul-2007 15:37:00.00
$ show time
30-JUL-2007 15:37:00
$
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 08:00 AM
тАО07-30-2007 08:00 AM
Re: Batch job completes before start time?
Do an occasional (every couple of months?):
$ mcr sysman set env/cluster
SYSMAN> config set time hh:mm:ss
using some reliable time source to keep 'em close.
Cheers,
Art
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 08:46 AM
тАО07-30-2007 08:46 AM
SolutionI've also seen an (older) recommendation to add a WAIT in sylogin.com for batch jobs or to use a "set time" job to keep cluster time.
Andy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 07:48 PM
тАО07-30-2007 07:48 PM
Re: Batch job completes before start time?
We think it was due to DTSS that is/was used.
We added a wait 00:00:00:10 to sylogin to solve the problem.
Don't have that problem on 7.3 anymore (or is our sylogin or vms7.3 login procedure in geberal heavier than on 6.2 ?
Fwiw
Wim
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 10:25 PM
тАО07-30-2007 10:25 PM
Re: Batch job completes before start time?
Interesting undocumented behavior of WAIT (probably a direct corelation with SYS$SETIMR).
Mike,
Have the system times sinchronized is the better way to solve the problem.
If the time is not sinchronized you can probably put at the begining of the command procedure a line like this (using the undocumented wait behavior):
$ WAIT 'F$GETQUI("DISPLAY_JOB","AFTER_TIME",,"THIS_JOB")'
or without the undocumented behavior:
$ START_TIME = F$GETQUI ("DISPLAY_JOB","AFTER_TIME",,"THIS_JOB")
$ NOW = F$TIME()
$ IF F$CVTIME(START_TIME).GES.F$CVTIME(NOW) THEN GOTO DONE
$ WAIT 'F$DELTA_TIME(START_TIME,NOW)'
$DONE:
Bojan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-30-2007 11:33 PM
тАО07-30-2007 11:33 PM
Re: Batch job completes before start time?
I submitted 20 jobs and compared accounting with the schedule date. They all started 0.15 sec BEFORE the scheduled date.
Even after removal of login.com they got at the point of the first script line 0.06 sec AFTER the scheduled time. And logout said that they had been active for 0.06 sec (not 0.06 + 0.15).
Same test on AS 500 but sylogin and login removed. They all started about 0.02 sec after the scheduled time (in accounting) and needed 0.14 sec to get to the first statement.
Fwiw
Wim
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-31-2007 01:23 AM
тАО07-31-2007 01:23 AM
Re: Batch job completes before start time?
Batch queues and the queue manager is and has been a comparatively course mechanism, entirely manual/local set-up and management, and less than easy to deal with failures.
Here are links to cron and Kronos: http://64.223.189.234/node/97
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-31-2007 05:12 AM
тАО07-31-2007 05:12 AM
Re: Batch job completes before start time?
midnight and I'd have it wait several minutes before resubmitting, so it would
not run twice on the cluster. btw nice
to know the wait feature! implies wait until xxx. nice! Dean
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-31-2007 05:23 AM
тАО07-31-2007 05:23 AM