From owner-freebsd-questions@FreeBSD.ORG Tue Apr 16 09:06:48 2013 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id C32A51E2 for ; Tue, 16 Apr 2013 09:06:48 +0000 (UTC) (envelope-from tak.official@gmail.com) Received: from mail-vc0-f177.google.com (mail-vc0-f177.google.com [209.85.220.177]) by mx1.freebsd.org (Postfix) with ESMTP id 8B92CD2D for ; Tue, 16 Apr 2013 09:06:48 +0000 (UTC) Received: by mail-vc0-f177.google.com with SMTP id hr11so194011vcb.36 for ; Tue, 16 Apr 2013 02:06:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:date:message-id:subject:from:to :content-type; bh=FuJjq/vYpgvRKmQpi+aSkYx/0VUXu7kliBpFBA7xJCc=; b=B2JPq39EpeKOPP2u3ZDIcwtg6eOsWgiS9xsp7Uah52LtYoxjL22GZ+zJcERg9z0u8K uyc7jkXvqnyqOE2AMtnJvlt3RD+b91rSMZzmFtC/anMA6lkOTTPvYrSuUSylwApeGWCn DVhKA9DwymEc0QuWuuZuval5dMmqBo2NKlqKnOVapf0UrVnQXCIuo1Ac5UEeZBFaSWDx FhuAmCpGQ+mkTNKQIpRzG2mhFFCHgi2RBO70v9rlgpHefItjjMMDzkHQl/Rti2Y4egQr NQZ8uYwlV7tDAw/AMM8v+dS+uJ9iix8Wb5MsSE5l6JyVbHzU8hnp2UcO6eBv/gM/x+AF Rm0w== MIME-Version: 1.0 X-Received: by 10.220.104.68 with SMTP id n4mr861029vco.37.1366103202418; Tue, 16 Apr 2013 02:06:42 -0700 (PDT) Received: by 10.220.27.206 with HTTP; Tue, 16 Apr 2013 02:06:42 -0700 (PDT) Date: Tue, 16 Apr 2013 13:36:42 +0430 Message-ID: Subject: pwd.db/spwd.db file corupption when having unsafe system poweroff From: Tak Tak To: freebsd-questions@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 16 Apr 2013 09:06:48 -0000 hi everyone, i wanna know what exactly happens for freebsd files and processes, when we shutdown system via pressing hardware power key for 3 seconds? here's what has happened to me, recently: i've faced a strange problem.. on one of my bsd servers, one of my coworkers had defined and edited some system users, and then, instead of safe shutdown, he kept pressing power-button for 3 seconds!.. after next startup, we couldn't login anymore! we had to replace pwd.db and spwd.db files, via bootable-freebsd Fixit mode, and then, everything was fine! we know that we are, for sure, better to use safe shutdown, but i can't guarantee it always happens. what if sudden power off makes same problem??so i can't leave my servers in such situations.. My questins are: what has happened exactly? just in-used corrupted files ?? is there any way to prevent this situation? (instead of having a read-only FS.. i can't apply it on this server for now..). i'm sorry if my question seems dummish! i'm trying to increase my bsd knowledge, but i'm just on my way.. for sure, i appreciate any ideas or answers :)