From owner-freebsd-hackers@FreeBSD.ORG Thu Feb 26 07:51:02 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E110316A4CE for ; Thu, 26 Feb 2004 07:51:02 -0800 (PST) Received: from fledge.watson.org (fledge.watson.org [204.156.12.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 443F943D2D for ; Thu, 26 Feb 2004 07:51:02 -0800 (PST) (envelope-from robert@fledge.watson.org) Received: from fledge.watson.org (localhost [127.0.0.1]) by fledge.watson.org (8.12.10/8.12.10) with ESMTP id i1QFo6DL092492; Thu, 26 Feb 2004 10:50:06 -0500 (EST) (envelope-from robert@fledge.watson.org) Received: from localhost (robert@localhost)i1QFo6ii092489; Thu, 26 Feb 2004 10:50:06 -0500 (EST) (envelope-from robert@fledge.watson.org) Date: Thu, 26 Feb 2004 10:50:06 -0500 (EST) From: Robert Watson X-Sender: robert@fledge.watson.org To: db In-Reply-To: <20040226155832.555eef86@main.trunet.dk> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII cc: hackers@freebsd.org Subject: Re: 5.2.1 make installword trashed my system X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Feb 2004 15:51:03 -0000 On Thu, 26 Feb 2004, db wrote: > I've been running 5.2 on my laptop (i386 Acer) for some time now. Few > hours ago I download the 5.2.1-release source, buildworld, buildkernel, > installkernel, but after a few minuts of installworld my system froze. > Now when I try to boot I get: Ouch. > Mounting root from ufs: /dev/ad0s1a > WARNING: / was not properly dismounted > exec /sbin/init: error 8 > /sbin/sysctl: 1: Syntax error: ";" unexpected > /sbin/sysctl: 1: Syntax error: ";" unexpected > > Thu Feb 26 16:24:26 CET 2004 > Feb 26 16:24:26 init: can't exec getty '/usr/libexec/getty' for port > /dev/ttyv0: No such file or directory > ....and so on > > So the question is: Now what? I can boot in single user mode and get a > shell, but very few programs work and I can't mount anything? It seems there might be three fairly straight-forward choices, not sure which are options for you: (1) Download the 5.2.1 ISO, and do a binary update, which will simply slap down the 5.2.1 binaries over whatever is on the disk (a pretty blend of 5.2 and 5.2.1, no doubt). (2) In general, the 5.2 and 5.2.1 binaries are about the same in userspace -- most changes were to the kernel, and no ABIs were changed. So it sounds like maybe init got toasted, a few shared libraries, etc. Boot to single-user mode using /rescue/init and/or /rescue/sh, and manually update binaries from your object tree until you can successfully kick off an installworld. You can use /rescue/cp to do most of this. I'd start by copying /usr/obj/usr/src/sbin/init to /sbin/init, and hitting a couple of the key libraries (libc, libutil, for example). As soon as you can boot normally to single user mode and use the existing tools, restart installworld. By looking at the dates in /bin, /sbin, etc, you can probably figure out where it gave up, and what only got partially completed. (3) If you can NFS boot the system, perhaps using PXE, you can do an installworld over the network. This is generally easy if you already have a PXE setup, but otherwise hard as you have to figure out PXE. None of this addresses the hang you saw -- once you've gotten the system up and running properly, if you are still experiencing the hang, we should see if we can figure out what it is that's hanging. However, that will be very hard to do in the partially updated configuration, so I think the best bet is to try and get the update finished. Good luck! Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Senior Research Scientist, McAfee Research