Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Does VMS have a facility like unix's cron?

63 views
Skip to first unread message

George ZAMROZ

unread,
Jun 27, 1993, 7:42:57 PM6/27/93
to
UNIX have a facility called cron, which allows commands to be at regular times
without having to hold them on queues. Does VMS have anything similar?

-------------------------------------------------------------------------------
George Zamroz, BHP Information Technology, Wollongong Region, Australia.
Address: wezamg%devax...@itwol.bhp.com.au (or)
wez...@itwol.bhp.com.au (or)
george.g...@bhpmelmsm.bhp.bhpmel04.telememo.au

Bob Koehler

unread,
Jun 28, 1993, 9:51:00 AM6/28/93
to
In article <1993Jun28....@iwsd01.itwol.bhp.com.au>, WEZ...@itwol.bhp.com.au (George ZAMROZ) writes...

>UNIX have a facility called cron, which allows commands to be at regular times
>without having to hold them on queues. Does VMS have anything similar?
>

There is a PD cron for VMS. The pertinent difference between puuting something
in a queue or putting it in a crontab escapes me. I wish I had real queues on
my UNIX machines.

(I wish I had no UNIX machines.)

------------------------------------------------------------------------------
Bob Koehler | Any illusion to these opinions being other
rkoe...@author.gsfc.nasa.gov | than just mine alone is just that.

If its too loud, You're too old

unread,
Jun 28, 1993, 10:02:21 AM6/28/93
to

Check with the following person if you want cron for VMS.

> Ulli 'Framstag' Horlacher \ psi%(0262)45050260103::orakel
> Student consultant VAX/VMS and networks \ ora...@dulruu51.bitnet
> Rechenzentrum Universitaet Ulm Germany \ ora...@rz.uni-ulm.de


al


Al Lilianstrom
Fermi National Accelerator Laboratory
Batavia, Illinois
lilia...@fnal.gov

My opinion. Not the DOE's, URA's, or anyone else at Fermilab

Mighty Firebreather

unread,
Jun 28, 1993, 9:33:49 AM6/28/93
to
WEZ...@itwol.bhp.com.au (George ZAMROZ) writes:

>UNIX have a facility called cron, which allows commands to be at regular times
>without having to hold them on queues. Does VMS have anything similar?
>

No. VMS does not have such a facility as part of the system.
There is at least one public domain version available. It's on the Spring
1988 L&T Sig tape. Maybe somebody could make it available for anonymous
FTP.

I simply use a batch job that resubmits itself with the /AFTER
qualifier.


*************************************************************************
* Here, there be dragons! *
* dra...@nscvax.princeton.edu *
* *
* I'm job hunting. Any offers or leads will be appreciated. *
* Thanks! *
* Richard B. Gilbert *
*************************************************************************

Neil Readwin

unread,
Jun 28, 1993, 10:55:10 AM6/28/93
to
rkoe...@author.gsfc.nasa.gov (Bob Koehler) writes:
|> There is a PD cron for VMS. The pertinent difference between puuting
|> something in a queue or putting it in a crontab escapes me.

A crontab entry gets re-executed at the specified times. Adding the cruft
to do this in a VMS batch job is tedious and error prone. In some cases it
is also quite difficult - quick, how do you resubmit a batch job on every
Friday, and also on the 1st, 19th and 31st of each month (if that day
exists). I could knock up some DCL that would do it, but it wouldn't be
fun.

|> I wish I had real queues on my UNIX machines.

Me too. I also wish my VMS machines had cron. The two are very different.
Something tells me that if DEC shipped a cron for VMS it would be a monster
that would allow you do adjust every conceivable parameter and SUBMIT
qualified for each batch job. Handy for those shops that have 300 generic
and execution batch queues spread over a bunch of high-end VAXen, but
massive overkill for the Unix hacker who just wants to run a script each
night and gets handed a 300 page manual when he asks how to do it :-\

Neil.
--
Phone: +44 71 815 5283 E-mail: nrea...@micrognosis.co.uk
Anything is a cause for sorrow that my mind or body has made

Dick Munroe

unread,
Jun 28, 1993, 12:46:02 PM6/28/93
to
In article <0096EB1F.CB...@nscvax.princeton.edu>, Mighty Firebreather <dra...@nscvax.princeton.edu> writes:
> No. VMS does not have such a facility as part of the system.
> There is at least one public domain version available. It's on the Spring
> 1988 L&T Sig tape. Maybe somebody could make it available for anonymous
> FTP.

It's available from vmsnet-so...@dmc.com. Send a message
containing:

SEND CRON
QUIT

or via anonymous FTP:

UUCP_PUBLIC:[000000.PUB.VMSNET.SOURCES.CRON]

or via anonymous UUCP:

thehulk!~/pub/vmsnet/sources/cron/cron.part01

(see SERVICES from file...@dmc.com, for details on anonymous
uucp)
--
Dick Munroe Internet: mun...@dmc.com
Doyle, Munroe Consultants, Inc. UUCP: ...uunet!thehulk!munroe
267 Cox St. Office: (508) 568-1618
Hudson, Ma. 01749 USA FAX: (508) 562-1133

GET CONNECTED!!! Send mail to in...@dmc.com to find out about DMConnection.

Heribert Dahms

unread,
Jun 29, 1993, 9:12:45 AM6/29/93
to
In <C9C6r...@micrognosis.co.uk> nrea...@micrognosis.co.uk writes:

: rkoe...@author.gsfc.nasa.gov (Bob Koehler) writes:
: |> There is a PD cron for VMS. The pertinent difference between puuting
: |> something in a queue or putting it in a crontab escapes me.

:
[...]
: |> I wish I had real queues on my UNIX machines.


:
: Me too. I also wish my VMS machines had cron. The two are very different.

[...]
If your UNIX machines are Ultrix machines, you can run cron on them to
start an remote batch job on VMS via DECnet using "dcp -S" or task-to-task
communication to a DECnet object.


Bye, Heribert (da...@ifk20.mach.uni-karlsruhe.de)

Joachim Glaubrecht #Alwd#

unread,
Jun 29, 1993, 9:39:04 AM6/29/93
to
>: Me too. I also wish my VMS machines had cron. The two are very different.
>[...]
>If your UNIX machines are Ultrix machines, you can run cron on them to
>start an remote batch job on VMS via DECnet using "dcp -S" or task-to-task
>communication to a DECnet object.
>Bye, Heribert (da...@ifk20.mach.uni-karlsruhe.de)

THEN you are using the BIGGEST SECURITY PROBLEM, VMS ever had ...

don't even think of working with this option on a public-access
network! just a hint.

--
___ _____________________________________
/ / _____ ! jo...@tolkien.imib.rwth-aachen.de !
__/__/_/ Gl ! RWTH-Aachen, Germany, Europe !
/_/ !_Never_send_a_boy_to_do_a_man's_job__!

Bob Koehler

unread,
Jun 29, 1993, 12:11:00 PM6/29/93
to
In article <C9C6r...@micrognosis.co.uk>, nrea...@micrognosis.co.uk (Neil Readwin) writes...

>A crontab entry gets re-executed at the specified times. Adding the cruft
>to do this in a VMS batch job is tedious and error prone. In some cases it
>is also quite difficult - quick, how do you resubmit a batch job on every
>Friday, and also on the 1st, 19th and 31st of each month (if that day
>exists). I could knock up some DCL that would do it, but it wouldn't be
>fun.
>

OK, so you like crontab's 5 little fields. I prefer to write the DCL once
and then copy it. IMHO the different crontab interfaces on all my UNIX systems
are a PITA. One of them just edits a file, the other has an interface that
likes to blow away all the existing commands in the crontab. One looses all
output that isn't re-directed the other insists on sending me mail.

>|> I wish I had real queues on my UNIX machines.
>
>Me too. I also wish my VMS machines had cron. The two are very different.
>Something tells me that if DEC shipped a cron for VMS it would be a monster
>that would allow you do adjust every conceivable parameter and SUBMIT
>qualified for each batch job. Handy for those shops that have 300 generic
>and execution batch queues spread over a bunch of high-end VAXen, but
>massive overkill for the Unix hacker who just wants to run a script each
>night and gets handed a 300 page manual when he asks how to do it :-\
>

I just can't agree with you here on any of these points, and typically I have
to play the role of the UNIX hacker.

Heribert Dahms

unread,
Jun 29, 1993, 11:43:02 AM6/29/93
to
In <20pglo$e...@urmel.informatik.rwth-aachen.de> jo...@merry.imib.rwth-aachen.de writes:

: >: Me too. I also wish my VMS machines had cron. The two are very different.


: >[...]
: >If your UNIX machines are Ultrix machines, you can run cron on them to
: >start an remote batch job on VMS via DECnet using "dcp -S" or task-to-task
: >communication to a DECnet object.
: >Bye, Heribert (da...@ifk20.mach.uni-karlsruhe.de)
:
: THEN you are using the BIGGEST SECURITY PROBLEM, VMS ever had ...
:
: don't even think of working with this option on a public-access
: network! just a hint.

:
Huh? DECnet does node/username based access checks.
I wish non-Ultrix-Unix-X11 via TCP/IP transport did also!

You can specify access control strings or use proxy accounts.
And Ultrix prompts for passwords if only the username is given 8-)
VMS doesn't 8-(
I didn't recommend to use a default DECnet account, you may disable that!
Have your sysmgr define the object with NCP and disable TASK object also.


Bye, Heribert (da...@ifk20.mach.uni-karlsruhe.de)

imh...@indyvax.iupui.edu

unread,
Jun 29, 1993, 11:47:48 AM6/29/93
to
In article <C9C6r...@micrognosis.co.uk>, nrea...@micrognosis.co.uk (Neil Readwin) writes:
[Deletia]

> Me too. I also wish my VMS machines had cron. The two are very different.
> Something tells me that if DEC shipped a cron for VMS it would be a monster
> that would allow you do adjust every conceivable parameter and SUBMIT
> qualified for each batch job. Handy for those shops that have 300 generic
> and execution batch queues spread over a bunch of high-end VAXen, but
> massive overkill for the Unix hacker who just wants to run a script each
> night and gets handed a 300 page manual when he asks how to do it :-\

So, you didn't look at DECscheduler?

One very minor, very nice thing about gadgets like cron or DS is that, when you
change the text of a procedure, that is the text that executes next time. With
self-resubmitting batch jobs, you have to remember to delete the queue entry
and resubmit, or you are treated to one of two interesting behaviors:

o If you didn't PURGE the old version, that one will run one more time
before your changes take effect.

o If you *did* PURGE the old version, the job will fail, since the queue
entry refers to the file by file-id and that file is gone.

I'm slowly moving all of our periodic processing from batch to DECscheduler. I
like it very well, and I haven't even begun to use all of the fancy
dependency-chain features. It is very nice not to have to code the same
submit-myself-again-whenever and send-me-mail-on-error stuff over and over
again, or worry about some transient condition breaking the resubmission cycle.
--
Mark H. Wood, Lead Systems Programmer +1 317 274 0749 [@disclaimer@]
Internet: IMH...@INDYVAX.IUPUI.EDU BITNET: IMHW400@INDYVAX
Celebrate freedom: read a banned newsgroup.

David-Michael Lincke

unread,
Jun 29, 1993, 8:44:20 AM6/29/93
to

Use DEC Scheduler or try the DCL implememtation of cron available ( as far as
I can remember) at info.rz.uni-ulm.de

David

--
*** With mainframes you can do nonsense, with PCs not even that ***
-------------------------------------------------------------------
David-Michael Lincke **** University of St. Gallen USG ************
-------------------------------------------------------------------
EMail: bwll...@sgcl1.unisg.ch, ae...@freenet.carleton.ca
9263...@sgcl1.unisg.ch, dli...@nyx.cs.du.edu
lin...@ezinfo.vmsmail.ethz.ch

Stephen Morris

unread,
Jun 30, 1993, 8:21:11 AM6/30/93
to
In article <1993Jun29....@indyvax.iupui.edu>
imh...@indyvax.iupui.edu writes:
>
>One very minor, very nice thing about gadgets like cron or DS is that, when you
>change the text of a procedure, that is the text that executes next time. With
>self-resubmitting batch jobs, you have to remember to delete the queue entry
>and resubmit, or you are treated to one of two interesting behaviors:
>
>o If you didn't PURGE the old version, that one will run one more time
> before your changes take effect.
>
>o If you *did* PURGE the old version, the job will fail, since the queue
> entry refers to the file by file-id and that file is gone.
>


If this is really a problem, you could always have a two-file batch job:

file1.com
$ @ file2 "''P1'" "''P2'" ...
$ EXIT

In file2.com
:
$ SUBMIT file1.com -
<other qualifiers>
:

The queue holds the FID of file1.com, but latest version of file2.com is always
executed.

Stephen Morris (mo...@tessella.co.uk)
Tessella Support Servies plc, Abingdon, Oxon, United Kingdom
#include <standard_disclaimers.h>

Bill Bochnik (Info Systems)

unread,
Jul 1, 1993, 9:48:21 AM7/1/93
to
In article <C9Foz...@tessella.co.uk> mo...@tessella.co.uk (Stephen Morris) writes:
>In article <1993Jun29....@indyvax.iupui.edu>
>imh...@indyvax.iupui.edu writes:
>>
>If this is really a problem, you could always have a two-file batch job:
>
>file1.com
> $ @ file2 "''P1'" "''P2'" ...
> $ EXIT
>
>In file2.com
> :
> $ SUBMIT file1.com -
> <other qualifiers>
> :
>

This is also useful if you do a @ file2 /log=xxx.log ... because this will
aloow you to mail the results (log) of the run to yourself. This can come in
handy.
--
Bill Bochnik | It's hard to be a James Bond in an Abbott
Systems Analyst | and Costello world.
Ciba-Geigy Corporation | Signed and sealed, they deliver oblivion.
philabs!crpmks!billb | It's worse than that, he's dead Jim.

Dan Wing

unread,
Jul 1, 1993, 7:53:13 PM7/1/93
to
In article <1993Jul1.1...@crpmks.uucp>, bi...@crpmks.uucp (Bill
Bochnik (Info Systems)) writes:

>>file1.com
>> $ @ file2 "''P1'" "''P2'" ...
>> $ EXIT
>>
>>In file2.com
>> :
>> $ SUBMIT file1.com -
>> <other qualifiers>
>> :
>>
>
>This is also useful if you do a @ file2 /log=xxx.log ... because this will
>aloow you to mail the results (log) of the run to yourself. This can come in
>handy.

If you want to log the output of a batch job and mail it (or print it),
a solution I've used often is:

$ ON WARNING THEN GOITO ERROR_HANDLER
$ ...
$ ... other code ...
$ ...
$ERROR_HANDLER:
$ THIS_FILE = F$GETQUI("DISPLAY_FILE","FILE_SPECIFICATION",,"THIS_JOB")
$ LOGFILE = -
F$PARSE(F$GETQUI("DISPLAY_JOB","LOG_SPECIFICATION",,"THIS_JOB"), -
"SYS$LOGIN:''F$PARSE(THIS_FILE,,,"NAME")'.LOG",,,"NO_CONCEAL")
$ TEMPFILE = "SYS$SCRATCH:TEMP_" + F$GETJPI(0,"PID") + ".TMP"
$ SET OUTPUT_RATE ! flush output to the .LOG file
$ WAIT 00:00:02 ! give it time to finish
$ TYPE 'LOGFILE'/OUTPUT='TEMPFILE'
$ MAIL 'TEMPFILE' 'F$GETJPI(0,"USERNAME")'/SUBJECT="I crashed and burned"
$ DELETE 'TEMPFILE';
$ EXIT

(this is just to get you going -- this sortof thing does work, but I could
have a problem with too many commas or something...)

Anyways, I like this because it only sends you mail if the code detected
and error, and then sends you the whole .LOG file, so you don't need to
go look for it. You can even get fancier by putting some unique string
in the error handler and use SEARCH/WINDOW=(100,1)/OUTPUT and the Email
the resulting output, so you only have to look at the last 100 lines of
the .LOG file instead of the whole thing.

Hope someone finds this useful. Our applications people have added this
to a few of their programs, and seem to like it.

-Dan Wing, Systems Administrator, University Hospital, Denver
dw...@uh01.colorado.edu or win...@ucolmcc.bitnet

Michel Steiner

unread,
Jun 29, 1993, 1:09:00 AM6/29/93
to

>> UNIX have a facility called cron, which allows commands to be at regular times
>> without having to hold them on queues. Does VMS have anything similar?

VMS does not have such a functionality build-in. But the product DECscheduler
does this... and more !

Michel.

Framstag

unread,
Jul 6, 1993, 2:49:49 PM7/6/93
to
In <1993Jun28....@iwsd01.itwol.bhp.com.au> WEZ...@itwol.bhp.com.au writes:

> UNIX have a facility called cron, which allows commands to be at regular times
> without having to hold them on queues. Does VMS have anything similar?

I wrote a CRON program in DCL.

CRON is a job scheduler for VMS for periodic tasks, inspired by the unix
crontab facility.

CRON doesn't need any special privs, every user should be able to use it.
You need at least: VMS 5.5, active job quota 3, subprocess quota 3.
A Pascal or a FORTRAN compiler are optional (only for reporting problems with
the CRON_DAEMON).

An example of a running CRON system:

$ cron list

31-JAN-1993 23:10:40 ( detached CRON-daemon: MAIN02::ORAKEL_CRON )

Jobname Times (m h d wd or d-h:m) Queue
------- --------------------------- -----
BACKUP 0 6 * * fast$batch
HAPPA 0 18 * 1-5 / 40 13 * 1-5 fast$batch
NEWS 30 18 * * fast$batch
CRON_CHECK 02:00 (Holding until 31-JAN-1993 23:22) fast$batch
O25 0:05 (Holding until 31-JAN-1993 23:13) spawn
USER 0:10 (Holding until 31-JAN-1993 23:15) spawn
$
$ cron kill
%CRON-S-KILLD, killed detached daemon-process ORAKEL_CRON
-CRON-I-KILLD, and all fix timed/spawned jobs
%CRON-S-KILLJ, killed job CRON_CHECK
$
$ cron start
%CRON-S-LAUNCH, launched job BACKUP
%CRON-S-LAUNCH, launched job CRON_CHECK
%CRON-S-LAUNCH, launched job HAPPA
%CRON-S-LAUNCH, launched job NEWS
%CRON-S-LAUNCH, launched job O25
%CRON-S-LAUNCH, launched job USER
%CRON-S-DAEMON, started detached daemon-process ORAKEL_CRON
$
$ cron kill=user
%CRON-S-KILLJ, killed job USER
$
$ cron start=user
%CRON-S-LAUNCH, launched job USER
$
$ type cron:backup.crn
$! 0 6 * *
$! fast$batch
$! /cpu=0
$set noon
$del ba:orakel.zip.*,util.zip.*
$vzip -b sys$scratch: ba:orakel.zip [...]*.*
$vzip -b sys$scratch: ba:util.zip oo:[000000...]*.*


You can get it from ftp.rz.uni-ulm.de pub/VMS/misc/dcl/cron.shr

\ Ulli 'Framstag' Horlacher \ psi%(0262)45050260103::orakel \


\ Student consultant VAX/VMS and networks \ ora...@dulruu51.bitnet \

\ Rechenzentrum Universitaet Ulm Germany \ ora...@rz.uni-ulm.de \
\ G=ulli;S=horlacher;OU=rz;P=uni-ulm;A=dbp;C=de \ rzmain::orakel \
\ "With mainframes you just can do nonsense, with PCs not even that." \

0 new messages