home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.wwiv.com
/
ftp.wwiv.com.zip
/
ftp.wwiv.com
/
pub
/
BBS
/
REHASH13.ZIP
/
REHASH.DOC
< prev
next >
Wrap
Text File
|
1991-11-04
|
5KB
|
137 lines
REHASH
v1.30
11-04-91
by Tom Collins
What
----
REHASH is a small RBBS utility for packing and resizing a system's
users files. Users can be removed based on the date last on the
system (or in a conference), and exempted by security level.
Why
---
Ideally, you'd set up your BBS with an optimum number of user records
for both the main board and for conferences. Determining the optimum
is at best, an annoying problem. REHASH takes care of this for you.
In addition, the users' file "rebuilding" function, normally contained
within CONFIG, can be done by REHASH from a batch file on a regular
basis.
Using It
--------
The generic form of the REHASH command line is:
REHASH <Messages File> <Users File> [/ELx] [/OTy] [/MFz] [/EUm]
The first two parameters are required, and correspond to a set of
messages/users files. For example, MESSAGES and USERS, or
TREKM.DEF and TREKU.DEF.
The /OT parameter tells REHASH to delete users who haven't been on
(or entered a given conference) in y days. The default is to not
delete any users.
The /EL parameter tells REHASH to never delete users whose security
level is greater than or equal to x.
The /MF parameter forces REHASH to make the users file size at
least z times the required size. So, if the users file requires
space for 100 users, using /MF1.5 causes REHASH to make the file at
least 150 records.
The /EU parameter tells REHASH to leave room for at least m more
users than is required.
/EU and /MF can be used together.
If /MF and /EU are omitted, REHASH will leave room for at least 8
additional users (equivalent to /EU8).
Examples
--------
a. REHASH MainM.DEF MainU.DEF /OT60 /EL10
Delete users from the main board who haven't been on in two
months (and whose security level is less than 10)
b. REHASH TrekM.DEF TrekU.DEF
Resize the users file to whatever is necessary, and leave
all user records intact.
c. REHASH SysopM.DEF SysopU.DEF /EU2
Leave all users intact, and only leave room for two additional
users.
Notes
-----
1. REHASH writes to the CONS: device, so it can be run remotely from
RBBS on an "exit to DOS" jump.
2. If RBBS reports insufficient space in a given users file, try
raising the /EU or /MF values.
3. The '/' parameters can be in any order, but the messages and users
file names have to be the first two parameters.
Source Code
-----------
The source code, written in MicroSoft QuickBASIC, is included.
Errors
------
REHASH first reads the specified users file, and figures out the
number of records it thinks will be required to resize your file. It
then tries resizing with that number. If it can't fit all of the
users into that size users file, it tries the next higher size. So,
if you see that it "fails" at resizing, don't worry. It'll just go on
and try again (up to a limit, of course).
What's New with v1.30
---------------------
REHASH v1.30 is yet another bug-fix release. It turns out that REHASH
v1.21's method of removing users could cause RBBS to not find other
users! The result was a users file full of duplicate users, with
people "disappearing" for no apparent reason. Now, REHASH also
includes code to remove duplicate users from the users file... so
v1.30 fixes the mess that v1.21 created.
What's New with v1.21
---------------------
REHASH v1.21 fixes a bug in v1.10 that would cause REHASH to keep old
users in the users list if it never had to change the file size. Now,
old users are always purged, whether or not the users file is
"rehashed." Also, REHASH's method of determining how long it's been
since a user was on was imprecise, to say the least (all screwed up,
to say the most). That's now fixed.
Bugs
----
If you run into bugs, please point them out to me. I can be reached
at the MSFA BBS, FidoNet 1:261/1047, 1-301-536-1935.
Guarantees
----------
If you always back up your RBBS system files before using REHASH,
you'll never lose data...
Good luck!
-- Tom Collins