Viktor Dukhovni:
> On Tue, Jan 15, 2013 at 11:35:14PM +0800, Fred Ho wrote:
>
> > Hi Wietse,
> > I have already asked the ISP, they said it's not the problem on
> > their side. It's mailgate2 our receiving side that is slow.The
> > postfix 2.5.6 running in mailgate2 does not turn on any header_check,
> > body_check checking. Plainly delivery to the backend.
>
> In other words they told you to go away and stop bothering them.
> The real issue is that neither MTA is "slow". What is slow is almost
> certainly the transmission of the message payload across the network.
> You need to use tcpdump to capture inbound port 25 traffic:
>
> root# IP=192.0.2.1 # Replace with your MTA's IP
> root# tcpdump -s0 -w pkts.pcap \
> tcp and \
> "(" "(" dst port 25 and dst host $IP ")" or \
> "(" src port 25 and src host $IP ")" ")"
>
> let this run for 10 minutes, then hit "CTL-C" and look at the
> capture file. Note any retransmissions, and how quickly data is
> arriving over the network, and whether your TCP is every closing
> the TCP window, or whether bandwidth is low even though your TCP
> window is wide open. Be aware that window scaling may be in place,
> and is perhaps mishandled by a broken firewall (or when you read
> the TCP capture without seeing the initial handshake, in addition
> to the long sessions already in progress look at the window-scaling
> negotiated by new sessions).
Victor has an excellent point.
You can quickly eliminate TCP window scaling issues by dumbing down
Postfix thusly:
# postconf -e master_service_disable=inet
# postfix reload
# postconf -e tcp_windowsize=65535 master_service_disable=
# postfix reload
You need to execute all four commands in the given order.
(You can also eliminate TCP window scaling issues with kernel
configuration).
Wietse