On Mon, Oct 15, 2018 at 6:48 AM Jan Fajerski <jfajerski@xxxxxxxx> wrote: > > Hi list, > while playing with ceph-volume I noticed that it adds the tag ceph.data_device > to an lv with the name of the lv (at the time of calling prepare). > I was wondering what this specific tag is used for. From looking at > ceph-volume's code it seems its only ever set. > Using vgrename of lvrename one can easily create an inconsistency in this > self-reference. Restarting the OSD (or rebooting the node) still works as > expected but I'm certainly not thinking of all cases here. The tags are used as a key/value store in the device, and we try to add as much info there as possible. I think you are right that we only set it (for now), but I can see how this could get us into trouble if we ever depended on it. A similar issue happens with the ephemeral names of other non-lv devices, in which case we do update them. > If this doesn't serve a specific purpose I think we shouldn't set the tag (happy > to push a PR). I think the right thing to do would be to make sure that we have the right LV and update it if that changes. This would help commands like `ceph-volume lvm list` which displays that information. > Best, > Jan > > -- > Jan Fajerski > Engineer Enterprise Storage > SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, > HRB 21284 (AG Nürnberg)