Comment 8 for bug 1728742

Revision history for this message
Dmitrii Shcherbakov (dmitriis) wrote :

Tested #6:

https://paste.ubuntu.com/26471097/

1) while dname symlinks point to the respective /dev/bcache<n> devices (n -> n is always maintained) the underlying /dev/sd<x> devices change for dnames (provided that they are stable in this test)

https://paste.ubuntu.com/26471097/

2) only one /dev/bcache/by-uuid symlink is ever created (should be two with per-superblock uuids). The UUID used is different from slave superblock UUIDs (it is a cache dev's superblock UUID):

https://paste.ubuntu.com/26471151/

cache device uuid -> dev.uuid 90707207-91e6-4def-9f39-b9fdbb3540ab
cset.uuid 4e21a32d-d60e-42a6-bc99-8ae7f5b21c99

sdc -> dev.uuid 4fb3f632-6e1a-43f4-9f68-e10db4d6d612
sdd -> dev.uuid 2c9b7bca-d30a-44c5-afcd-3b3aadfb0be0

ubuntu@maas-xenial2:~$ tree /dev/bcache
/dev/bcache
└── by-uuid
    └── 90707207-91e6-4def-9f39-b9fdbb3540ab -> ../../bcache0 # <---- 907...

instead, it should be:

/dev/disk/by-uuid/4fb3f632-6e1a-43f4-9f68-e10db4d6d612 -> /dev/bcache<whatever0>
/dev/disk/by-uuid/4fb3f632-6e1a-43f4-9f68-e10db4d6d612 -> /dev/bcache<whatever1>

IoW: bcache numbers for /dev/bcache<n> may flip but numbers at /dev/bcache/by-dname/bcache<n> should stay coherent with MAAS'/curtin's naming by using slave device superblock UUIDs.