From owner-freebsd-questions@freebsd.org Sun Jul 12 12:33:55 2015 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 38F3F99978A for ; Sun, 12 Jul 2015 12:33:55 +0000 (UTC) (envelope-from freebsd@qeng-ho.org) Received: from bede.qeng-ho.org (bede.qeng-ho.org [217.155.128.241]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "fileserver.home.qeng-ho.org", Issuer "fileserver.home.qeng-ho.org" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id D2E662FD5 for ; Sun, 12 Jul 2015 12:33:54 +0000 (UTC) (envelope-from freebsd@qeng-ho.org) Received: from arthur.home.qeng-ho.org (arthur.home.qeng-ho.org [172.23.1.2]) by bede.home.qeng-ho.org (8.14.9/8.14.9) with ESMTP id t6CCERxb033211; Sun, 12 Jul 2015 13:14:27 +0100 (BST) (envelope-from freebsd@qeng-ho.org) Message-ID: <55A25A23.800@qeng-ho.org> Date: Sun, 12 Jul 2015 13:14:27 +0100 From: Arthur Chance User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Quartz , Aleksandr Miroslav CC: freebsd-questions@freebsd.org Subject: Re: ZFS: zdev names don't match devices References: <55A03DB2.3020407@sneakertech.com> In-Reply-To: <55A03DB2.3020407@sneakertech.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Jul 2015 12:33:55 -0000 On 10/07/2015 22:48, Quartz wrote: >> Did I screw >> up my zfs setup? > > No. This is a quirk of the way the 10.x installer/ZFS works. There are a > handful of different ways to identify a disk on FreeBSD besides the > device ID, including UUIDs and gpt labels and such. Device IDs will > change if you ever add/remove/reorder the physical drives, so the > installer uses the other methods to be safer. I don't know why it uses a > mix instead of doing the same thing for each drive though. I've been bitten by the fact that disk partitions can have several names before. Depending on the exact set up the same partition could be called some or all of /dev/ada0p3, /dev/gpt/$gptlabel, /dev/gptid/$uuid, /dev/diskid/DISK-${disklabel}p3 or /dev/ufs/$ufslabel. ZFS pool importing seems to pretty much randomise which forms get used. Personally I prefer to use partition names of the form /dev/gpt/xx-label where xx- is a per machine and disk prefix so I can move disks between machines without confusion in case of problems. I haven't actually got round to trying this yet, but the appearance the various forms of partition name under /dev seem to be controlled by the kern.geom.label.xxx.enable sysctls. Thus if you wish to see the /dev/gpt forms and not have ZFS grab some alternate name, try putting kern.geom.label.gptid.enable=0 kern.geom.label.disk_ident.enable=0 into /boot/loader.conf -- Those who do not learn from computing history are doomed to GOTO 1