From owner-freebsd-questions@FreeBSD.ORG Thu Dec 2 00:02:49 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5CB4216A4CE for ; Thu, 2 Dec 2004 00:02:49 +0000 (GMT) Received: from ns1.tiadon.com (SMTP.tiadon.com [69.27.132.161]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0322143D1F for ; Thu, 2 Dec 2004 00:02:49 +0000 (GMT) (envelope-from kdk@daleco.biz) Received: from [69.27.131.0] ([69.27.131.0]) by ns1.tiadon.com with Microsoft SMTPSVC(6.0.3790.211); Wed, 1 Dec 2004 18:03:36 -0600 Message-ID: <41AE5BB9.1000902@daleco.biz> Date: Wed, 01 Dec 2004 18:03:05 -0600 From: "Kevin D. Kinsey, DaleCo, S.P." User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.2) Gecko/20041023 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Trey Sizemore References: <41AA5AFC.2090902@fastmail.fm> <20041128201638.N66254@cactus.fi.uba.ar> <41AA663F.2030106@fastmail.fm> In-Reply-To: <41AA663F.2030106@fastmail.fm> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 02 Dec 2004 00:03:36.0891 (UTC) FILETIME=[5F04F0B0:01C4D802] cc: freebsd-questions@freebsd.org Subject: Re: How to edit file in single user mode X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Dec 2004 00:02:49 -0000 Trey Sizemore wrote: > Fernando Gleiser wrote: > >> On Sun, 28 Nov 2004, Trey Sizemore wrote: >> >> >> >>> I made a typo in rc.conf and now am able to boot only into single user >>> mode. I thought vi would be available to edit the file, but cannot >>> execute it (vi not found). How can I edit my rc.conf at this point/ >>> >> >> >> After you drop into single user, say the magic words: >> >> # mount -a >> >> that will mount all the filesystems and then vi will be available. >> >> >> Fer >> >> > D'oh....sorry. Dumb question, but thanks for answering anyway! {Sorry to come into this so late...} Not necessarily a dumb question. What if you can't mount /usr ? then you've even more trouble. You can learn to use ed(1), but that's like going back thirty years. Not that we hate anyone who was using computers back then ... There was some discussion on the lists (IIRC) a while back on the idea of building a small editor binary that you like (trying to remember some of the possibilities: zed, ved, led, sted, (but not ted), ee (already in the base system), pico, nano, nah, can't really remember :-< ) and cp'ing it to /bin in preparation for just such an emergency. With root partitions {generally} being a tad larger these days than in the elder times, it might be a feasible idea...I'm pretty sure *someone* out there has tried it. Come to think of it, I may. :-) Kevin Kinsey DaleCo, S.P.