Synchronet v3.19b-Win32 (install) has been released (Jan-2022).

You can donate to the Synchronet project using PayPal.

This is an old revision of the document!


Table of Contents

SMBUTIL

The SMBUTIL can be used for several things, but most importantly, it must be used for maintaining your Synchronet message base (using the 'm' command). This command causes SMBUTIL to mark old messages, and messages over the maximum sub-board limit, as deleted so that their spaces can be used by new messages. If you are using the 'Hyper Allocation' or 'Fast Allocation' method for your message bases, you must also use this utility to pack your message bases (using the 'p' command) periodically. The pack command causes SMBUTIL to compress the message bases removing any unused spaces (messages marked as deleted).

SMBUTIL maintenance and/or packing should be done using your daily event (or after importing from a network such as FidoNet). If your message base is using the 'Fast Allocation' or 'Hyper Allocation' storage methods, you should run maintenance before packing (there is no reason to pack if you do not run maintenance!). If your message base is set up for the 'Self Packing' method, you do NOT need to use SMBUTIL to pack, only to perform maintenance.

Usage

smbutil [/opts] cmd <filespec.SHD>

cmd

-l[n]      list messages starting at number n
-r[n]      read messages starting at number n
-x[n]      dump message index at number n
-v[n]      view message headers starting at number n
-i<f>      import from text file f (or use stdin)
-e<f>      import e-mail from text file f (or use stdin)
-n<f>      import netmail from text file f (r use stdin)
-h         dump hash file
-s         display message base status
-c         change message base status
-d         delete all messages
-m         maintain message base - delete old messages and messages over max
-p[k]      pack message base (k specifies minimum packable Kbytes)

opts

-c[m]      create message base if it doesn't exist (m=max messages)
-a         always pack message base (disable compression analysis)
-i         ignore dupes (do not store CRCs or search for duplicate hashes)
-d         use default values (no prompt) for to, from, and subject
-l         LZH-compress message text
-o         print errors on stdout (instead of stderr)
-p         wait for keypress (pause) on exit
-!         wait for keypress (pause) on error
-b         beep on error
-t<s>      set 'to' user name for imported message
-n<s>      set 'to' netmail address for imported message
-u<s>      set 'to' user number for imported message
-f<s>      set 'from' user name for imported message
-e<s>      set 'from' user number for imported message
-s<s>      set 'subject' for imported message
-z[n]      set time zone (n=min +/- from UT or 'EST','EDT','CST',etc)
-#         set number of messages to view/list (e.g. -1)

Examples

for maintenance and packing (100k or more per sub):

SMBUTIL mp100 /sbbs/data/subs/*.shd

for maintenance only (self-packing sub-boards):

SMBUTIL m /sbbs/data/subs/*.shd

WARNING: All BBS nodes should be DOWNed (offline) when using SMBUTIL with the pack option! To do this, set the SMBUTIL event to be 'Exclusive' in the SCFG program.

When using the pack command, SMBUTIL will check to see if it is necessary for you to pack your message base, if you want to skip this checking and have it unconditionally pack the message base (useful when attempting to repair a corrupted message base), you should add the '/a' switch to the command line:

SMBUTIL /a p /sbbs/data/subs/*.shd

The maintenance and pack commands are likely all that you will ever need to SMBUTIL for.

See Also