get_osd_tree incorrectly parsing of ceph tree
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
charms.ceph |
Fix Released
|
Undecided
|
Robert Gildein |
Bug Description
The function get_osd_tree are incorrectly parses data from the
`ceph osd tree --fromat=json` output.
The function searches for host with type==host, but wrongly assumes
that it's contains information about root/rack/row etc.
Sample of current information, where it can be seen that they do not
contain any information about the parents.
```bash
{
"id": -5,
"name": "juju-1ea5b4-bug1911006-0",
"type": "host",
"type_id": 1,
"pool_weights": {},
"children": [1]
}
```
This results in the CrushLocation object being created with the correct
name and id, but the other information is empty.
String representation of Crush Location from example above.
```bash
name: juju-1ea5b4-bug1911006-0 id: -5 host: None rack: None row: None datacenter: None chassis :None root: None
```
Changed in charm-ceph-osd: | |
status: | New → In Progress |
assignee: | nobody → Robert Gildein (rgildein) |
review: https:/ /review. opendev. org/c/openstack /charms. ceph/+/ 780280