home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The World of Computer Software
/
World_Of_Computer_Software-02-385-Vol-1of3.iso
/
c
/
chkdef.zip
/
CHKDEF.DOC
next >
Wrap
Text File
|
1989-09-19
|
7KB
|
182 lines
A long time ago, in a city far far away...
San Antonio, TX ran totally crashmail on all its local
echos. The time for this is past (unfortunately) but its
memory still lives on. (Actually we still run 'true
crashmail' but not during the heavy usage hours when it
becomes a practical impossibility) In this kind of a set up
you scan your message bases after EACH caller. One of the
things I did to speed up processing of RBBSMAIL scan was to
create a small fast pascal program to prune all the files
out of my areas.bbs file that hadn't changed since the last
time a scan was run. This may seem like a waste of time to
you, but remember I was running on two 90ms hard drives and
the time saved was very noticable to me. This was done
(with a few glitches at first, like stripping out my origin
line and writing dozens of little files instead of one
single data file, said glitches having been mercilessly
pointed out by one Mike Zakharoff who put the thing through
its paces for me. I followed his suggestions for
improvement scrupulously and was finally satisfied with the
results when WHAM no more hard drive. Needless to say I
didn't have a backup. What to do? I had no more source,
and my latest executable version still lying around was old
and buggy. I was despondent and moped around for months
thinking evil thoughts and studying arcane methods of data
recovery...
The only fortunate thing is that chkdef never got
released, ergo I didn't have to support the thing without
even having the source... Finally I came out of my doldrums
and spent a day to re-write the durned thing. This version
is more logically written, more flexible, smaller, and
faster than the original. (It helps having completely
written the thing once, lemme tell ya...) So here's the
real docs:
SWITCHES (run without parameters for help)
/B - Runs CHKDEF in BEFORE USER mode. When this switch is
set chkdef will scan your areas.bbs file and record
each non-comment line in it as well as the time-date
stamp of each messages file into a temporary file for
later comparison.
/A - Runs CHKDEF in AFTER USER mode. When this switch is
set chkdef will scan the temporary file created when
it is run in the /B mode and compare the time date
stamps recorded in it with the current ones. Any
messages files which have changed will be recorded in
a secondary areas.bbs file.
/I:INFILE - This is your file containing echos and their
destinations which normally RBBSMAIL uses for
scanning. The default is AREAS.BBS
/O:OUTFILE -This can be anything you want, and is the name
of the secondary areas.bbs file which chkdef
will create which does not contain unchanged
message bases. The default is AREAS.BB2
/T:TEMPFILE-This can also be anything you like, it is the
file in which chkdef will store the lines of
your areas.bbs which are not comments and the
date/time stamps of the message files. The
default is AREAS.&&&
Example of usage:
CHKDEF /B {Gets current time stamps of messages files}
RBBS-PC ... {user logs in}
CHKDEF /A {Creates smaller secondary areas.bbs file}
RBBSMAIL SCAN -O -F:AREAS.BB2
{scan only changed message bases}
Binkley.bat
or alternatively (like I have it...)
RBBS-PC ... {I like this configuration better as}
CHKDEF /A {it doesn't add any delay to user logon}
{and the results are identical}
RBBSMAIL SCAN -O -S -F:AREAS.BB2
CHKDEF /B
Binkley.bat
Technical notes
---------------
1) CHKDEF opens the messages files very briefly to obtain
the date/time stamp. it does NOT write to them. This
may be of interest for multi-node people.
2) The date/time stamp is stored immediately after the line
containing the message file in AREAS.BB2.
3) CHKDEF makes these assumptions about your areas file...
The first NON COMMENT line is your origin line. Any line
beginning with a <SPACE>, a '-' or a ';' is a comment
line. Blank lines are ignored.
4) You CAN specify /B and /A at the same time. Chkdef will
ALWAYS process AFTER USER mode first. This way you can
combine everything into one step like so:
RBBS-PC CHKDEF /B /A RBBSMAIL SCAN /A:AREAS.BB2
BINKLEY.BAT
Unfortunately RBBSMAIL's scan function will change the
messages file if a message has been entered, and you
will wind up scanning it TWICE (this time and the next
time you run chkdef)
5) Chkdef is NOT smart enough to tell the difference
between a user joining a conference and a message being
entered into it. So if a user enters a conference it
will change the checkpoint record changing the time/date
stamp. Chkdef will faithfully pass the name of the
conference along to RBBSMAIL for processing.
6) The clear screen is an ANSI sequence, all output is
fully redirectable to the communications port or a file.
7) Any files which are listed in your AREAS.BBS but don't
exist will generate an error message on your screen
indicating the missing file (it will NOT stop
processing) which will simplify maintenance of this file
for sysops with large numbers of echos. When I first
ran the thing on my areas.bbs I was shocked at how much
junk I had left in it.
8) Time savings: (Rounded to nearest second) for 17
unchanged echo message bases. (65ms ST-238R, No Cache,
10MHZ XT, results will vary with configuration) Tests
run with RBBSMAIL 890902.
-----------------------------
CHKDEF /B -\
CHKDEF /A - > 22 seconds
RBBSMAIL SCAN -O -F:AREAS.BB2 -/
-----------------------------
----------------
RBBSMAIL SCAN -O {Run to ensure no changes were}
{scanned}
RBBSMAIL SCAN -O -> 122 seconds
----------------
As you can see you need 3+ unchanged message bases to make
CHKDEF break even. If you run scans in a nightly event this
program may not be for you. If you run your scans more
frequently it may reduce the time your BBS is offline. The
more echos you carry the more likely it will save you some
time. If you scan frequently this WILL save you time.
CHKDEF was designed with 25 echos, 90ms hard drives, and
frequent scanning in mind. If you have this setup its a
MUST.
Support is available through
NUL Sysop: Jan Maaskant (1:387/301 |
8:930/502) (512)690-5601 300-2400
Turbo Pascal 5.0 Source available on request
Thanks to Mike Zakharoff who went through the original copy
and found all the bugs. I've (I think...) remembered all
his suggestions in this one.
Cost/Registration/etc...
The rules for this are the same as for anything else I
write:
1) If you pack ads into files you had no part in the
development of you may not use this program
2) If you charge for an RBBS related utility the license
fee is equivalant