wishmaster: > Hi! > > I have strange behavior of Postfix (postfix-2.11.1_1,1) > > I use FreeBSD as base system and some jails. Each jail use > virtual network stack (vnet). Problem is in latency when > connection is outside from the base system only. > > telnet localhost 25 works fine, but if this connection or from > jail or from LAN it is latency about 10 seconds before I see 220 > example.com.ua ESMTP Postfix
Is that 10 seconds to establish a TCP connection? The telnet client looks up the destination host address, and your host may be configured to query DNS before searching /etc/hosts. With a bad /etc/resolv.conf file, or with bad firewalling/routing for DNS queries/replies, that causes delays, typically a multiple of 5 seconds (RES_TIMEOUT=5). Is that 10 seconds for Postfix to respond after TCP completes? This is typically the result of a bad /etc/resolv.conf file, but may also be caused by bad firewalling/routing for DNS queries/replies, typically causing delays of a multiple of 5 seconds (RES_TIMEOUT=5). So the proceduce is: 1) Disable chroot in master.cf (all columns 5 = "n") and "postfix reload". 2) Check your /etc/resolv.conf. 3) Check your /etc/host.conf and /etc/nsswitch.conf. Wietse