Actions
Bug #12458
closedrbdmap should be changed to map a rbd automatically when starup
Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
% Done:
0%
Source:
other
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):
Description
environment:centos7+ceph v0.87
problem:
- the function do_map() in /etc/init.d/rbdmap will do post-mapping checking after mapped a new image, but the directory /etc/ceph/rbd.d/ doesn't exist at all and isn't created automaticall. Therefore, the “rbdmap” sctrip failed to do post-mapping checking.
- In /etc/ceph/rbdmap, auth parameter "id=client,keyring=/etc/ceph/ceph.client.keyring" is not correct, and it should be "id=admin,keyring=/etc/ceph/ceph.client.admin.keyring", user without "client." prefix.
- the parameter "--keyfile" cant't be used when map a rbd, and it can be replaced by "--keyring". There is no description of "--keyring" in the helping info of "rbd -h".
[root@c8 src]# rbd map im1 --id admin --keyfile /etc/ceph/ceph.client.admin.keyring rbd: failed to get secret rbd: map failed: (22) Invalid argument 2015-07-24 23:27:03.415795 7f585deaf880 -1 auth: failed to decode key '[client.admin] key = AQByfqZVOAGSAhAAGnjXsO2WZpK1qT7ZNQ9IgA== auid = 0 caps mds = "allow" caps mon = "allow *" caps osd = "allow *" [root@c8 src]# rbd map im1 --id admin --keyring /etc/ceph/ceph.client.admin.keyring /dev/rbd2 [root@c8 src]# rbd -h |grep keyring [root@c8 src]#
Updated by Kefu Chai over 8 years ago
- Description updated (diff)
- Category set to 26
Updated by Kefu Chai over 8 years ago
the parameter "--keyfile" cant't be used when map a rbd, and it can be replaced by "--keyring". There is no description of "--keyring" in the helping info of "rbd -h".
keyfile is a key-only file, see http://ceph.com/docs/master/rados/configuration/auth-config-ref/
and please see http://ceph.com/docs/master/man/8/rbd/#cmdoption-rbd--keyfile .
oh, right, the "-h" help message is not in sync with the man page. will fix it. thanks.
Updated by Vikhyat Umrao over 8 years ago
doc fix PR : https://github.com/ceph/ceph/pull/5440
Actions