From owner-freebsd-stable@FreeBSD.ORG Fri Dec 28 20:46:03 2012 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 96530CD0 for ; Fri, 28 Dec 2012 20:46:03 +0000 (UTC) (envelope-from greg.bonett@gmail.com) Received: from mail-vb0-f48.google.com (mail-vb0-f48.google.com [209.85.212.48]) by mx1.freebsd.org (Postfix) with ESMTP id 439088FC0A for ; Fri, 28 Dec 2012 20:46:03 +0000 (UTC) Received: by mail-vb0-f48.google.com with SMTP id fc21so10928255vbb.7 for ; Fri, 28 Dec 2012 12:46:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=3FDT5TNEFSNrRH2CiTjbwN4pb2GbE1pmBj2KvZedef4=; b=u+rs5xGgAS3vGwqg3omVmrQBA5PO6BLNvCPS+qC18lifgZl6tOaJC7D0vhjY3+tL+n IxEReZCWro75JUKLm/7ofFvPYpLNXupdfx32j8q1EjB3Y90pDht/V7m3rT2H2yLoyoKE K7SsvSN+K6H1FxCFP9RpTvV8tQ9xKh3VjIEmpLIVHbSWN5LsVb3jo2MMBIMhzgT6eByX A8iChZsccvUi9ODZJBU4SZz5jl318VsvcsEue5fjnvKufo2qEmIjf1Hiz3nJVZgAC/UJ mX6q/tRZ9VGsclAEAAwPf47qIoD9XclhyGWckfrxYpGXC2SfKHUizNYKydmOYMofilL+ UFDw== MIME-Version: 1.0 Received: by 10.220.115.19 with SMTP id g19mr53099322vcq.69.1356727562478; Fri, 28 Dec 2012 12:46:02 -0800 (PST) Received: by 10.58.40.33 with HTTP; Fri, 28 Dec 2012 12:46:02 -0800 (PST) Date: Fri, 28 Dec 2012 20:46:02 +0000 Message-ID: Subject: how to destroy zfs parent filesystem without destroying children - corrupted file causing kernel panick From: Greg Bonett To: freebsd-stable@freebsd.org Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.14 X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 Dec 2012 20:46:03 -0000 Many months ago, I believe some *very bad hardware* caused corruption of a file on one of my zfs file systems. I've isolated the corrupted file and can reliably induce a kernel panic with "touch bad.file", "rm bad.file", or "ls -l" in the bad.file's directory (ls in bad.file's dir doesn't cause panic, but "ls bad.file" does). This is a raidz zpool, but zpool scrub doesn't fix it - it eventually creates a kernel panic. My next plan is to attempt to get rid of this file by zfs destroy(ing) the entire filesystem. The corrupted file is on /tank, and I've copied all of the good data onto a new zfs file system, /tank/tempfs/. However, I can't figure out how to destroy the /tank filesystem without destroying /tank/tempfs (and the other /tank children). Is it possible to destroy a parent without destroying the children? Or, create a new parent zfs file system on the same zpool and move the /tank children there before destroying /tank? /tank and it's children are about 4.2 TB and I don't have the disk space readily available to copy the whole thing (but I can get the space if it's the only way to do this). Thanks in advance for the help. --Greg system info: FreeBSD 9.1-PRERELEASE #1 r243694 amd64 16GB ram 'zpool upgrade' gives: This system supports ZFS pool feature flags. All pools are formatted using feature flags. Every feature flags pool has all supported features enabled. 'zfs upgrade' gives: This system is currently running ZFS filesystem version 5. All filesystems are formatted with the current version.