From nobody Thu Aug 05 19:45:01 2021 X-Original-To: freebsd-fs@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 8A6A510FA4F1 for ; Thu, 5 Aug 2021 19:45:20 +0000 (UTC) (envelope-from asomers@gmail.com) Received: from mail-ot1-f41.google.com (mail-ot1-f41.google.com [209.85.210.41]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4GgfGS3J8Rz4R5N for ; Thu, 5 Aug 2021 19:45:20 +0000 (UTC) (envelope-from asomers@gmail.com) Received: by mail-ot1-f41.google.com with SMTP id v8-20020a0568301bc8b02904d5b4e5ca3aso6290959ota.13 for ; Thu, 05 Aug 2021 12:45:20 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=HaaEATdabA5H60geP2UXilZxOBQEUHLdZJije8FDEIU=; b=uejov/fh0HVmFXsBiWKDmnFtyY1HlEfNMLJOV3vEE22CR81T+6j6eClPVJc6dsKHKN NE31RzWGdqg0XwX3OAfhe698sJACosB/yx/N/Bj8p7XnSK0UwViX8mKan8RP07bS5Xd7 KJPjJF7Bmamv5uwLluRFHTry5nykSTJz6dfD3lx/M8GKVAU1ZhCchYmcOwD7PD0LY4O4 MWOsJ8kD74Mjqbuo1gIEPe7wnlmfYK0uSRxdYS2onIrp3DTn5vkXjQeLhld7makd2GCK +WAKt94PLaynkxI3+P7zpVhwb8qFB0V9kep828XcaO0tuTK1Q8LuVOieWovnYsQ3DolU naEw== X-Gm-Message-State: AOAM5305NtObJhZhuvfIhut+wOr2Ph/mHFVNPM6rTglrGUTKlSJcRDod 1NBN78nqg/PiialOJ8iu7Rx7Sbq871NoIZJ8iG5By/G5 X-Google-Smtp-Source: ABdhPJyT+KLZGVYNFEd/30EHsZpYCVBSeiWGyYn8eE5j/Za4Gs+SqReK+fEYozzcbabNuHdo47lcgi3wcyBZq6o6v8A= X-Received: by 2002:a9d:7982:: with SMTP id h2mr4701029otm.291.1628192714672; Thu, 05 Aug 2021 12:45:14 -0700 (PDT) List-Id: Filesystems List-Archive: https://lists.freebsd.org/archives/freebsd-fs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-fs@freebsd.org MIME-Version: 1.0 References: In-Reply-To: From: Alan Somers Date: Thu, 5 Aug 2021 14:45:01 -0500 Message-ID: Subject: Re: ZFS question To: joe mcguckin Cc: freebsd-fs Content-Type: multipart/alternative; boundary="00000000000062500805c8d52802" X-Rspamd-Queue-Id: 4GgfGS3J8Rz4R5N X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-ThisMailContainsUnwantedMimeParts: Y --00000000000062500805c8d52802 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Each drive has a label containing the drive's guid and the guid of every other drive in the same top level vdev . During import, ZFS searches every geom provider to find matching guids. If the drives have the same names as they used to, then the import goes faster. But ZFS always checks the guids during import . On Thu, Aug 5, 2021, 2:26 PM joe mcguckin wrote: > How does ZFS keep track of drives in a dataset or VDEV? If I rearrrange > the drives in a chassis, somehow ZFS is able to make sense of the scrambl= ed > drives and > mount the dataset. > > Clearly ZFS is tracking the drives. How does it refer to the drives > internally? By UUID, Drive Label? On some OS=E2=80=99s (Linux) there ar= e many > options for specifying which drives make up a VDEV: UUID, Partition Label= , > etc. On other OS=E2=80=99s, these schemes might not exist > (think moving drives from Linux to FreeBSD, for example). > > I=E2=80=99ve noticed that on Linux, drive identifiers (sda, sdb, etc) mov= e around > after reboots. How does ZFS cope with this? > > Does each drive (or partition) have a header that tells ZFS that this > entity is =E2=80=98drive 2 of VDEV foo=E2=80=99? > > Thanks, > > Joe > > Joe McGuckin > ViaNet Communications > > joe@via.net > 650-207-0372 cell > 650-213-1302 office > 650-969-2124 fax > > > > --00000000000062500805c8d52802--