smdemon.cleanu Command

Purpose

Cleans up the sendmail queue for periodic housekeeping.

Syntax

/usr/lib/smdemon.cleanu

Description

The smdemon.cleanu command is a shell procedure that cleans up the sendmail command queue and maintains the /var/spool/mqueue/log file.

To enable the smdemon.cleanu command, you must remove the comment statement by deleting the # character from the beginning of the smdemon.cleanu line in the /var/spool/cron/crontabs/root file. If the /var/spool/mqueue directory does not exist, do not change the /var/spool/cron/crontabs/root file.

Be careful that the average size of a log file for each smdemon.cleanu session multiplied by the number of log files does not use more space than you need. You can arrange the number of log files to suit your needs.
Note: The smdemon.cleanu command is not usually entered on the command line. The command is executed by the cron daemon.

Examples

To run the smdemon.cleanu procedure automatically, edit the /var/spool/cron/crontabs/root file and delete the # (comment character) from the beginning of the smdemon.cleanu line as follows:

# ulimit 5000; /usr/lib/smdemon.cleanu > /dev/null

Files

Item Description
/var/spool/cron/crontabs/root Schedules when the smdemon.cleanu command will run.
/var/spool/mqueue Contains the log file and temporary files associated with the message in the mail queue.