dkim-filter problem - can't read SMFIC_OPTNEG reply packet header

Discussion in 'Server Operation' started by leonhongkong, Mar 21, 2009.

  1. leonhongkong

    leonhongkong New Member

    Hi. I use ubuntu 8.10 server 64 bit + postfix + dkim-filter + dovecot
    There is a problem with dkim-filter. I followed the instruction at https://help.ubuntu.com/community/Postfix/dkim-milter
    Everything worked fine until I ran apt-get upgrade.

    The dkim-filter didn't work. When I sent mail, syslog said
    Code:
    ...
    Mar 19 16:40:57 myubuntu postfix/smtpd[6166]:warning: milter inet:127.0.0.1:8891: can't read SMFIC_OPTNEG reply packet header: Connection timed out
    Mar 19 16:40:57 myubuntu postfix/smtpd[6166]: warning: milter inet:127.0.0.1:8891:read error in initial handshake
    ...
    The mail is sent successful but without dkim's header. Hotmail just send my mail directly to the junk folder :(



    when I tried to restart dkim-filter the syslog said
    Code:
    ...
    Mar 19 06:31:18 myubuntu dkim-filter[14604]: can't configure DKIM library; continuing
    Mar 19 06:31:18 myubuntu dkim-filter[14604]: Sendmail DKIM Filter v2.6.0 starting (args: -x /etc/dkim-filter.conf -p local)
    ...
    After restarted dkim-filter. It ran normally but didn't work with postfix!?!


    any idea to fix dkim-filter?
    Thanks.
     
  2. falko

    falko Super Moderator ISPConfig Developer

    What's the output of
    Code:
    netstat -tap
    ? Have you tried to restart dkim-filter?
     
  3. leonhongkong

    leonhongkong New Member

    "netstat -tap" output
    Code:
    Active Internet connections (servers and established)
    Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name
    tcp        0      0 *:imaps                 *:*                     LISTEN      14906/dovecot
    tcp        0      0 *:pop3s                 *:*                     LISTEN      10524/pop3-login
    tcp        0      0 localhost:mysql         *:*                     LISTEN      6859/mysqld
    tcp        0      0 *:netbios-ssn           *:*                     LISTEN      7104/smbd
    tcp        0      0 *:pop3                  *:*                     LISTEN      10524/pop3-login
    tcp        0      0 *:imap2                 *:*                     LISTEN      14906/dovecot
    tcp        0      0 *:webmin                *:*                     LISTEN      7482/perl
    tcp        0      0 *:www                   *:*                     LISTEN      7279/apache2
    tcp        0      0 *:ftp                   *:*                     LISTEN      7185/proftpd: (acce
    tcp        0      0 192.168.122.1:domain    *:*                     LISTEN      7059/dnsmasq
    tcp        0      0 myubuntu.xxx:domain *:*                     LISTEN      6745/named
    tcp        0      0 localhost:domain        *:*                     LISTEN      6745/named
    tcp        0      0 *:smtp                  *:*                     LISTEN      10761/master
    tcp        0      0 localhost:953           *:*                     LISTEN      6745/named
    tcp        0      0 localhost:8891          *:*                     LISTEN      10661/dkim-filter
    tcp        0      0 *:https                 *:*                     LISTEN      7279/apache2
    tcp        0      0 *:microsoft-ds          *:*                     LISTEN      7104/smbd
    tcp6       0      0 [::]:8009               [::]:*                  LISTEN      7375/jsvc
    tcp6       0      0 [::]:http-alt           [::]:*                  LISTEN      7375/jsvc
    tcp6       0      0 [::]:domain             [::]:*                  LISTEN      6745/named
    tcp6       0      0 localhost:953           [::]:*                  LISTEN      6745/named
     
    Last edited: Mar 22, 2009
  4. leonhongkong

    leonhongkong New Member

    These are what I had tried

    - update dkim-filter2.6 to dkim-filter2.8
    - bind dkim-filter's port from 8891 to 8892
    - change milter_protocol in /etc/postfix/main.cf from 2 to 3,4,6

    still no luck :confused:
     
  5. falko

    falko Super Moderator ISPConfig Developer

    Have you tried to restart dkim-filter (or reboot the whole system)?
     
  6. leonhongkong

    leonhongkong New Member

    yes, I tried.

    I don't know if my problem relate to
    Code:
    Mar 20 07:42:19 myubuntu deliver(root): mail_location not set and autodetection failed: Mail storage autodetection failed with home=/root
    Mar 20 07:42:19 myubuntu deliver(root): Fatal: Namespace initialization failed
    in /var/log/syslog which have appeared frequency.

    Nah,but I don't think "Namespace initialization failed" relate to dkim-filter
    :confused:
     
  7. falko

    falko Super Moderator ISPConfig Developer

    I don't know what's wrong here. :(
     
  8. falko

    falko Super Moderator ISPConfig Developer

  9. helpmhost

    helpmhost New Member

    I had the exact same problem. The cause (and solution) was that dkim does DNS lookups use TCP.

    Open your firewall to allow outbound TCP DNS queries (and allow the replies back in) and it should work.

    Martin
     

Share This Page