On 28/11/2023 20:55, Warner Losh wrote:
The problem is a geom design point. When you have multiple aliases that
you can open, the others are removed from the filesystem view when one
is opened. It looks like from the above that the mirror-0 was created
with the diskid, so that's the device that zfs opens, leaving the ada2
devices removed.
No I really didn't use diskids for pool creation. Those diskids are too
long to type. :) That's why I explicitly post about commands I used:
> # zpool create -m none sys mirror ada2p3 ada3p3
>
> # zpool create -m none tank1 mirror ada2p5 ada3p5
I understand that "some" aliases are hidden when other style of aliases
were used but I never see ada0pX missing even if gpt labels are used.
Also partition p4 prepared for swap was not used by any name style /
alias so I expect to see it there but it is not there. ANd the behavior
is the exact opposite - when I now tried to create swap with diskids,
/dev/gpt/ directory was instantly created a populated with gpt label
aliases:
# gmirror label -F -h gmGswap0 /dev/diskid/DISK-Z3010G8Vp4
/dev/diskid/DISK-Z302YC90p4
# ll /dev/gpt/
total 0
crw-r----- 1 root operator 0xf9 Nov 28 23:22 swapC90
crw-r----- 1 root operator 0x115 Nov 28 23:22 swapG8V
This is normal example from another machine with similar setup:
# ls -1 /dev/ada*
/dev/ada0
/dev/ada0p1
/dev/ada0p2
/dev/ada0p3
/dev/ada1
/dev/ada1p1
/dev/ada1p2
/dev/ada1p3
/dev/ada2
/dev/ada2p2
/dev/ada3
/dev/ada3p2
# ls -1 /dev/gpt/
boot0
boot1
disk0tank0
disk1tank0
ssd0tank1
ssd1tank1
swap0
swap1
# zpool list -v
NAME SIZE ALLOC FREE CKPOINT EXPANDSZ FRAG CAP
DEDUP HEALTH ALTROOT
ssdtank1 199G 51.4G 148G - - 75% 25%
1.00x ONLINE -
mirror-0 199G 51.4G 148G - - 75%
25.8% - ONLINE
gpt/ssd0tank1 200G - - - - -
- - ONLINE
gpt/ssd1tank1 200G - - - - -
- - ONLINE
tank0 1.80T 714G 1.10T - - 52% 38%
1.00x ONLINE -
mirror-0 1.80T 714G 1.10T - - 52%
38.8% - ONLINE
gpt/disk0tank0 1.81T - - - - -
- - ONLINE
gpt/disk1tank0 1.81T - - - - -
- - ONLINE
As you can see there are aliases in /dev/gpt/, there are partitions for
/dev/adaX devices and the pools are made of gpt labels.
This is what I expect from the system in my first post.
I will try to disable disk_ident as suggested by Freddie Cash.
Kind regards
Miroslav Lachman