From owner-freebsd-stable@FreeBSD.ORG Thu Feb 17 21:07:06 2011 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EDE57106567A for ; Thu, 17 Feb 2011 21:07:06 +0000 (UTC) (envelope-from ml@netfence.it) Received: from cp-out8.libero.it (cp-out8.libero.it [212.52.84.108]) by mx1.freebsd.org (Postfix) with ESMTP id 7BA7E8FC20 for ; Thu, 17 Feb 2011 21:07:06 +0000 (UTC) X-CTCH-Spam: Unknown X-CTCH-RefID: str=0001.0A0B0205.4D5D8DF8.0208,ss=1,re=0.000,fgs=0 X-libjamoibt: 1555 Received: from soth.ventu (151.51.49.89) by cp-out8.libero.it (8.5.133) id 4D0F2C9809198FE7 for freebsd-stable@freebsd.org; Thu, 17 Feb 2011 22:07:04 +0100 Received: from alamar.ventu (alamar.ventu [10.1.2.18]) by soth.ventu (8.14.4/8.14.4) with ESMTP id p1HL6url046763 for ; Thu, 17 Feb 2011 22:06:56 +0100 (CET) (envelope-from ml@netfence.it) Message-ID: <4D5D8DF0.8080900@netfence.it> Date: Thu, 17 Feb 2011 22:06:56 +0100 From: Andrea Venturoli User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; it-IT; rv:1.9.2.13) Gecko/20101211 Thunderbird/3.1.7 MIME-Version: 1.0 To: freebsd-stable@freebsd.org References: <201102091420.p19EKJ5u001268@m5p.com> <20110217032858.GA17686@icarus.home.lan> In-Reply-To: <20110217032858.GA17686@icarus.home.lan> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.68 on 10.1.2.13 Subject: Re: statd/lockd startup failure X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Feb 2011 21:07:07 -0000 On 02/17/11 04:28, Jeremy Chadwick wrote: > On Wed, Feb 16, 2011 at 09:46:37PM -0500, Michael Proto wrote: >> On Wed, Feb 9, 2011 at 9:20 AM, wrote: >>> Under 8.2-PRERELEASE (GENERIC kernel), about 15% of the times I boot up >>> (with rpc.statd and rpc.lockd enabled in rc.conf), I get: >>> >>> Feb 4 07:31:11 wonderland rpc.statd: bindresvport_sa: Address already in use >>> Feb 4 07:31:11 wonderland root: /etc/rc: WARNING: failed to start statd >>> >>> and slightly later: >>> >>> Feb 4 07:31:36 wonderland kernel: NLM: unexpected error contacting NSM, stat=5, errno=35 >>> >>> I can start rpc.statd and rpc.lockd manually at this point (and I have to >>> start them to run firefox and mail with my NFS-mounted home directory and >>> mail spool). But what might cause the above errors? -- George Mitchell >>> >>> _______________________________________________ >>> freebsd-stable@freebsd.org mailing list >>> http://lists.freebsd.org/mailman/listinfo/freebsd-stable >>> To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org" >>> >> >> Don't rpc.statd and lockd try to choose a random port upon startup? Yes, by default. > I >> seem to remember a similar problem I had a long time ago. I opted to >> use a consistent, not-used port and haven't seen the problem since >> (this was years ago, so I can't remember if the error you're seeing >> was identical to mine). >> >> /etc/rc.conf: >> rpc_statd_flags="-p 898" >> rpc_lockd_flags="-p 4045" I have: rpc_statd_flags="-p 918" rpc_lockd_flags="-p 868" Still statd occasionally fails to start. It might be that something else has already bound to port 918, though I don't know what. I'll check as soon as I have the chance. > Locking down the port numbers as you showed is the best choice, plus > allows for proper firewall rules to be added. However, be aware not all > daemons support this. Reliable firewall rules for NFS = good luck. Since I put the above in rc.conf, I've had more problems with NFS and ipfw. I also vaguely remember some daemons having hooks to open ipfw ports dinamically. bye & Thanks av.