From owner-freebsd-questions Sat Sep 28 3:50:29 2002 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 E84DE37B401 for ; Sat, 28 Sep 2002 03:50:26 -0700 (PDT) Received: from smtp.infracaninophile.co.uk (happy-idiot-talk.infracaninophile.co.uk [81.2.69.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id F124D43E3B for ; Sat, 28 Sep 2002 03:50:25 -0700 (PDT) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost.infracaninophile.co.uk [IPv6:::1]) by smtp.infracaninophile.co.uk (8.12.6/8.12.6) with ESMTP id g8SAoOC0004464; Sat, 28 Sep 2002 11:50:24 +0100 (BST) (envelope-from matthew@happy-idiot-talk.infracaninophile.co.uk) Received: (from matthew@localhost) by happy-idiot-talk.infracaninophile.co.uk (8.12.6/8.12.6/Submit) id g8SAoJHN004463; Sat, 28 Sep 2002 11:50:19 +0100 (BST) Date: Sat, 28 Sep 2002 11:50:19 +0100 From: Matthew Seaman To: Christopher Farley Cc: freebsd-questions@FreeBSD.ORG Subject: Re: Help! Broken libc! Message-ID: <20020928105019.GE24417@happy-idiot-talk.infracaninophi> Mail-Followup-To: Matthew Seaman , Christopher Farley , freebsd-questions@FreeBSD.ORG References: <20020928072600.GA321@northernbrewer.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020928072600.GA321@northernbrewer.com> User-Agent: Mutt/1.5.1i X-Spam-Status: No, hits=-11.7 required=5.0 tests=IN_REP_TO,MANY_EXCLAMATIONS,QUOTED_EMAIL_TEXT,REFERENCES, SPAM_PHRASE_00_01,USER_AGENT,USER_AGENT_MUTT version=2.41 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Sat, Sep 28, 2002 at 02:26:04AM -0500, Christopher Farley wrote: > The libc.so.4 hash is different, so I suspect it may be the source of my > problem. It also appears that replacing this file is somewhat > non-trivial. When I attempt to remove the file, I get an "Operation > not permitted," probably because it's linked to a ton of running > programs. > > Is there even a way to replace this file? Copy the good version of the libc.so.4 file onto your broken machine using a different filename: scp goodmachine:/usr/lib/libc.so.4 /usr/lib/libc.so.4.good Shut your machine down, and then boot up to single user mode, and move the bad file out of the way and the good file into place. This file is marked immutable using chflags(1) so depending on what security level you run at, you may need to be in single user to do anything. It's a good idea to go to single user whenever when you're fiddling with something so vital to the system: shutdown -r now [...] cd /usr/lib chflags -0 libc.so.4 mv libc.so.4 libc.so.4.bad mv libc.so.4.good libc.so.4 chmod 444 libc.so.4 chown root:wheel libc.so.4 chflags schg libc.so.4 and then immediately reboot. Cheers, Matthew -- Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks Savill Way Marlow Tel: +44 1628 476614 Bucks., SL7 1TH UK To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message