[Pkg-clamav-devel] Bug#600908: Bug#600908: Improvement to clamav-milter init script
Stephen Gran
sgran at debian.org
Fri Oct 22 15:30:44 UTC 2010
This one time, at band camp, Chris Moules said:
> We have recently experienced the case that clamav-milter was 'running'
> but the socket file was missing. This caused our mail system (postfix)
> to reject mail with a temporary error.
>
> Monitoring the service by checking the return code from
> '/etc/init.d/clamav-milter status' did not catch this situation.
>
> I have updated the 'status' check to include a check for the sockets
> existence and an alternate error code (LSB correct, I believe). See
> attached patch.
>
> The patch also fixes the call to 'status_of_proc' with the variable
> $BASENAME in place of $NAME (which does not exist). It also moves the
> 'local' copy of the function 'status_of_proc' below the sourcing of
> '/lib/lsb/init-functions' so that this version of the function gets
> called. Before, this local copy of the function was just unused code
> in the init script. This local copy of the LSB function now checks the
> existence of the clamav-milter socket as defined in '$SOCKET_PATH'.
Hi,
Thanks for the patch. The status_of_proc function definition is only
there for backports to older systems where the lsb_base stuff doesn't
define it. It's designed to be overridden when possible. I'd like to
leave it that way as much as possible, so we may rework your patch
somewhat, but the idea is a good one.
Cheers,
--
-----------------------------------------------------------------
| ,''`. Stephen Gran |
| : :' : sgran at debian.org |
| `. `' Debian user, admin, and developer |
| `- http://www.debian.org |
-----------------------------------------------------------------
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-clamav-devel/attachments/20101022/450cb6f2/attachment.pgp>
More information about the Pkg-clamav-devel
mailing list