From owner-freebsd-stable@FreeBSD.ORG Mon Sep 29 17:11:21 2008 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 D43B91065696 for ; Mon, 29 Sep 2008 17:11:21 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id A9CC48FC14 for ; Mon, 29 Sep 2008 17:11:21 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id 808DB1A9136; Mon, 29 Sep 2008 10:05:37 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 07fQQT7Xj1Gj; Mon, 29 Sep 2008 10:05:37 -0700 (PDT) Received: from [10.0.0.40] (iago.office.miralink.com [10.0.0.40]) by plato.miralink.com (Postfix) with ESMTP id 312211A90E3; Mon, 29 Sep 2008 10:05:37 -0700 (PDT) Message-ID: <48E10C39.9040907@miralink.com> Date: Mon, 29 Sep 2008 10:11:21 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: Dan Allen References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-stable@freebsd.org Subject: Re: Missing fstab 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: Mon, 29 Sep 2008 17:11:21 -0000 Dan Allen wrote: > In messing around trying to get a bootable FreeBSD system on a memory > stick I messed up and deleted my fstab file on my main FreeBSD STABLE > machine. Actually a script I was writing overwrote it... arrggghh. > > I feel so stupid. > > Anyway, my system now boots and then dies midway in boot because there > is no /etc/fstab. I get the mountroot prompt, I type in ufs:ad0s2a > (my main root partition) and it begins booting fine. So far so good. > > It then goes into single user mode, which is fine, but it leaves my > main root filesystem as readonly, which is not so fine. This is > because of the missing /etc/fstab file. > > I have a backup of my fstab file on a USB memory stick. I can mount > the stick on /mnt and then I type > > /sbin/mount -F /mnt/fstab -f -u -w / > > thinking that it will now update the drive to readwrite. It does > not. The command appears to succeed but running mount again shows the > file system is still read-only. It will not mount my main root file > system readwrite. I believe my main file system is fine. I can see > all of my files readonly. > > I cannot change my root file system in order to copy my backup fstab > back to /etc/fstab because the file system refuses to be updated to > readwrite. This is my core problem. > > fsck will not run because there is no /etc/fstab and there is no > option that I can find that will allow a different fstab to be used, > although running fsck is not my central problem. > > Any ideas on how to force the file system to be readwrite long enough > for me to replace my /etc/fstab file? > > Dan > A "mount -o rw /dev/ad0s1a /" doesn't "just work" for you? Sean