From owner-freebsd-current@FreeBSD.ORG Wed Feb 20 01:16:05 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 59ED016A400 for ; Wed, 20 Feb 2008 01:16:05 +0000 (UTC) (envelope-from sean@gothic.net.au) Received: from visi.gothic.net.au (unknown [IPv6:2001:388:f000::a25]) by mx1.freebsd.org (Postfix) with ESMTP id 17EE413C442 for ; Wed, 20 Feb 2008 01:16:05 +0000 (UTC) (envelope-from sean@gothic.net.au) Received: from localhost (localhost [127.0.0.1]) by visi.gothic.net.au (Postfix) with ESMTP id 631C1172296; Wed, 20 Feb 2008 12:18:30 +1100 (EST) X-Virus-Scanned: amavisd-new at gothic.net.au Received: from localhost ([127.0.0.1]) by localhost (visi.gothic.net.au [127.0.0.1]) (amavisd-new, port 10026) with SMTP id KMgFtqEqF+FN; Wed, 20 Feb 2008 12:18:27 +1100 (EST) Received: from [IPv6:2002:9665:9a11:1:21c:b3ff:febe:59cc] (unknown [IPv6:2002:9665:9a11:1:21c:b3ff:febe:59cc]) (Authenticated sender: sean) by visi.gothic.net.au (Postfix) with ESMTP id 3002217010C; Wed, 20 Feb 2008 12:18:27 +1100 (EST) Message-Id: <0FD9F726-6E45-4A81-9DE1-E3F0AAF3668B@gothic.net.au> From: Sean To: Dominic Fandrey In-Reply-To: <47BB01BE.4010309@gmx.de> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v919.2) Date: Wed, 20 Feb 2008 12:15:57 +1100 References: <47BADE07.9020402@gmx.de> <7CZsNG/ix1SXULta6Bdgf51ZwDE@TqmFlxFMySuiJ36EgnrGRgt6KQ8> <47BB01BE.4010309@gmx.de> X-Mailer: Apple Mail (2.919.2) 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: Wed, 20 Feb 2008 01:16:05 -0000 From FreeBSD 5.5 (the earliest I can check readily) fstab(5) The fourth field, (fs_mntops), describes the mount options associated with the file system. It is formatted as a comma separated list of options. It contains at least the type of mount (see fs_type below) plus any additional options appropriate to the file system type. See the options flag (-o) in the mount(8) page and the file system specific page, such as mount_nfs(8), for additional options that may be specified. So the fs_type (rw, ro, etc.) has always been documented as obligatory, though in slightly less than obvious wording. On 20/02/2008, at 3:20 AM, Dominic Fandrey wrote: > 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. > _______________________________________________ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org > " >