Postfix : Issue receiving gmail with attachment

Discussion in 'Server Operation' started by Sylvaner, Feb 2, 2017.

  1. Sylvaner

    Sylvaner New Member

    Hi,

    I have a postfix that work very well on front-end of an exchange server.
    Since 2 weeks, emails from Gmail (and few others domains) with attachment > 4MB does not arrive, and after a long period of time, the sender receives an undeliverable mail with the error message "write error: generic::deadline_exceeded: write timeout (180000ms)"
    We tried to rebuild a new server and the problem is still there (and still works well with the other domains).

    Below the logs from /var/log/maillog : (the messages listed below appear after a certain period of time)
    Code:
    timeout after DATA (179151 bytes) from mail-wj0-f193.google.com[209.85.210.193]
    
    We have set log in verbose mode, and the log stops at this point :
    Code:
    postfix/cleanup[9013]: cleanup_header_callback: 'X-Attachment-Id: f_iyo78pi70'
    
    We changed these parameters without success :
    Code:
    header_size_limit
    message_size_limit
    smtp_data_xfer_timeout
    smtp_data_init_timeout
    
    Did anyone had the same problem and found a solution, or any idea how to resolve this issue.
    Any suggestions are welcome.

    Thx

    main.cf :
    Code:
    mydomain = XXXXX.fr
    myhostname = srv-test.XXXXX.fr
    mydestination = XXXXX.fr, YYYYYY.fr
    mynetworks = 127.0.0.0/8, 172.16.0.0/16
    relay_domains = $mydestination
    smtpd_recipient_restrictions = permit_mynetworks,
                                   reject_unauth_destination,
                                   reject_invalid_hostname,
                                   reject_unauth_pipelining,
                                   reject_non_fqdn_sender,
                                   reject_unknown_recipient_domain,
                                   reject_unknown_sender_domain
    transport_maps = hash:/etc/postfix/transport
    local_recipient_maps =
    content_filter = smtp-amavis:[127.0.0.1]:10024
    virtual_alias_maps = hash:/etc/postfix/virtual
    
    master.cf
    Code:
    # ==========================================================================
    # service type  private unpriv  chroot  wakeup  maxproc command + args
    #  (yes)  (yes)  (yes)  (never) (100)
    # ==========================================================================
    smtp  inet  n  -  n  -  -  smtpd -v
    pickup  fifo  n  -  -  60  1  pickup
      -o content_filter=
      -o receive_override_options=no_header_body_checks
    smtp-amavis  unix  -  -  -  -  2  smtp -v
      -o smtp_data_done_timeout=1200
      -o smtp_send_xforward_command=yes
      -o disable_dns_lookups=yes
      -o max_use=20
    127.0.0.1:10025 inet  n  -  -  -  -  smtpd -v
      -o content_filter=
      -o local_recipient_maps=
      -o relay_recipient_maps=
      -o smtpd_restriction_classes=
      -o smtpd_delay_reject=no
      -o smtpd_client_restrictions=permit_mynetworks,reject
      -o smtpd_helo_restrictions=
      -o smtpd_sender_restrictions=
      -o smtpd_recipient_restrictions=permit_mynetworks,reject
      -o smtpd_data_restrictions=reject_unauth_pipelining
      -o smtpd_end_of_data_restrictions=
      -o mynetworks=127.0.0.0/8
      -o smtpd_error_sleep_time=0
      -o smtpd_soft_error_limit=1001
      -o smtpd_hard_error_limit=1000
      -o smtpd_client_connection_count_limit=0
      -o smtpd_client_connection_rate_limit=0
      -o receive_override_options=no_header_body_checks,no_unknown_recipient_checks
    cleanup  unix  n  -  n  -  0  cleanup -v
    qmgr  unix  n  -  n  300  1  qmgr
    tlsmgr  unix  -  -  n  1000?  1  tlsmgr
    rewrite  unix  -  -  n  -  -  trivial-rewrite
    bounce  unix  -  -  n  -  0  bounce
    defer  unix  -  -  n  -  0  bounce
    trace  unix  -  -  n  -  0  bounce
    verify  unix  -  -  n  -  1  verify
    flush  unix  n  -  n  1000?  0  flush
    proxymap  unix  -  -  n  -  -  proxymap
    proxywrite unix -  -  n  -  1  proxymap
    smtp  unix  -  -  n  -  -  smtp
    relay  unix  -  -  n  -  -  smtp
    showq  unix  n  -  n  -  -  showq
    error  unix  -  -  n  -  -  error
    retry  unix  -  -  n  -  -  error
    discard  unix  -  -  n  -  -  discard
    local  unix  -  n  n  -  -  local
    virtual  unix  -  n  n  -  -  virtual
    lmtp  unix  -  -  n  -  -  lmtp
    anvil  unix  -  -  n  -  1  anvil
    scache  unix  -  -  n  -  1  scache
    
     

Share This Page