From owner-freebsd-fs@FreeBSD.ORG Wed Oct 10 16:45:16 2012 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BA80017C for ; Wed, 10 Oct 2012 16:45:16 +0000 (UTC) (envelope-from fjwcash@gmail.com) Received: from mail-la0-f54.google.com (mail-la0-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id 344BB8FC14 for ; Wed, 10 Oct 2012 16:45:15 +0000 (UTC) Received: by mail-la0-f54.google.com with SMTP id e12so664214lag.13 for ; Wed, 10 Oct 2012 09:45:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=dDJjUYaQ6ZXxhBOjWgo2J/umI0nnh59fS9Mi2TdUu2E=; b=Lf0sMnGAMg4qEfggh148d0eG9h3N7gZQQ4YmXzXdZcVwndj8K5x61OMjGYwFq/zYr4 NbgU74k2y4oJbsnucIlXc76JLHk7XL7BBIbNkZNGR2YB+Lq+Mclwa9S83Tp7O4PfAhe+ 2cNEWvslmzFOr2r+CZiJDbh//frZIjAg3DtggNC/d5gAvOVrlAJzzpDDbGh6BPY0rzb7 rh8FRHs9H/+9SogumTYHEUZA8MKTuv/uD3mwsOs90w/+oa9LAyQYffdMs3ByslvD/WVd Bf/b/CB3ZUzBE8F8PZ4nqCmpJtrrdPjp9T17VadvQQNl2GWXw3oBRi4uCWnirYsnnn6H KvjQ== MIME-Version: 1.0 Received: by 10.152.104.148 with SMTP id ge20mr20298083lab.51.1349887514687; Wed, 10 Oct 2012 09:45:14 -0700 (PDT) Received: by 10.114.23.230 with HTTP; Wed, 10 Oct 2012 09:45:14 -0700 (PDT) In-Reply-To: <074F3CC1-E29F-4552-840F-A38FDDCC7E76@wimsey.us> References: <074F3CC1-E29F-4552-840F-A38FDDCC7E76@wimsey.us> Date: Wed, 10 Oct 2012 09:45:14 -0700 Message-ID: Subject: Re: Deadlock on zfs import From: Freddie Cash To: David Wimsey Content-Type: text/plain; charset=UTF-8 Cc: freebsd-fs@freebsd.org X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Oct 2012 16:45:16 -0000 If you boot to single-user mode, disable the auto-import of pools (zfs_enable=no in rc.conf), boot to multi-user, start top in one terminal, and then manually import the pool in another window, and watch top out, does it run out of RAM (putting everything into wired)? You're running dedupe with only 4 GB of RAM, with pools over 90% full. My guess is that it's running out of ARC space trying to import the pool and load the DDT (dedupe table). The above test will show that to be the case (wired memory goes to 100% and system locks up). If that's the case, the only solution I've found is to stick more RAM into the box. If the cause of the "can't import due to running out of ARC" is that you were destroying a ZFS filesystem that had dedupe enabled, then you can try upgrading to 9-STABLE and add the "zfs features" patch that was posted here last week. That will run the "zfs destroy" process in the background and allow the pool to import. It worked for us ("zfs destroy" of a 1 TB filesystem locked up our pool; but the background destroy feature let us work around it for importing). -- Freddie Cash fjwcash@gmail.com