rook: devicePathFilter doesn't work with /dev/disk/by-partlabel
- Bug Report
Deviation from expected behavior: Devices are ignored. Expected behavior: Devices are used in cluster. How to reproduce it (minimal and precise): Create a simple partition on a disk. Use gdisk to give the partition a label. Use: “devicePathFilter: /dev/disk/by-partlabel/<the-label>”
File(s) to submit:
Fresh 1.2.7 deployment.
Log from the discovery (cut useless info):
2020-05-18 13:19:40.022717 I | exec: Running command: udevadm info --query=property /dev/sdb
2020-05-18 13:19:40.027761 I | exec: Running command: lsblk --noheadings --list -o NAME /dev/sdb
2020-05-18 13:19:40.033102 I | exec: Running command: udevadm info --query=property /dev/sdb1
2020-05-18 13:19:40.037794 I | inventory: skipping device "sdb" because it has child, considering the child instead.
2020-05-18 13:19:40.037829 I | exec: Running command: lsblk /dev/sdb1 --bytes --nodeps --pairs --output SIZE,ROTA,RO,TYPE,PKNAME
2020-05-18 13:19:40.041742 I | exec: Running command: udevadm info --query=property /dev/sdb1
udevadm info --query=property /dev/sdb1:
DEVPATH=/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.1/2-1.1:1.0/host6/target6:0:0/6:0:0:0/block/sdb/sdb1
DEVNAME=/dev/sdb1
DEVTYPE=partition
PARTN=1
PARTNAME=CEPH_DATA
MAJOR=8
MINOR=17
SUBSYSTEM=block
USEC_INITIALIZED=83937007236
ID_VENDOR=Crucial_
ID_VENDOR_ENC=Crucial_
ID_VENDOR_ID=152d
ID_MODEL=CT256MX100SSD1
ID_MODEL_ENC=CT256MX100SSD1\x20\x20
ID_MODEL_ID=1576
ID_REVISION=0204
ID_SERIAL=Crucial__CT256MX100SSD1_987654321029-0:0
ID_SERIAL_SHORT=987654321029
ID_TYPE=disk
ID_INSTANCE=0:0
ID_BUS=usb
ID_USB_INTERFACES=:080650:080662:
ID_USB_INTERFACE_NUM=00
ID_USB_DRIVER=uas
ID_PATH=pci-0000:00:1d.0-usb-0:1.1:1.0-scsi-0:0:0:0
ID_PATH_TAG=pci-0000_00_1d_0-usb-0_1_1_1_0-scsi-0_0_0_0
ID_PART_TABLE_UUID=0e5b541c-593f-364e-aad0-9e14a35330d2
ID_PART_TABLE_TYPE=gpt
ID_FS_UUID=909d7a94-518f-437c-96ad-0081cd2c0b92
ID_FS_UUID_ENC=909d7a94-518f-437c-96ad-0081cd2c0b92
ID_FS_VERSION=1.0
ID_FS_TYPE=ext4
ID_FS_USAGE=filesystem
ID_PART_ENTRY_SCHEME=gpt
ID_PART_ENTRY_NAME=CEPH_DATA
ID_PART_ENTRY_UUID=69b2a0e3-78c8-fc4d-968e-27cf536b05b1
ID_PART_ENTRY_TYPE=0fc63daf-8483-4772-8e79-3d69d8477de4
ID_PART_ENTRY_NUMBER=1
ID_PART_ENTRY_OFFSET=2048
ID_PART_ENTRY_SIZE=500116111
ID_PART_ENTRY_DISK=8:16
DEVLINKS=/dev/disk/by-uuid/909d7a94-518f-437c-96ad-0081cd2c0b92 /dev/disk/by-id/usb-Crucial__CT256MX100SSD1_987654321029-0:0-part1 /dev/disk/by-partlabel/CEPH_DATA /dev/disk/by-partuuid/69b2a0e3-78c8-fc4d-968e-27cf536b05b1 /dev/disk/by-path/pci-0000:00:1d.0-usb-0:1.1:1.0-scsi-0:0:0:0-part1
TAGS=:systemd:
So both PARTNAME and DEVLINKS show the correct label (CEPH_DATA), but i guess because the ‘raw’ devpath is still sdb, it’s ignored.
This causes issues, because I want to generalize the config for all machines and use autodiscover. I just want to be able to use different devices in different machines with different paths with a generic configuration. All my machines have different disks attached, but all the Ceph partitions are labeled properly. In the future, I’m probably going to use CEPH_DATA[0-90-9] as a filter, so I can easily and dynamically add OSD’s.
Environment:
- OS (e.g. from /etc/os-release):
- Kernel (e.g.
uname -a): Debian 10, fully updated - Cloud provider or hardware configuration: Intel NUC’s
- Rook version (use
rook versioninside of a Rook Pod): 1.2.7 - Storage backend version (e.g. for ceph do
ceph -v): latest for 1.2.7 - Kubernetes version (use
kubectl version):1.17.3 - Kubernetes cluster type (e.g. Tectonic, GKE, OpenShift): kubeadm
- Storage backend status (e.g. for Ceph use
ceph healthin the Rook Ceph toolbox): healthy
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Reactions: 1
- Comments: 16 (9 by maintainers)
Commits related to this issue
- reproduce 5504 https://github.com/rook/rook/issues/5504 Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com> — committed to satoru-takeuchi/rook-helper by satoru-takeuchi 4 years ago
- ceph: fix ignoring device specification with non-kname Since partition's DevLinks are empty in osd-prepare-pod, the device specification with non-kname, for example devicePathFilter, doesn't work. C... — committed to cybozu-go/rook by satoru-takeuchi 4 years ago
- ceph: fix ignoring device specification with non-kname Since partition's DevLinks are empty in osd-prepare-pod, the device specification with non-kname, for example devicePathFilter, doesn't work. C... — committed to cybozu-go/rook by satoru-takeuchi 4 years ago
- ceph: fix ignoring device specification with non-kname Partition's DevLinks are empty in osd-prepare-pod. So, the device specification with non-kname, for example devicePathFilter, doesn't work. Clo... — committed to cybozu-go/rook by satoru-takeuchi 4 years ago
- ceph: fix ignoring device specification with non-kname Partition's DevLinks are empty in osd-prepare-pod. So, the device specification with non-kname, for example devicePathFilter, doesn't work. Clo... — committed to cybozu-go/rook by satoru-takeuchi 4 years ago
- ceph: fix ignoring device specification with non-kname Partition's DevLinks are empty in osd-prepare-pod. So, the device specification with non-kname, for example devicePathFilter, doesn't work. Clo... — committed to cybozu-go/rook by satoru-takeuchi 4 years ago
- ceph: fix ignoring device specification with non-kname Partition's DevLinks are empty in osd-prepare-pod. So, the device specification with non-kname, for example devicePathFilter, doesn't work. Clo... — committed to cybozu-go/rook by satoru-takeuchi 4 years ago
- ceph: fix ignoring device specification with non-kname Partition's DevLinks are empty in osd-prepare-pod. So, the device specification with non-kname, for example devicePathFilter, doesn't work. Clo... — committed to cybozu-go/rook by satoru-takeuchi 4 years ago
- ceph: fix ignoring device specification with non-kname Partition's DevLinks are empty in osd-prepare-pod. So, the device specification with non-kname, for example devicePathFilter, doesn't work. Clo... — committed to rook/rook by satoru-takeuchi 4 years ago
@FireDrunk The next patch release v1.3.7 is expected in the next couple of days.
I’ve just upgraded my cluster, and after reapplying the cluster configuration, all OSD’s have added the extra drive, thanks @satoru-takeuchi !
Thanks, I’ll try to reproduce your problem.