Actions
Bug #2532
closedrbd command allows passing in -K </path/to/secret>, but long version of (--secret) does not work
Status:
Resolved
Priority:
Normal
Assignee:
-
Target version:
-
% Done:
0%
Source:
Development
Tags:
Backport:
Regression:
Severity:
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
While rolling back a snapshot I succeed when I pass in `-K with location of key file, but it looks like I fail when I attempt to use `--secret /path/to/secret` or `--secret=/path/to/secret`.
# rbd --name=client.admin -K ./secret.key --pool lab8_pool_a snap rollback --snap=lab8-001-20120607-001 lab8-001 Rolling back to snapshot: 100% complete...done. # rbd --name=client.admin --secret ./secret.key --pool lab8_pool_a snap rollback --snap=lab8-001-20120607-001 lab8-001 2012-06-08 05:37:54.073360 7ff75be00780 -1 auth: failed to open keyring from /etc/ceph/ceph.client.admin.keyring 2012-06-08 05:37:54.073382 7ff75be00780 -1 monclient(hunting): failed to open keyring: (2) No such file or directory 2012-06-08 05:37:54.073418 7ff75be00780 0 librados: client.admin initialization error (2) No such file or directory error: couldn't connect to the cluster! # rbd --name=client.admin --secret=./secret.key --pool lab8_pool_a snap rollback --snap=lab8-001-20120607-001 lab8-001 2012-06-08 05:38:01.521293 7fb9a85fa780 -1 auth: failed to open keyring from /etc/ceph/ceph.client.admin.keyring 2012-06-08 05:38:01.521326 7fb9a85fa780 -1 monclient(hunting): failed to open keyring: (2) No such file or directory 2012-06-08 05:38:01.521359 7fb9a85fa780 0 librados: client.admin initialization error (2) No such file or directory error: couldn't connect to the cluster!
It appears that the map operation is the other way around, where `--secret` does work, while the `-K` does not.
rbd --name=client.admin --pool lab8_pool_a --snap=lab8-001-20120607-001 -K ./secret.key map lab8-001; echo $? add failed: (22) Invalid argument 1 rbd --name=client.admin --pool lab8_pool_a --snap=lab8-001-20120607-001 --secret ./secret.key map lab8-001; echo $? 0 # rbd --name=client.admin --pool lab8_pool_a --snap=lab8-001-20120607-001 --secret=./secret.key map lab8-001; echo $? 0
Actions