This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

SMTP Timeout

Hello,
 
we have a problem with SMTP Timeouts, and it has been a general problem during the last year of running the system.
 
We have ensured that the link and speed of NIC is good. But we miss an option to be able to set the SMTP Timeout. Problem as we see it; one message arrives at the GW, when it tries to connect to the server it should deliver it to it gets a timeout, after several timeouts the server is auto-blacklisted, and it becomes a problem for all messages arriving to specific servers. The timeout for the servers to be auto-whitelisted can vary - depends on the load. It not a thing we see every day, but yet too often to just let pass un-noticed.
 
We are running a large site, where approximately somewhere between 200.000 and 300.000 mails pr. month is being handled. The load is shared between two servers (Sun Fire V20z - They are listen in servers approved to run Astaro) and they primarily only handles ingoing mail. Outgoing mail is handled by seperate SMTP servers.
 
Short output from log: SEE ATTACHMENT (astaro_smtp_timeout.txt).
 
 
Our latets configuration is ASL 6.311 (patch to 6.312 is planned within a couple of weeks).
 
Any input, comments or help at all are very much appreciated.
 
Best regards
 
Yngve Berthelsen
UNIX and SAN Consultant


This thread was automatically locked due to age.
Parents
  • Have you verified the following?

    1. That the mail servers in question are actually running and accepting connections?
    2. That you don't have a bandwidth issue?

    I was only able to connect to 1 out of 3 servers listed in your log file.
  • About migrating to version 7, can we use the license for version 6 with version 7?
     
    The mail servers accepting mails are not the problem, they accept mail just fine.
    Bandwith issue can be hard to define, as we have a 70Mbit connection. It depends on how the load is shared between the different services being used in the organization. I will try to investigate with the network division.
     
    About connecting to the mail server. It is a design within the firewall configuration that only one or two IP addresses accepts SMTP connections, and that will be the astaro servers. All mailserver are only allowed SMTP access from the astaro server (basic security ;-) )
     
    /Yngve
  • If your Maintenance is current, your reseller, Astaro, and probably yourself, in the my.astaro.com portal, can "upgrade" your V6 license to Version 7.  I also believe the old V6 license actually still loads just fine on a Version 7 installation ... in fact I'm rather sure of it.  In any event, with an active Maintenance subscription (silver, gold, or platinum) you are automatically entitled to an upgraded license.  I upgraded all these licenses for my customers over the past year or so; in fact, when I create a new license, it default to Version 6, and I have to "upgrade" it to Version 7 before sending the customer their new license key(s).

    CTO, Convergent Information Security Solutions, LLC

    https://www.convergesecurity.com

    Advice given as posted on this forum does not construe a support relationship or other relationship with Convergent Information Security Solutions, LLC or its subsidiaries.  Use the advice given at your own risk.

  • About connecting to the mail server. It is a design within the firewall configuration that only one or two IP addresses accepts SMTP connections, and that will be the astaro servers. All mailserver are only allowed SMTP access from the astaro server (basic security ;-) )

    I feel like you are leaving out critical details of your setup and where mail is being failed to delivered. Perhaps you can describe the whole setup in more detail.
  • The design for all mail traffic is within the firewall, that only the mailgateways are allowed smtp traffic on port 25 on the in and outgoing, that means, that one can not deliver mail directly to the mail server handling the users. The firewall is set up, so only the mail gateways can deliver mails to the different mail servers.
    In this case, we are not using the Astaro boxes as firewall, they only handle mails. Firewalls are cisco products.
     
    The post about connecting to the mailserver..... was an answer to the note:
     
    "I was only able to connect to 1 out of 3 servers listed in your log file. "
     
    /Yngve
  • So I guess that no one has any solutions on this SMTP timeout problem?
  • We have now modified the TCP/IP stack inside the Linux system, as a lot were pointing ín that direction. So far it looks good.
     
    /etc/sysctl.conf:
    # increase TCP max buffer size setable using setsockopt()
    net/core/rmem_max = 16777216
    net/core/wmem_max = 16777216
    # increase Linux autotuning TCP buffer limits
    # min, default, and max number of bytes to use
    # set max to at least 4MB, or higher if you use very high BDP paths
    net/ipv4/tcp_rmem = 8192 873800 16777216
    net/ipv4/tcp_wmem = 4096 655360 16777216
    # don't cache ssthresh from previous connection
    net/ipv4/tcp_no_metrics_save = 1
    net/ipv4/tcp_moderate_rcvbuf = 1
    net/ipv4/tcp_max_syn_backlog = 8192
Reply
  • We have now modified the TCP/IP stack inside the Linux system, as a lot were pointing ín that direction. So far it looks good.
     
    /etc/sysctl.conf:
    # increase TCP max buffer size setable using setsockopt()
    net/core/rmem_max = 16777216
    net/core/wmem_max = 16777216
    # increase Linux autotuning TCP buffer limits
    # min, default, and max number of bytes to use
    # set max to at least 4MB, or higher if you use very high BDP paths
    net/ipv4/tcp_rmem = 8192 873800 16777216
    net/ipv4/tcp_wmem = 4096 655360 16777216
    # don't cache ssthresh from previous connection
    net/ipv4/tcp_no_metrics_save = 1
    net/ipv4/tcp_moderate_rcvbuf = 1
    net/ipv4/tcp_max_syn_backlog = 8192
Children
  • We also changed these setting in /var/chroot-smtd/etc/exim.conf:
     
    smtp_receive_timeout = 15m
    timeout_frozen_after = 3d

    We haven't had any SMTP Timeout since we tuned the TCP/IP stack.
     
    Though we do get a lot of SMTP Command and also Data timeout, we have tried to fix that with the SMTP Receive timeput, by going from 5m to 15m.