From owner-freebsd-current@FreeBSD.ORG Tue Feb 19 16:20:20 2008 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7BC9F16A420 for ; Tue, 19 Feb 2008 16:20:20 +0000 (UTC) (envelope-from LoN_Kamikaze@gmx.de) Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by mx1.freebsd.org (Postfix) with SMTP id DC34513C467 for ; Tue, 19 Feb 2008 16:20:19 +0000 (UTC) (envelope-from LoN_Kamikaze@gmx.de) Received: (qmail invoked by alias); 19 Feb 2008 16:20:18 -0000 Received: from nat-wh-1.rz.uni-karlsruhe.de (EHLO mobileKamikaze.norad) [129.13.72.169] by mail.gmx.net (mp028) with SMTP; 19 Feb 2008 17:20:18 +0100 X-Authenticated: #5465401 X-Provags-ID: V01U2FsdGVkX19Ai10zCd5AjxvJpDUI41c5dufv32H23sWrGBahdj irjd6sKxtrj4d1 Message-ID: <47BB01BE.4010309@gmx.de> Date: Tue, 19 Feb 2008 17:20:14 +0100 From: Dominic Fandrey User-Agent: Thunderbird 2.0.0.9 (X11/20080205) MIME-Version: 1.0 To: Eygene Ryabinkin References: <47BADE07.9020402@gmx.de> <7CZsNG/ix1SXULta6Bdgf51ZwDE@TqmFlxFMySuiJ36EgnrGRgt6KQ8> In-Reply-To: <7CZsNG/ix1SXULta6Bdgf51ZwDE@TqmFlxFMySuiJ36EgnrGRgt6KQ8> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Y-GMX-Trusted: 0 X-Mailman-Approved-At: Tue, 19 Feb 2008 18:35:40 +0000 Cc: freebsd-current@freebsd.org Subject: Re: nfs mounts don't work through fstab X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Feb 2008 16:20:20 -0000 Eygene Ryabinkin wrote: > Dominic, good day. > > Tue, Feb 19, 2008 at 02:47:51PM +0100, Dominic Fandrey wrote: >> My nfs mounts haven't been working by their fstab entries, ever since I >> switched to RELENG_7. Today I took the time tracking the issue down by >> adding lots of printf to mount.c. I tracked the problem down to the >> function >> fstabscan() in the file "/usr/src/lib/libc/gen/fstab.c". >> >> The result of my testing was that it is now obligatory to set 'sw', 'ro' or >> 'rw' in the options list. > > Could you, please, show your /etc/fstab? I see that lib/libc/gen/fstab.c > was last changed 4 years ago (not counting revision 1.15, where the > advertising license clause was removed), so perhaps fstabscan() is > not guilty. > > Thank you! These 2 lines have been in use since 6.0 release: mobileKamikaze:/usr/src /usr/src nfs -b,-T,-R=5,noauto 0 0 mobileKamikaze:/usr/obj /usr/obj nfs -b,-T,-R=5,noauto 0 0 They stopped working with the switch to RELENG_7. # mount /usr/src/ 0 /root fstab: /etc/fstab:27: Inappropriate file type or format fstab: /etc/fstab:28: Inappropriate file type or format fstab: /etc/fstab:27: Inappropriate file type or format fstab: /etc/fstab:28: Inappropriate file type or format mount: /usr/src: unknown special file or file system fstabscan() is the place where the "Inappropriate file type or format" error is printed. The pointer char* cp either points to a string "rw", "ro" or "sw". If none of these are present cp is a NULL-pointer when the final check in line 207 is reached. So error(EFTYPE) is called.