From owner-freebsd-hackers@FreeBSD.ORG Thu Mar 1 23:43:48 2007 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 2D2BD16A403; Thu, 1 Mar 2007 23:43:48 +0000 (UTC) (envelope-from killing@multiplay.co.uk) Received: from multiplay.co.uk (core6.multiplay.co.uk [85.236.96.23]) by mx1.freebsd.org (Postfix) with ESMTP id 9723A13C4A8; Thu, 1 Mar 2007 23:43:47 +0000 (UTC) (envelope-from killing@multiplay.co.uk) X-Spam-Checker-Version: SpamAssassin 3.1.5 (2006-08-29) on core6.multiplay.co.uk X-Spam-Level: X-Spam-Status: No, score=-24.7 required=6.0 tests=BAYES_00, USER_IN_WHITELIST, USER_IN_WHITELIST_TO autolearn=ham version=3.1.5 Received: from vader ([212.135.219.179]) by multiplay.co.uk (multiplay.co.uk [85.236.96.23]) (MDaemon PRO v9.5.4) with ESMTP id md50003576969.msg; Thu, 01 Mar 2007 23:42:33 +0000 Message-ID: <00cb01c75c5b$4205e390$b3db87d4@multiplay.co.uk> From: "Steven Hartland" To: , Date: Thu, 1 Mar 2007 23:42:14 -0000 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.3028 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3028 X-MDRemoteIP: 212.135.219.179 X-Return-Path: killing@multiplay.co.uk X-Envelope-From: killing@multiplay.co.uk X-Spam-Processed: multiplay.co.uk, Thu, 01 Mar 2007 23:42:34 +0000 X-MDAV-Processed: multiplay.co.uk, Thu, 01 Mar 2007 23:42:34 +0000 Cc: Subject: sysinstall creates corrupt filesystems after repartitioning X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 Mar 2007 23:43:48 -0000 I've been repartitioning some of our machines here and found that using the following method sysinstall creates corrupt filesystems. 1. Boot a machine using an nfs mounted /usr 2. Run: sysctl kern.geom.debugflags=16 to enable writing to the disk mbr 3. run sysinstall, Customise -> Label 4. Delete the /usr partition e.g. /dev/da0s1f 5. Create two partitions from the space left as ufs with mount points /usr and /data 6. Write the changes. Now two strange things happen: 1. /usr ends up mounted twice once from nfs and once from the new ufs. This requires umount -f /dev/da0s1f to correct but doesnt always work properly requiring a reboot to restore system functionality. 2. The FS on both partitions is totally corrupt even fsck cant repair them, even after a reboot. So the question is why would sysinstall create two corrupt FS's with this procedure? Fixing is trivial just rerun the newfs commands and all is good but its really odd that they should be corrupt in the first place and caught me out big time when I first did this as I had restored a full dump back onto /usr and rebooted only for it to blow up horribly as the fs was so badly corrupted. Steve ================================================ This e.mail is private and confidential between Multiplay (UK) Ltd. and the person or entity to whom it is addressed. In the event of misdirection, the recipient is prohibited from using, copying, printing or otherwise disseminating it or any information contained in it. In the event of misdirection, illegible or incomplete transmission please telephone +44 845 868 1337 or return the E.mail to postmaster@multiplay.co.uk.