Actions
Bug #48536
closedceph tool: osd crush create-or-move cannot accept multiple crush buckets
Status:
Rejected
Priority:
Normal
Assignee:
-
Category:
Administration/Usability
Target version:
-
% Done:
0%
Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(RADOS):
ceph cli
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
gregf@vossi01:~/src/ceph/build [wip-stretch-fixes]$ ./bin/ceph osd crush create-or-move osd.0 1.0 "root=default,host=vossi02" *** DEVELOPER MODE: setting PATH, PYTHONPATH and LD_LIBRARY_PATH *** 2020-12-10T11:59:33.348+0000 7fce4d105700 -1 WARNING: all dangerous and experimental features are enabled. 2020-12-10T11:59:33.383+0000 7fce4d105700 -1 WARNING: all dangerous and experimental features are enabled. Invalid command: invalid chars , in root=default,host=vossi02 osd crush create-or-move <id|osd.id> <weight:float> <args>... : create entry or move existing entry for <name> <weight> at/to location <args> Error EINVAL: invalid command
This doesn't work with spaces or anything, either -- the MonCommands.h file only allows characters in [A-Za-z0-9-_.=].
Updated by Greg Farnum over 3 years ago
I'm actually a little confused about if this works separately from the CLI, in fact. I'm probably just not understanding what's happening in the command parsing, since somehow or other the OSD seems to manage to place itself in a particular host in a particular root, but it really looks like we just take the string we're given, put it into a 1-element vector<string>, and then parse the beginning of just that one string into a key=value crush location. I'm puzzled.
Updated by Greg Farnum over 3 years ago
- Status changed from New to Rejected
I'm dumb; this works just fine with the expected syntax:
$ ./bin/ceph osd crush create-or-move osd.3 1.0 root=default rack=testrack host=vossi02 *** DEVELOPER MODE: setting PATH, PYTHONPATH and LD_LIBRARY_PATH *** 2021-01-08T19:05:55.481+0000 7fa6a77c9700 -1 WARNING: all dangerous and experimental features are enabled. 2021-01-08T19:05:55.522+0000 7fa6a77c9700 -1 WARNING: all dangerous and experimental features are enabled. create-or-move updating item name 'osd.3' weight 1 at location {host=vossi02,rack=testrack,root=default} to crush map
Actions