Guide On How To install Qmhandle On FreeBSD

Guide On How To install Qmhandle On FreeBSD 2017-08-21T12:31:24+00:00

A Step By Step Guide On How To Install Qmhandle On FreeBSD
Qmhandle is a small program that allows you to view and modify Qmails mail queue. Installing qmhandle is quite easy and we will do this from ports.

cd /usr/ports/mail/qmhandle && make install clean

If you installed qmail by following the the guide on this site you will need to edit qmhandle’s configuration file located here /usr/local/etc/qmHandle.conf

Find these 2 lines.

# For instance, this is if you have DJB's daemontools
#our ($stopqmail) = '/usr/local/bin/svc -d /service/qmail-deliver';
#our ($startqmail) = '/usr/local/bin/svc -u /service/qmail-deliver';

Replace them with the following i.e remove the # and replace deliver with send like below.

# For instance, this is if you have DJB's daemontools
our ($stopqmail) = '/usr/local/bin/svc -d /service/qmail-send';
our ($startqmail) = '/usr/local/bin/svc -u /service/qmail-send';

Next find these 2 lines.

# This is if you have FreeBSD with its qmail package
our ($stopqmail) = '/usr/local/etc/rc.d/qmail.sh stop';
our ($startqmail) = '/usr/local/etc/rc.d/qmail.sh start';

Add a # in front of these 2 lines like this.

# This is if you have FreeBSD with its qmail package
#our ($stopqmail) = '/usr/local/etc/rc.d/qmail.sh stop';
#our ($startqmail) = '/usr/local/etc/rc.d/qmail.sh start';

Optional.
If you don’t want qmHandle to use pgrep for terminating qmail you can use of pidof. In order to use pidof we need to install pidof first.

cd /usr/ports/sysutils/pidof && make install clean

Now edit the qmhandle configuration file located here /usr/local/etc/qmHandle.conf

Find this line.

#our ($pidcmd) = 'pidof qmail-send';

And remove the # like this.

our ($pidcmd) = 'pidof qmail-send';

And finally find this line.

our ($pidcmd) = 'pgrep qmail-send';

And add a # in front of the line like this.

# our ($pidcmd) = 'pgrep qmail-send';

Note.
Some people claim they cant locate qmhandle. It’s most likely because they are not spelling it with a capital “H” i.e qmHandle.

And we are done here.

Spell checkers don’t – Grammar checkers don’t either.