From owner-freebsd-current@FreeBSD.ORG Tue Nov 18 08:50:26 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 53D1B16A4CE for ; Tue, 18 Nov 2003 08:50:26 -0800 (PST) Received: from Palimpsest.saic.hq.nasa.gov (Palimpsest.saic.hq.nasa.gov [198.116.138.106]) by mx1.FreeBSD.org (Postfix) with SMTP id 5C6BB43F85 for ; Tue, 18 Nov 2003 08:50:25 -0800 (PST) (envelope-from Chris.Shenton@hq.nasa.gov) Received: (qmail 96529 invoked by uid 1001); 18 Nov 2003 16:50:22 -0000 To: current@freebsd.org From: Chris Shenton Date: Tue, 18 Nov 2003 11:50:22 -0500 Message-ID: <86islhoc35.fsf@Palimpsest.saic.hq.nasa.gov> User-Agent: Gnus/5.090008 (Oort Gnus v0.08) Emacs/21.2 (i386--freebsd) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Subject: Recovery? recent "make world" rendered system unusable (64 bit change) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 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, 18 Nov 2003 16:50:26 -0000 I've been running 5.1-CURRENT for a while and a couple nights ago did a "make world". After a couple hours building, my system was unusable. Critical binaries like "rm", "ls", "mtree", "sh" failed, reporting "Exec format error". I can't login, not even single user. I can no longer even boot single user. I've hosed my system and am looking for a way to recover without having to reinstall everything and overwrite critical data and system config files. Naturally, I only discovered the note in UPDATING after I trashed my system -- in fact, I read it from the "OK" boot prompt with its "more". Doh! 20031112: The statfs structure has been updated with 64-bit fields to allow accurate reporting of multi-terabyte filesystem sizes. You should build world, then build and boot the new kernel BEFORE doing a `installworld' as the new kernel will know about binaries using the old statfs structure, but an old kernel will not know about the new system calls that support the new statfs structure. [...] Running an old kernel after a `make world' will cause programs such as `df' that do a statfs system call to fail with a bad system call. [...] DO NOT make installworld after the buildworld w/o building and installing a new kernel FIRST. You will be unable to build a new kernel otherwise on a system with new binaries and an old kernel. I'm looking for recommendations on how to recover, hopefully without trashing my critical system files like /etc/passwd. Ideally, I guess I'd like a way to replace all the broken binaries and any related libraries without overwriting other files. If I do a floppy-based install and then select Custom/Expert than request a minimal install, I presume it will install a small set of binaries but also overwrite /etc/passwd, /etc/ssh/* and so on. Is there a way to have it just update binaries and libraries? If I have to, I could add another disk to this box. Then I could do a floppy install of 5.x on to that new disk. Then I could boot it, and mount the old disk's partitions. Then install the new install's binaries on the old partitions. Or perhaps I could do a make buildworld, kernel, installworld the proper way, using the old disk's partitions as the target. Or could I -- somehow -- push a 64-bit-aware kernel onto this box so that the newly "broken" binaries will work again? How? Again, I've got no shell access any more so everything's gonna have to be done from floppy or maybe CD if I can borrow a burner. Naturally, this is my net boot server for my diskless clients so I can't go that route either. :-( Any other suggestions? Thanks.