Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

zfs zvol partition can not create by-partuuid or by-uuid path #14141

Closed
humaorong opened this issue Nov 4, 2022 · 1 comment
Closed

zfs zvol partition can not create by-partuuid or by-uuid path #14141

humaorong opened this issue Nov 4, 2022 · 1 comment
Labels
Type: Defect Incorrect behavior (e.g. crash, hang)

Comments

@humaorong
Copy link

ZFS run environment :

System inforation :
kernel : Linux horeb34 5.10.139 #17
cpu : x86_64
os: Rocky Linux 8.6
zfs version : 2.1.5

installed : zfs , zfs-dkms , and other depends rpm

The proble :
My environment need zfs zvol partion , use partition path /dev/disk/by-partuuid/ .
And find: udevadm info -q property {zvol patition} , have no filesystem entry: ID_FS_TYPE ,ID_FS_UUID ID_FS_UUID_ENC ... , no partition info entry : ID_PART_ENTRY_{DISK,NAME,UUID...} ; use sgdisk set zvol partuuid , seting command run OK , but no zvol uuid path in /dev/disk/by-partuuid/

======================= some info as fallow :

[root@horeb34 deploy]# udevadm info -q property /dev/zd64p1
DEVLINKS=/dev/zvol/storage/zvl1-part1 /dev/storage/zvl1-part1
DEVNAME=/dev/zd64p1
DEVPATH=/devices/virtual/block/zd64/zd64p1
DEVTYPE=partition
ID_SCSI=1
MAJOR=230
MINOR=65
PARTN=1
PARTNAME=xfs
SUBSYSTEM=block
TAGS=:systemd:
USEC_INITIALIZED=8626579822
[root@horeb34 deploy]#
[root@horeb34 deploy]#
[root@horeb34 deploy]# sgdisk -u 1:d06f212f-2002-4e28-b5ee-0a87f8224199 /dev/zd64**
The operation has completed successfully.
[root@horeb34 deploy]#
[root@horeb34 deploy]#
[root@horeb34 deploy]# udevadm info -q property /dev/zd64p1
DEVLINKS=/dev/zvol/storage/zvl1-part1 /dev/storage/zvl1-part1
DEVNAME=/dev/zd64p1
DEVPATH=/devices/virtual/block/zd64/zd64p1
DEVTYPE=partition
ID_SCSI=1
MAJOR=230
MINOR=65
PARTN=1
PARTNAME=xfs
SUBSYSTEM=block
TAGS=:systemd:
USEC_INITIALIZED=12986468769
[root@horeb34 deploy]#
[root@horeb34 log]# ls -al /dev/disk/by-partuuid/ | grep zd
[root@horeb34 log]#

==================================
on centos7 , ZFS 0.8.5 , info like as follow :

[root@node85 rules.d]# udevadm info -q property /dev/zd0p1
DEVLINKS=/dev/disk/by-partlabel/data_1 /dev/disk/by-partuuid/144bdc5a-266b-48d3-b1dc-1da9e0d3654d /dev/disk/by-uuid/35d21f8c-9966-49f1-bd73-c3258507a46c /dev/pool/vol2-part1 /dev/zvol/pool/vol2-part1
DEVNAME=/dev/zd0p1
DEVPATH=/devices/virtual/block/zd0/zd0p1
DEVTYPE=partition
ID_FS_TYPE=xfs
ID_FS_USAGE=filesystem
ID_FS_UUID=35d21f8c-9966-49f1-bd73-c3258507a46c
ID_FS_UUID_ENC=35d21f8c-9966-49f1-bd73-c3258507a46c
ID_PART_ENTRY_DISK=230:0
ID_PART_ENTRY_NAME=data_1
ID_PART_ENTRY_NUMBER=1
ID_PART_ENTRY_OFFSET=2048
ID_PART_ENTRY_SCHEME=gpt
ID_PART_ENTRY_SIZE=202752
ID_PART_ENTRY_TYPE=4fbd7e29-9d25-41b8-afd0-062c0ceff05d
ID_PART_ENTRY_UUID=144bdc5a-266b-48d3-b1dc-1da9e0d3654d
ID_PART_TABLE_TYPE=gpt
MAJOR=230
MINOR=1
SUBSYSTEM=block
TAGS=:systemd:
USEC_INITIALIZED=75583

========================================
Please help me !

@humaorong humaorong added the Type: Defect Incorrect behavior (e.g. crash, hang) label Nov 4, 2022
@humaorong
Copy link
Author

this is systemctl proble , version :
[root@horeb34 deploy]# systemctl --version
systemd 239 (239-58.el8_6.7)
+PAM +AUDIT +SELINUX +IMA -APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUTLS +ACL +XZ +LZ4 +SECCOMP +BLKID +ELFUTILS +KMOD +IDN2 -IDN +PCRE2 default-hierarchy=legacy
=============resolve this proble :
change /usr/lib/udev/rules.d/60-persistent-storage.rules file , add 'zd*' to KERNEL, changed as this : KERNEL!="loop*|mmcblk*[0-9]|msblk*[0-9]|mspblk*[0-9]|nvme*|sd*|sr*|vd*|xvd*|bcache*|cciss*|dasd*|ubd*|scm*|pmem*|nbd*|zd*"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Defect Incorrect behavior (e.g. crash, hang)
Projects
None yet
Development

No branches or pull requests

1 participant