cluster name might get overridden
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 22
- Forks
- 16
- PR merge metrics
- No merged PRs in 30d
Description
Currently, 'cluster name' is set when connecting to each host. If one host has 'test' the cluster name gets set to 'test', but if a subsequent node has something else, this will get changed.
This 'cluster' name should go under the node metadata, in the 'ceph' section: data['ceph']['cluster']. The current logic exists in the connection.py module:
if not ceph_medic.config['cluster_name']:
cluster_conf_files, stderr, exit_code = remoto.process.check(conn, ['ls', '/etc/ceph/'])
cluster_name = 'ceph'
if 'ceph.conf' not in cluster_conf_files:
logger.warning('/etc/ceph/ceph.conf was not found, will try to infer the cluster name')
for i in cluster_conf_files:
if i.endswith('conf'):
cluster_name = i.split('.conf')[0]
logger.warning('inferred %s as the cluster name', cluster_name)
ceph_medic.metadata['cluster_name'] = cluster_name
else:
ceph_medic.metadata['cluster_name'] = ceph_medic.config['cluster_name']
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Read the cluster-name logic in connection.py and trace how ceph_medic.metadata is assembled for each host. Verify that the inferred or configured name is stored under each node's data['ceph']['cluster'] without being overwritten by later connections; no test file is named in the issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100