File:  [Power 6/32 Unix Tahoe 4.2BSD] / cci / usr / src / usr.bin / bsc / doc / tutor.txt
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Sun Jul 28 12:26:12 2019 UTC (7 years ago) by root
Branches: bsd, MAIN
CVS tags: v121, HEAD
Power 6/32 Unix version 1.21

.RP
.TL
Using the 2780/3780 Utilities
.AU
Risa Galant
.AI
D. L. Buck and Associates, Inc.
.LP
The
.I BSC
utilities are a collection of programs, library-files, and drivers which
are used to perform batch communications with remote computers, and which
make non-IBM terminals look like IBM 2780 or 3780 communications terminals.
.LP
This tutorial describes some basic terminology, how files are sent and
received, how each utility works, and
how to use each invocation. The utilities are presented in two parts:
those used daily by everyone interested in communicating with remote
computers, and those the system administrator will use for maintenance and
administration.
.LP
The utilities are presented in probable order of use:
.ID
I. Daily use
   1. Queuing files for batch transmission
   2. Searching host spool directories for files received 
   3. Formatting files received 

II. Administration and Maintenance
   1. Checking the communications log (if one is kept)
   2. Clearing old received files from the host spool directories 
   3. Purging the communications log
   4. Using /usr/lib/crontab to make BSC run automatically
.DE
.SH
Terminology
.LP
The following terms will be used throughout this tutorial:
.RS
.IP \(bu
Remote host, or host
.IP
The remote host is any remote computer with which communications are to take
place. There may be more than one. Your system administrator should know with
what hosts you may communicate.
.IP \(bu
Spool directory
.IP
This refers to a special directory on the computer into which transmission
control files for files to be transmitted to a particular host are
placed, and into which files received from 
that host are placed. Each host to be communicated with must have a 
corresponding spool directory, otherwise, files intended for a particular 
host could go to a different one, and it would be unclear from which host a 
particular received file came.
.IP \(bu
Default host
.IP
Several of the utilities have a default name for the host (and thus for the
spool directory); that name is 
.I default.
The default host is the spool directory files to be sent are queued for,
searched for, and formatted from if no other host name is specified.
Host names should be specified if there are several hosts which
may be communicated with, but if there is only one, your system
administrator has probably assigned the name "default" to it. This 
makes invoking the utilities
much simpler, because the need to specify a host name is eliminated.
.IP \(bu
.I
BSC (Bisync)
.R
Daemon
.IP
This utility is usually invoked by an entry the system administrator made in
.I /usr/lib/crontab.
It controls the communications activity between your computer and the remote
host computer, and does the actual file transfers.
.IP
If your computer does not have auto-dial or auto-answer facilities for
connection to the remote computer, you may have to manually invoke the
daemon. Your system administrator should be able to give you procedures
for doing so.
.RE
.SH
How Files Are Sent and/or Received
.LP
The daemon needs three things to perform its communications duties:
.IP 1.
A remote host configuration file for each host with which communications
take place.
.IP 2.
A remote host spool directory (one per host), the name of which matches the
name of the configuration file.
.IP 3.
At least one transmission control file in the remote host spool directory
(i.e., at least one file to send, or an empty ("dummy") control file).
.IP \(bu
Remote Host Configuration Files
.IP
Configuration files are created for each remote host by the system
administrator in a directory called
.I /usr/lib/bscbatch.
They serve two purposes: 1, to identify a remote host
spool directory to the daemon, and 2, to tell the daemon how to communicate 
with the host. They contain parameters such as in which character code data 
will be transferred (ASCII or EBCDIC), how long to put up with a specified 
(unusual) line condition before terminating a communications session, and
how many times to try to get the communications line to the remote host
before giving up. If the configuration file doesn't exist, there's no
host spool directory as far as the daemon is concerned.
.IP \(bu
Remote Host Spool Directory
.IP
As previously explained in the terminology section, this directory's 
function is to contain files received from the host, and transmission
control files created when files are queued for transmission. It must
have the same name as the host configuration file or the daemon won't
know it exists.
.IP \(bu
Transmission Control Files
.IP
Transmission control files are created by
.I bscbatch
for every file which is queued for transmission. They're placed in the
remote host spool directory,
.I /usr/spool/bscbatch/<hostname>,
where <hostname> is the name of a real host spool directory on your computer.
They tell the daemon what file(s) to transmit, how to transmit them, whether
special mail should be sent when they've been successfully transmitted, and
whether to send only a copy of the file.
.IP
Your system administrator will already have set up all the configuration files
and spool directories you need you need them.
All you really need to know is the name assigned to the remote host
on your computer; the
.I BSC
daemon and the utilities will do the rest.
.IP \(bu
How It Works
.IP
Once invoked, the daemon searches the
.I /usr/lib/bscbatch
directory for a host configuration file. When it finds one, it searches
.I /usr/spool/bscbatch/<hostname>
for transmission control files. If it finds one, it pulls the information
from the configuration file and tells its driver how it intends to 
communicate with the remote host. It then opens the file to be transmitted
and attempts to send it. If transmission is successful, it looks for another
one to send, repeating the process until there are no more transmission
control files in the spool directory. At that time, it waits,
ready to receive files. If the host has anything to transmit,
it does so.
.IP
If, when communications first start, the host is more persistant than the 
daemon and
wants to transmit first, the daemon will give up and decide to receive
instead. It attempts to send again when the host is finished, and when it is
done transmitting, it informs the host it is ready to receive again.
.IP 
When no further activity is detected with the remote host for a period of
time specified by the system administrator, the daemon
"times out", i.e. it decides to end the session with that host. It
continues to search through
.I /usr/lib/bscbatch
for host spool directories, repeating the communications process for each
one it finds. When it doesn't find any more hosts, the daemon ceases
to exist.
.IP
Received files are placed in 
.I /usr/spool/bscbatch/<hostname>
with names which are useful only to differentiate one file from another;
they're meaningless for anything else. The standard form is:
.RS
.IP
PR<4-digit index #><daemon's process id #>
for print files, and

PU<4-digit index #><daemon's process id #>
for punch files.
.RE
.IP
For example, if the daemon's process id is 89 and it receives two
print files, it will place the print files in the host spool directory
and name the first one PR000089 and the second one PR000189.
.SH
Command Syntax Conventions
.LP
Command syntax of the utilities is shown as follows:
.DS
utility param [option=<name>] [option] [option] ...
.DE
.LP
Words without brackets are mandatory parameters \(em they must be typed in if 
the utility is to perform the function desired.  All the words within square 
brackets ("[]") are optional parameters \(em they need not be specified unless 
values other than their default values are desired.  All the words within 
angular brackets ("<>") will be replaced by actual names, e.g. the names 
of real files to be transmitted to a remote host, or the name of a remote 
host to be communicated with.
.NH 1
Daily BSC Utilities
.LP
Daily use of
.I BSC
consists of queuing files for transmission, checking for files received from 
a remote host, and processing files received. The utilities which perform 
these functions are 
.I bscbatch,
which batches (queues) files for transmission and searches directories for 
received files, and
.I bscpr,
which formats received files.
.NH 2
Queuing Files for Batch Transmission
.LP
Files must be queued before they can be transmitted to a remote host.
.I bscbatch
does this by creating special files called transmission control files, one
for each file to be sent. Each contains the name of the file and
information about the options with which it was queued, e.g., whether it is
just a copy and should be deleted after it has been sent, or whether or not 
to send mail if it was transmitted successfully. Transmission control files
exist in the spool directory for a host, and start with the letter "C".
.LP
The
.I BSC
daemon attempts to contact a particular host only if it finds at least
one transmission control file in its spool directory, so that's where
.I bscbatch 
puts them.
.LP
It is invoked as follows:
.DS
bscbatch [\(emto=<hostname>] [\(emcopy] [\(emmail] [\(emtransp] [<file> ...]
.DE
.NH 3
The Options
.IP \(bu
.I \(emto=<hostname>
.IP
The 
.I \(emto 
option is used to specify a destination host. If 
.I \(emto 
isn't used, files will be queued in the
.I default
host spool directory automatically.
.IP
Note: only one destination host can be specified per invocation of
.I bscbatch.
.IP \(bu
.I \(emcopy
.IP
The
.I Bisync
daemon depends on the transmission control file for information about what
file is to be sent. If the 
.I \(emcopy 
option is specified, a copy of the file to be transmitted is created 
in the host's spool directory, and 
the name of that copy is put into the control file. The daemon transmits 
the copy, rather than the file itself, when 
communication with the remote host is begun. 
.IP
The 
.I \(emcopy 
option is especially useful if a file is going to be changed, but 
its current version must be transmitted to the remote host. A copy can be
made of the file in its current state and added to the spool directory, and
work can continue on the original.
.IP
Once the copy has been successfully transmitted, it is removed from the
spool directory.
.IP
Note: the daemon removes only
.I copy
files from the spool directory; originals are not removed from their 
directories.
.IP \(bu
.I \(emmail
.IP
Mail is usually sent to the system administrator only if there were
problems during the transmission or reception of files. If 
.I \(emmail 
is specified, mail will be sent to the user id queuing the file 
if it was transmitted successfully.
.IP \(bu
.I \(emtransp
.IP
The
.I Bisync
daemon checks whether special control characters exist in the 
file being transmitted. If there are any, it changes its transmission 
mode so that those characters are transmitted safely, i.e. not considered 
to be
.I BSC
control characters, but actual data. This mode is known as the
.I transparent 
mode. It enables special characters which are part of a
file's text to be treated as data, rather than as characters with
special meaning for the daemon.
.IP
If 
.I \(emtransp 
is specified, the file will be sent in transparent mode with no
special character checking done by the daemon. 
.I \(emtransp 
is generally used
only if the file to be sent 
.I has
to be sent in transparent mode for remote host compatability reasons. 
That sort of situation is unusual, and
.I \(emtransp
really isn't needed for normal communications activity.
.IP
Note: this form is usually slower than non-transparent mode.
.IP \(bu
Additional notes
.IP
All files queued during a single session of 
.I bscbatch
will be queued with the same options. If, for example, it is desired that a 
.I copy 
of only one file of, say, 20 to be queued be transmitted, it is 
better if that file is queued via a separate command to avoid needless 
use of space.
.IP
.I bscbatch
does its work quietly \(em no prompts are displayed, no input is needed beyond
invoking it with appropriate parameters and/or options. It's easy to know
when it is finished \(em the system prompt will appear.
.IP \(bu
[<file>]
.IP
Substitute the names of files to be queued for transmission for the [<file>]
option, separated by spaces. Several files can be queued at once, or separate
invocations of 
.I bscbatch
can be made as files are ready for transmission.
.IP
If no file names are specified, 
.I bscbatch
creates a "copy" file from text entered on the terminal ("standard input")
as it is running, placing it in the host's spool directory. The transmission 
control file created contains the same kind of information as those which are 
created for files queued with the 
.I \(emcopy 
option.
.IP
Text is entered at the terminal as if the terminal is a typewriter. When
all text has been entered, type control-d on a line by itself.
This signals
.I bscbatch
that the file is complete. It creates the "copy" file, and returns to the
system prompt. Only one file can be queued this way.
.NH 3
Sample Queuing Invocations
.LP
Suppose you want to send three files, stuff, more_stuff, and further_stuff,
to a host named "2780" by the system administrator. Further, suppose you
want mail to be sent to you when sending is completed. The following
command will do this for you:
.DS
bscbatch \(emto=2780 \(emmail stuff more_stuff further_stuff
.DE
.LP
Or, suppose that you want to send a binary file called obj_file to the
.I default
host, but you're still working on it and want to be sure that the current
version gets sent. Use the following:
.DS
bscbatch \(emcopy \(emtransp obj_file
.DE
.NH 2
Searching Host Spool Directories
.LP
.I Bscbatch
is also used to search the host spool directories for files received from
the hosts. This is usually done after communications have been completed.
.LP
It is invoked as follows:
.DS
bscbatch \(emq[=<host name>] [\(emt=hh[mm]] [\(eml=lines]
.DE
.NH 3
The Options
.IP \(bu
.I \(emq[=<hostname>]
.IP
.I \(emq 
is 
.I not 
an optional parameter. If the search function of 
.I bscbatch
is desired, 
.I \(emq 
has to be specified. Otherwise,
.I bscbatch
assumes that you want to queue a file for transmission.
.IP
If a host name isn't specified,
.I bscbatch
will do the search on the
.I default
host spool directory. Otherwise, it will search the spool directory of the
specified host for files received.
.IP \(bu
.I \(emt=<hh[<mm>]>
.IP
.I \(emt 
is used to limit the search for received files to those received within
the last 
.I hh 
hours and, optionally, 
.I mm 
minutes. If 
.I \(emt 
isn't specified, all the files received from the host and currently in the
spool queue are displayed.
.IP
.I Warning: 
your system administrator will probably cause old received files
to be discarded every once in a while. Don't go off on vacation and expect
your received files to be waiting for you! As soon as you identify them,
move them
to a safe place in your directory. You can give
them meaningful names this way, too, since the names the daemon assigns are
not very meaningful (it uses 
its process id and an index number to tell files apart). "mv"ing your files
will also help keep the size of the spool directories to reasonable limits.
.IP \(bu
.I \(eml=<lines>
.IP
.I <lines>
must be a number greater than 0 (zero).
.I bscbatch
displays the first 20 lines of each file received. If some other
number of lines is desired, use the 
.I \(eml 
option to specify how many.
.NH 3
Sample Search Invocations
.LP
Let's say that your system administrator set up the
.I bsc
daemon to run overnight, and when you start work in the morning, you
want to see if you received anything from your favorite host, 2780.
You know that you can identify any file that's yours in the first 10
lines, so you enter:
.DS
bscbatch \(emq=2780 \(emt=8 \(eml=10
.DE
.LP
This causes
.I bscbatch
to search 2780's spool directory for any files received within the last eight
hours and to display the first 10 lines of each one found.
.LP
On the other hand, you can poke around the entire queue of received files in
the 
.I default
host spool directory and display 20 lines of each one by typing:
.DS
bscbatch \(emq
.DE
.LP
Note: If it is possible to identify which files are yours versus which files
are someone else's merely by looking at them, your system administrator may
have modified the
.I bsc
daemon to have it place your files in your directory and send you some mail 
when they
arrive. In that case, you won't need to use the search option at all.
.NH 2
Formatting Files Received
.LP
.I bscpr
is used to format files received from the remote host which contain
IBM 3780 or 2780 terminal control characters and escape sequences.
It is invoked as follows:
.DS
bscpr [\(emascii] [\(empage=<pp>] [<chan>=<lineno> ...] [<file>]
.DE
.NH 3
The Options
.IP \(bu
.I \(emascii
.IP
.I Bscpr
assumes that all the control characters and escape sequences used for
printer positioning are EBCDIC style unless this parameter is specified.
EBCDIC and ASCII use different letters to identify vertical positioning,
so this parameter is important.
.IP \(bu
.I \(empage=<pp>
.IP
Page length is assumed to be 66 lines unless this parameter is specified.
.IP \(bu
<chan>=<lineno>
.IP
This parameter allows the user to tell
.I bscpr
the line numbers to which channel numbers specified in the file's escape 
sequences correspond. 
.I <chan> 
may be a number from 1 to 12. 
.I <lineno> 
may be a number from 1 to whatever the page length is: 66 if the default page
length is being used, or the length set in the 
.I \(empage 
option. 
.IP
Usually, channel 1 is top-of-form, channel 12 is bottom-of-form, and the 
rest correspond to line numbers in between. 
.NH 3
Sample Invocation
.LP
Suppose you received a file and "mv"ed it to your directory, calling it
received_file.
If you'd like to see what received_file looks like when it is formatted on your
terminal, using line 22 of your terminal as bottom of form, type:
.DS
bscpr \(empage=22 12=22 received_file
.DE
.LP
.I Bscpr 
will format 
.I received_file
with 22 lines per page, and any escape sequence specifying channel 12
will cause bscpr to go to line 22, the bottom of the page.
.SH 
See Also:
.LP
.ID
BSCBATCH(8)
BSCPR(1C)
.DE
.LP
For information on escape sequences for forms control:
.LP
.I
Component Description: IBM 2780 Data Transmission Terminal,
.R
IBM document GA27-3005.
.br
.I
Component Description: IBM 3780 Data Communication Terminal, 
.R
IBM document GA27-3063.
.NH 1
Administration and Maintenance
.LP
Administration and maintenance of
.I bsc
consists of checking the communications log regularly,
doing periodic clean-ups of old received files in the
host spool directories, and periodically purging the log of old entries.
The utilities which perform these functions are
.I bsclog,
which puts log entries into report format and displays them and purges 
the log, and
.I bsclean,
which cleans out the host spool directories.
.NH 2
Checking the Communications Log
.LP
A log of all communications activity with a remote host is kept if a file named
.I AUDIT
has been created in the host's spool directory. Information in the log
includes communications session statistics, files sent and received,
their sizes in bytes and number of blocks they were transmitted in,
when files were queued for transmission, problems encountered, reasons
for disconnection, and so on. Each entry includes the date and time that
the event for which it was made occurred, the class of the event, and
the user id on which the event took place.
.LP
.I bsclog
is used to put the information in the communications log into a
readable report format. It displays all entries in the communications log 
for the 
.I default
host, unless one or more of its options are used to limit the display.
It is invoked as follows:
.DS
.ta 0.6i
bsclog	[<hostname>] [\(emfrom=[<yymmdd>]<hhmm>] 
	[\(emto=[<yymmdd]<hhmm>] [\(emclass=<class(es)>] 
	[\(emuser=<user id>]
.DE
.NH 3
The Options
.IP \(bu
.I <hostname>
.IP
If you're checking the log for any host besides the
.I default
host, specify it here.
.IP \(bu
.I \(emfrom=[<yymmdd>]<hhmm>
.IP
.I bsclog
will display the entire communications log unless you give it some limits. Use
.I \(emfrom
to tell it from which point you'd like to check the log. 
If only hours and minutes are specified,
.I bsclog
will assume that today's entries are to be displayed, starting at
the time hh:mm. If a specific date is desired, enter the date
.I and
the time from which to start checking, in year-month-day-hours-minutes
format, e.g. 8305261000 for May 26, 1983 at 10:00 a.m.
.IP
Four-digit times must be specified, e.g. 8 a.m. is specified as 0800,
3 p.m. as 1500, etc.
.IP
Note: hours and minutes
.I must
be specified if
.I \(emfrom
is used. Year, month, and day are optional.
.IP \(bu
.I
\(emto=[<yymmdd>]<hhmm>
.IP
If 
.I \(emfrom
can be thought of as a starting point for checking the communications log,
.I \(emto
can be thought of as an ending point. If only
.I \(emfrom
is specified, 
.I bsclog
will display everything from the starting time until it reaches the end of
the log. If you really don't want to display that much information, use
.I \(emto
to specify the ending point you want.
.IP
As with
.I \(emfrom,
if only hours and minutes are specified,
.I bsclog
assumes that the ending date for checking the log is today, at the time
specified. If a different date is desired, it must be specified in the 
year-month-day-hours-minutes format.
.IP
Note: as in 
.I \(emfrom,
hours and minutes 
.I must
be specified if 
.I \(emto
is used. Year, month, and day are optional.
.IP \(bu 
.I \(emclass=<class(es)>
.IP
Communications log entries come in 6 classes:
.I
C, D, Q, R, S,
.R
and
.I T, 
for connect, disconnect, queue, receive, send, and statistics log
entries, respectively.
.I bsclog
will display all classes of log entries unless you say otherwise.
If you wish to look at entries for a particular class
or group of classes, rather than all of them, use 
.I \(emclass
to do so.
.IP
See 
.I BSCLOG(8)
for descriptions of messages and their classes.
.IP
Note: one or more classes may be specified, either in upper or lower case.
Classes may be specified in any order.
.IP \(bu
.I \(emuser=<user id>
.IP
The
.I \(emuser
option is used to look at the log entries for a particular user id. This
is useful for such things as checking who's queuing files for
transmission, or who's trying to invoke the
.I bsc
daemon.
.IP
Note: any valid user id may be entered for this option, but only one may
be specified per invocation. 
.NH 3
Sample Log Checking Invocations
.LP
Suppose that you'd like to check 2780's communications log for all activity
between 10:00 and 11:00 on June 21, 1983. This command may be used:
.ID
bsclog 3780 \(emfrom=8306211000 \(emto=8306211100
.DE
.LP
Or, you've been curious as to how successful the connections have been
since you started keeping the log (or at least since the last time you
purged it) for
.I default.
Type the following:
.ID
bsclog \(emclass=C
.DE
.LP
Okay, suppose that it is June 15, 1983, and
you want to check all the send, receive, and statistics for
user id root between June 10, 1983 at 3 p.m. and June 12, 1983 at 3 p.m.
for remote host 3780. Try this:
.ID
bsclog 3780 \(emfrom=8306101500 \(emto=8306121500 \(emuser=root \(emclass=SRT
.DE
.LP
As a last example, say that you want to look at everything which happened
with 
.I default
after 8 a.m. today. Type:
.ID
bsclog \(emfrom=0800
.DE
.NH 2
Clearing Out Old Received Files 
.LP
Files received from remote hosts are placed in the local spool directory
for the appropriate host. They remain in the spool directories until
they are either claimed and "mv"ed to a user directory, or until they
are cleared out by the system administrator.
.LP
.I Bsclean
is used to clear out old received files from host spool directories.
It removes any file which begins with PU (indicating a received punch
file) or PR (indicating a received print file) which is more than
72 hours old from the
.I default
spool directory unless its options are used to specify otherwise.
.LP
It is invoked as follows:
.ID
bsclean [\(emt=<hh>] [<hostname>]
.DE
.NH 3
The Options
.IP \(bu
.I \(emt=<hh>
.IP
If a cutoff age of other than 72 hours is used to select files for removal, use
.I \(emt
to specify the age. 
.IP
Note:
.I <hh>
indicates age in hours.
.IP \(bu
.I <hostname>
.IP
To clean out the spool directory of any host other than
.I default,
specify this option.
.IP
Note: 
.I bsclean
does its work quietly. You'll know it is done when the system prompt
reappears.
.NH 3
Sample 
Invocations
.LP
Suppose that you've warned all your users that you're going to clean
out all received files in 3780's spool directory which are more than
five days old. When you set out to do so, you'll type:
.ID
bsclean \(emt=120 3780
.DE
.LP
If you'd rather just let
.I bsclean
do as it will (or you'd like all received files in
.I default's
spool directory removed which are older than 72 hours), you'll type:
.ID
bsclean
.DE
.NH 2
Purging the Communications Log
.LP
As time goes by, more and more communications sessions occur, and the
communications log gets larger and larger. 
.I bsclog's
purge function is used to reduce the size of the log.
.LP
It is invoked as follows:
.ID
bsclog  \(empurge=<dd> [<hostname>]
.DE
.NH 3
The Options
.IP \(bu
.I <hostname>
.IP
This option is specified if a spool directory other than
.I default's
is to be purged.
.IP \(bu
.I \(empurge=<dd>
.IP
.I \(empurge
is 
.I not
an optional parameter. If it isn't specified, 
.I bsclog
will assume that you wish to display the log, not purge it.
.IP
.I <dd>
signifies the age of entries to be purged, in days. It must be greater than
or equal to 1.
.IP
Note: there is no default age for purging entries. 
.IP
Also, 
.I bsclog
converts the number of days specified to the number of hours in that many
days, and compares that to an entry's age
before it decides whether or not to purge the entry. This may result in
some confusion when you try to purge all entries which were made 
yesterday, display the log to be sure they're gone, and find that
some are still there. That's probably because exactly
24 hours haven't elapsed between the time the entries were made and the
time you decided to purge them. Don't worry \(em you'll get them next time.
.NH 3
Sample Purging Invocation
.LP
Let's say that you really do want to purge all communications log entries
which were made yesterday for the remote host 3780. Here's how:
.ID
bsclog 3780 \(empurge=1
.DE
.LP
Or, perhaps you're clearing out the
.I default
communications log so that there are only two days' worth of entries in the 
log at any time.
The following command will rid the log of any entry
which is at least three days old:
.ID
bsclog \(empurge=3
.DE
.NH
How To Use Cron To Make BSC Run Automatically
.LP
You may wish to have the spool directories and log files cleared automatically
on a regular basis. There is a resident clock daemon,
.I /etc/cron,
which executes commands at specified dates and times if those commands are
in a file called
.I 
/usr/lib/crontab. /etc/cron
.R
is usually started by the initialization process at boot time.
See
.I CRON(1M)
for more information about this facility.
.NH 2
Crontab Entries
.LP
Entries in
.I /usr/lib/crontab
consist of lines which each contain six fields separated by spaces or tabs.
The first five fields are numeric values specifying dates and times to execute
the command, which is specified in the sixth field. The date and time
fields may have the following values:
.DS
.ta 2i
Minute	0-59
Hour	0-23
Day of Month	1-31
Month of Year	1-12
Day of Week	0-6 (0 = Sunday)
.DE
.LP
They are specified in the same order as they're listed above. Entries are
made using the text editor.
.NH 2
Sample Entries
.LP
Suppose that you wanted to have bsclog purge all communications log entries
for 3780 once a month. Further, you've decided that the 15th of each month
at 1 a.m. would be a  good time to have this done. The following entry 
will do this for you:
.ID
0 1 15 * * bsclog 3780 \(empurge=1
.DE
.LP
Or, suppose that you want to purge the log entries for
.I default
every week, after working hours on Fridays, leaving two days' worth of entries
untouched. Try the following
.I /usr/lib/crontab
entry:
.ID
30 18 * * 5 bsclog \(empurge=2
.DE
.LP
This will purge all log entries older than two days at 6:30 p.m. every
Friday.
.LP
As a last example, suppose that all received files older than 72 hours in the
.I default
spool directory are to be removed daily, at 1 a.m. Use the following
.I /usr/lib/crontab 
entry:
.ID
0 1 * * * bsclean
.DE
.SH
See Also:
.LP
.ID
BSCLOG(8)
BSCLEAN(8)
CRONTAB(8)
.DE
.FS
DLBA Version 1.2
.FE

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.