From owner-freebsd-questions Mon Sep 18 23:56: 5 2000 Delivered-To: freebsd-questions@freebsd.org Received: from mailhost01.reflexnet.net (mailhost01.reflexnet.net [64.6.192.82]) by hub.freebsd.org (Postfix) with ESMTP id 68F6E37B422 for ; Mon, 18 Sep 2000 23:56:03 -0700 (PDT) Received: from 149.211.6.64.reflexcom.com ([64.6.211.149]) by mailhost01.reflexnet.net with Microsoft SMTPSVC(5.5.1877.197.19); Mon, 18 Sep 2000 23:54:52 -0700 Received: (from cjc@localhost) by 149.211.6.64.reflexcom.com (8.11.0/8.11.0) id e8J6tsI10557; Mon, 18 Sep 2000 23:55:54 -0700 (PDT) (envelope-from cjc) Date: Mon, 18 Sep 2000 23:55:54 -0700 From: "Crist J . Clark" To: Spades Cc: freebsd-questions@FreeBSD.ORG Subject: Re: passwd Message-ID: <20000918235554.K367@149.211.6.64.reflexcom.com> Reply-To: cjclark@alum.mit.edu References: <3.0.32.20000919143501.009fdc40@smtp.magix.com.sg> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0i In-Reply-To: <3.0.32.20000919143501.009fdc40@smtp.magix.com.sg>; from spades@galaxynet.org on Tue, Sep 19, 2000 at 02:35:01PM +0800 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Tue, Sep 19, 2000 at 02:35:01PM +0800, Spades wrote: > At 09:50 PM 9/18/00 -0700, you wrote: > >On Tue, Sep 19, 2000 at 12:30:43PM +0800, Spades wrote: > >> I overwritten my /etc/passwd with /etc/adduser.conf and accidentally > >> rebooted, now the passwds all cannot work. When i rename /etc/master.passwd > >> to /etc/passwd, it might work too. > >> > >> When I run the passwd command, I get an error saying that the > /etc/pwd.db > >> is an incorrect file type or format. It looks like both, the /etc/pwd.db > >> and /etc/spwd.db are corrupted. I am trying to get something working so > >> that i can log in. > >> > >> Any idea? > > > >If you still have an intact master.passwd, just boot into single user, > > > > # pwd_mkdb -p /etc/master.passwd > > > >And you're set. > > Server will not boot into single mode. Well, how are you getting into root with corrupted password files? Anyway, just run it as root. Why won't it boot into single user? (If that is what you need to do to get root.) -- Crist J. Clark cjclark@alum.mit.edu To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message