From owner-freebsd-net@FreeBSD.ORG Tue Jun 1 02:47:33 2004 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CF36516A4D0 for ; Tue, 1 Jun 2004 02:47:33 -0700 (PDT) Received: from smtp.atlantis.dp.ua (smtp.atlantis.dp.ua [193.108.46.231]) by mx1.FreeBSD.org (Postfix) with ESMTP id ACD3543D54 for ; Tue, 1 Jun 2004 02:47:31 -0700 (PDT) (envelope-from dmitry@atlantis.dp.ua) Received: from smtp.atlantis.dp.ua (smtp.atlantis.dp.ua [193.108.46.231]) by smtp.atlantis.dp.ua (8.12.6p2/8.12.6) with ESMTP id i519lEAb083851 for ; Tue, 1 Jun 2004 12:47:14 +0300 (EEST) (envelope-from dmitry@atlantis.dp.ua) Date: Tue, 1 Jun 2004 12:47:14 +0300 (EEST) From: Dmitry Pryanishnikov To: freebsd-net@freebsd.org Message-ID: <20040601120238.B44353@atlantis.atlantis.dp.ua> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Subject: net.inet.ip.portrange.randomized=1 hurts X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Jun 2004 09:47:33 -0000 Hello! I've tried to install 4.10-RELEASE via FTP several times, but every time (earlier or later) FTP transfers were aborted with code "425 Failed to establish connection.", and FTP site selection menu popped up again. My FTP server is vsftpd-1.2.2 server built from fresh ports on 4.7-RELEASE system. First rule of firewall allows all traffic to and from my test machine on which I'm trying to install 4.10-RELEASE. Finally I have found what happens. Sometimes FTP client opens the same port for data which was used several seconds ago, and passes it to the server via PORT command. On client's side, this port is already free, but on server side it's steel in TIME_WAIT state. So server tries to open connection server.20 -> client.PORT and apparently gets an error indication from kernel because address is still in use. The main question is: how to prevent this situation? Of course, as a workaround I can set net.inet.ip.portrange.randomized to zero, but what's the real solution? Is it FTP-client or FTP-server that should take care of the previous DATA port usage? Or even network stack behaviour should be further modified to avoid this collision? Sincerely, Dmitry -- Atlantis ISP, System Administrator e-mail: dmitry@atlantis.dp.ua nic-hdl: LYNX-RIPE