<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>205097</bug_id>
          
          <creation_ts>2008-01-09 17:31 0000</creation_ts>
          <short_desc>mail-filter/dkim-milter-2.4.2 fails to start with stale socket</short_desc>
          <delta_ts>2008-01-24 16:40:54 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Server</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>minor</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>rtpsld@ntsel.com</reporter>
          <assigned_to>dragonheart@gentoo.org</assigned_to>
          <cc>mrness@gentoo.org</cc>

      

      
          <long_desc isprivate="0">
            <who>rtpsld@ntsel.com</who>
            <bug_when>2008-01-09 17:31:27 0000</bug_when>
            <thetext>After an unclean shutdown (power outage), dkim-milter fails to start with the following log entries:

dkim-filter[6118]: Sendmail DKIM Filter: Unable to bind to port local:/var/run/dkim-filter/dkim-filter.sock: Address already in use
dkim-filter[6118]: Sendmail DKIM Filter: Unable to create listening socket on conn local:/var/run/dkim-filter/dkim-filter.sock
dkim-filter[6118]: smfi_opensocket() failed

Problem is solved by manually performing:
# rm /var/run/dkim-filter/dkim-filter.sock
# /etc/init.d/dkim-filter start

I didn&apos;t see any dkim-filter options to force socket creation - would it make sense for the init script to handle this condition?</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>mrness@gentoo.org</who>
            <bug_when>2008-01-09 19:58:22 0000</bug_when>
            <thetext>We must be sure there is no dkim-filter process that use the socket before removing it.
Daniel, any idea? I thought at fuser, but it sucks to add psmisc to RDEPEND just for that... </thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>dragonheart@gentoo.org</who>
            <bug_when>2008-01-09 21:52:40 0000</bug_when>
            <thetext>inital very quick thoughts

push a milter stop command down the socket? 
https://www.milter.org/developers/api/smfi_stop

implement your own find on /proc for the socket

though i&apos;d try to look how other processes do it first.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>mrness@gentoo.org</who>
            <bug_when>2008-01-24 11:41:16 0000</bug_when>
            <thetext>Fixed in 2.4.3. 
I used fuser because psmisc is part of the system packages.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>rtpsld@ntsel.com</who>
            <bug_when>2008-01-24 16:40:54 0000</bug_when>
            <thetext>2.4.3 works for me and starts up cleanly now even with an old socket present.  Thanks for the update.

</thetext>
          </long_desc>
      
    </bug>

</bugzilla>