SETSPDIR(8)

NAME
setspdir - tidy up or redistribute GNUspool jobs into subdirectories

SYNOPSIS
setspdir [ -s n ] [ -r ] [ -d ] [ -f form ] [ -y ]

DESCRIPTION
setspdir tidies up the GNUspool spool directory, removing old spool files, or alternatively re-queuing them with a given default form type, and eliminating jobs where the spool file is missing.

Optionally, it may be used to split the main spool directory into a series of subdirectories 000, 001 etc, reducing the size of the main spool directory to manageable proportions and also speeding up file searches. Alternatively, the subdirectories may be linked to different file systems by the user.

For reasonably obvious reasons, setspdir should be run with the spooler shut down.

OPTIONS

-d  Clear (delete) any orphaned job files found in the directory or directories.

-f form
    Requeue any orphaned job files with the form type form rather than deleting them.

-r  Instead of moving jobs between subdirectories, renumber the jobs instead. This should only apply when there were existing subdirectories, and the number is being increased.

-s n
    Split the spool directory into n subdirectories, or change the number of subdirectories to n, where n may be 0 (to convert back to a single spool directory), or a number up to 999.

    We recommend that n be a prime number, as this minimises the chance of a cycle of operations which is a factor of the number of subdirectories causing just a small number of subdirectories to be filled more or less exclusively. Confirmation will be requested if n is not prime.

    The subdirectories are given the names 000 to 999, and each job will be moved to a subdirectory given by the remainder when its job number (the number after the "SP") is divided by the number of subdirectories.

-y  Answer "yes" to any questions which setspdir asks.

ENVIRONMENT
setspdir creates or updates the environment variable "SPOOLSUBDS" in /etc/gnuspool.conf.

SPOOLDIR
    location of spool directory

SPOOLSUBDS
    number of subdirectories

SEE ALSO
cjlist(8), cplist(8), spuconv(8), gnuspool.conf(5).

AUTHOR
John M Collins, Xi Software Ltd.