From owner-freebsd-geom@FreeBSD.ORG Tue Aug 1 20:08:17 2006 Return-Path: X-Original-To: freebsd-geom@freebsd.org Delivered-To: freebsd-geom@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 89F8216A4DE for ; Tue, 1 Aug 2006 20:08:17 +0000 (UTC) (envelope-from nomad@castle.org) Received: from castle.org (castle.org [207.178.4.54]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2608A43D46 for ; Tue, 1 Aug 2006 20:08:17 +0000 (GMT) (envelope-from nomad@castle.org) Received: from [128.208.232.198] (vanyel.ee.washington.edu [128.208.232.198]) (authenticated bits=0) by castle.org (8.13.6/8.13.6) with ESMTP id k71K8EGU031748 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 1 Aug 2006 13:08:15 -0700 (PDT) (envelope-from nomad@castle.org) Message-ID: <44CFB4AB.4080803@castle.org> Date: Tue, 01 Aug 2006 13:08:11 -0700 From: Lee Damon User-Agent: Thunderbird 1.5.0.5 (Macintosh/20060719) MIME-Version: 1.0 To: freebsd-geom@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=failed version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on castle.org Subject: growfs, old disks, gvinum - filesystem expansion and corruption X-BeenThere: freebsd-geom@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: GEOM-specific discussions and implementations List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Aug 2006 20:08:17 -0000 I have several FreeBSD-6.1 based file servers. Each one has a hardware RAID-based system that presents a single large (800G to 2TB) "disk" to the OS. In looking around for a FBSD-supported method of slicing this disk up into usable (and later growable) file systems the only thing I found was gvinum. The other geom commands don't seem to deal with the idea of slicing off parts of a large drive. In a process very similar to the LVM commands I've used on other systems I set up the boxes, calved off some disk as gvinum "drives", formatted with newfs -U /dev/gvinum/..., added data and served forth. Then as file systems filled up I expanded those file systems. When the data was no longer needed (testing was done, it was time to go production) I removed those file systems by unmounting them and using rm in the gvinum command. I then created new file systems and the time has recently come to expand them. Now I discover that gvinum + growfs = Bad Things. It seems that when a file system is grown over "old file systems" (that supposedly no longer exist) and then fsck is run it finds those old file systems and shoves random stuff (including device nodes in some cases) into the lost+found directory on the current file system. fsck(8) gives many complaints about "unexpected soft update inconsistency", unref dir", bad/dup file", and "allocated frags marked free" & "allocated files marked free". The rub being when I try to remove the old cruft from lost+found I run a good probability of triggering a kernel panic. My questions are: 1. Is there any way to clean up the old file system cruft without crashing/trashing/deleting the system? 2. What tool should I be using to calve off slices of a 'huge' drive and later expand it? Any help would be much appreciated, nomad