Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 28 Nov 2023 12:03:02 -0800
From:      Freddie Cash <fjwcash@gmail.com>
To:        Miroslav Lachman <000.fbsd@quip.cz>
Cc:        FreeBSD-STABLE Mailing List <freebsd-stable@freebsd.org>
Subject:   Re: Missing disk partition devices and GPT lables in /dev/
Message-ID:  <CAOjFWZ61tev%2BrSkm7xjrDHyQscT_ZKQRGqMKsQyuGVXG0dYW6A@mail.gmail.com>
In-Reply-To: <34a54774-004d-40de-bf0d-2985da5bc908@quip.cz>
References:  <34a54774-004d-40de-bf0d-2985da5bc908@quip.cz>

next in thread | previous in thread | raw e-mail | index | archive | help
--00000000000095e29b060b3be826
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

On Tue, Nov 28, 2023 at 11:51=E2=80=AFAM Miroslav Lachman <000.fbsd@quip.cz=
> wrote:

> I have strange problem on one of my machines - the disk devices in /dev/
> are only shown as ada0 and ada1 but no partition devices, no devices in
> /dev/gpt/ or /dev/gptid/, these directories are completely missing even
> though there are GPT labels.
> This is FreeBSD 13.2-RELEASE-p5 amd64 on HP Microserver Gen8. Disk are 2
> Seagate NAS 4TB, manually partitioned with gpart utility, zpool created
> and then all the date migrated by zfs send and zfs receive from old 2TB
> disks. Everything works, system is running but device nodes in /dev/ are
> missing. I noticed this only when I want to create gmirrored swap from
> ada0p4 and ada1p4 but got "No such file or directory."
>
> There are only diskid style devices in /dev/diskid/
>
<snip>

Sysctl seems normal to me.
>
> # sysctl kern.geom.label
> kern.geom.label.disk_ident.enable: 1
> kern.geom.label.gptid.enable: 1
>

Turn these two (above) off (set to 0).  Then reboot.

<snip>

> What can be wrong with this system?
>

Welcome to the wonderful world of GEOM tasting, "first match wins", and
Highlander's "There can be only 1" style of aliasing/labelling.  :)

The first alias path to a disk that is found (/dev/diskid, /dev/gptid,
/dev/gpt, /dev/ada*) and opened causes all other aliases to be hidden.  The
disk/GPT IDs seem to take precedence over other aliases/labels.  If you
want to access your disks via GPT labels, then disable the other naming
schemes via loader.conf.

--=20
Freddie Cash
fjwcash@gmail.com

--00000000000095e29b060b3be826
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div dir=3D"ltr">On Tue, Nov 28, 2023 at 11:51=E2=80=AFAM =
Miroslav Lachman &lt;<a href=3D"mailto:000.fbsd@quip.cz">000.fbsd@quip.cz</=
a>&gt; wrote:<br></div><div class=3D"gmail_quote"><blockquote class=3D"gmai=
l_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,20=
4,204);padding-left:1ex">I have strange problem on one of my machines - the=
 disk devices in /dev/ <br>
are only shown as ada0 and ada1 but no partition devices, no devices in <br=
>
/dev/gpt/ or /dev/gptid/, these directories are completely missing even <br=
>
though there are GPT labels.<br>
This is FreeBSD 13.2-RELEASE-p5 amd64 on HP Microserver Gen8. Disk are 2 <b=
r>
Seagate NAS 4TB, manually partitioned with gpart utility, zpool created <br=
>
and then all the date migrated by zfs send and zfs receive from old 2TB <br=
>
disks. Everything works, system is running but device nodes in /dev/ are <b=
r>
missing. I noticed this only when I want to create gmirrored swap from <br>
ada0p4 and ada1p4 but got &quot;No such file or directory.&quot;<br>
<br>
There are only diskid style devices in /dev/diskid/<br>
</blockquote><div>&lt;snip&gt;</div><div><br></div><blockquote class=3D"gma=
il_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,2=
04,204);padding-left:1ex">
Sysctl seems normal to me.<br>
<br>
# sysctl kern.geom.label<br>
kern.geom.label.disk_ident.enable: 1<br>
kern.geom.label.gptid.enable: 1<br>
</blockquote><div><br></div><div>Turn these two (above) off (set to 0).=C2=
=A0 Then reboot.</div><div>=C2=A0</div><div>&lt;snip&gt;</div><blockquote c=
lass=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-left:1px soli=
d rgb(204,204,204);padding-left:1ex">What can be wrong with this system?<br=
></blockquote><div><br></div><div>Welcome to the wonderful world of GEOM ta=
sting, &quot;first match wins&quot;, and Highlander&#39;s &quot;There can b=
e only 1&quot; style of aliasing/labelling.=C2=A0 :)</div><div><br></div><d=
iv>The first alias path to a disk that is found (/dev/diskid, /dev/gptid, /=
dev/gpt, /dev/ada*) and opened causes all other aliases to be hidden.=C2=A0=
 The disk/GPT IDs seem to take precedence over other aliases/labels.=C2=A0 =
If you want to access your disks via GPT labels, then disable the other nam=
ing schemes via loader.conf.</div></div><div><br></div><span class=3D"gmail=
_signature_prefix">-- </span><br><div dir=3D"ltr" class=3D"gmail_signature"=
>Freddie Cash<br><a href=3D"mailto:fjwcash@gmail.com" target=3D"_blank">fjw=
cash@gmail.com</a></div></div>

--00000000000095e29b060b3be826--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAOjFWZ61tev%2BrSkm7xjrDHyQscT_ZKQRGqMKsQyuGVXG0dYW6A>