I was thinking about implementing Courier support for AMaViS-ng, so I
started playing around with perlfilter.
But I have had no luck so far, at least with the Debian package of
courier-mta (0.37-5). So, I started out with the supplied example
which is installed to
/usr/share/doc/courier-mta/examples/perlfilter-example.pl by the
Debian package.
I did an
# echo /usr/share/doc/courier-mta/examples/perlfilter-example.pl >
/etc/courier/filters/perlfilter
and
# filterctl start perlfilter
After restarting courierfilter by doing
# courierfilter stop
# courierfilter start
...CPU usage goes up quite a bit, but monitoring the process list
shows that the perlfilter processes don't live a very long life. They
die like flies, so that the controlling process has quite a bit of
work to do in order to bury its dead children.
The syslog shows a LOT of those:
,----
| perlfilter: Child process 22079 terminated - restarting.
`----
Testing the example script with
# perl -c /usr/share/doc/courier-mta/examples/perlfilter-example.pl
showed that it is at least syntactically correct.
A socket /var/lib/courier/filters/perlfilter has been created,
communication should not be a problem.
Where might the problem be, or are there ways to enable more
diagnostics?
-Hilko