From owner-freebsd-questions@freebsd.org Mon Jun 19 03:17:45 2017 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 014D3D93E65 for ; Mon, 19 Jun 2017 03:17:45 +0000 (UTC) (envelope-from list_freebsd@bluerosetech.com) Received: from echo.brtsvcs.net (echo.brtsvcs.net [208.111.40.118]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 5D0F5E60 for ; Mon, 19 Jun 2017 03:17:43 +0000 (UTC) (envelope-from list_freebsd@bluerosetech.com) Received: from chombo.houseloki.net (unknown [IPv6:2601:1c2:1401:9956:21c:c0ff:fe7f:96ee]) by echo.brtsvcs.net (Postfix) with ESMTPS id 85A9C50005; Mon, 19 Jun 2017 03:17:37 +0000 (UTC) Received: from [IPv6:fe80::7102:4df8:1f13:5c55] (unknown [IPv6:fe80::7102:4df8:1f13:5c55]) by chombo.houseloki.net (Postfix) with ESMTPSA id 97A9A54E; Sun, 18 Jun 2017 20:17:36 -0700 (PDT) Subject: Re: zpool import -N mounts filesystems anyway To: David Christensen , freebsd-questions@freebsd.org References: <7f41df25-df2e-298e-d33e-cc95874e831c@bluerosetech.com> From: Mel Pilgrim Message-ID: <1f776896-9b34-1a60-3bbe-9850ca940315@bluerosetech.com> Date: Sun, 18 Jun 2017 20:17:44 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Jun 2017 03:17:45 -0000 On 06/18/2017 13:19, David Christensen wrote: > > Have you tried setting canmount to noauto? It also doesn't work as expected. # zfs get -r canmount,mountpoint backupA NAME PROPERTY VALUE SOURCE backupA canmount noauto local backupA mountpoint /backup-ext/backupA local backupA/z0 canmount noauto local backupA/z0 mountpoint /backup-ext/backupA/z0 inherited from backupA # zpool export backupA # zpool import backupA # zfs list -ro name,mounted,mountpoint backupA NAME MOUNTED MOUNTPOINT backupA yes /backup-ext/backupA backupA/z0 no /backup-ext/backupA/z0 Despite canmount=noauto, ZFS mounted the root dataset automatically anyway. The only way I know of to guarantee a dataset won't be mounted on import, despite documentation to the contrary, is to make sure it has or inherits mountpoint=none.