diff options
author | Stratos Psomadakis <psomas@grnet.gr> | 2011-11-10 08:45:37 -0500 |
---|---|---|
committer | Sage Weil <sage@newdream.net> | 2011-11-11 12:50:19 -0500 |
commit | 224736d9113ab4a7cf3f05c05377492bd99b4b02 (patch) | |
tree | 0a8fe8063e904eebc2f591607faf8711b78016f8 /net/ceph | |
parent | 774ac21da76f5c3018428725074e27a3fd40b128 (diff) |
libceph: Allocate larger oid buffer in request msgs
ceph_osd_request struct allocates a 40-byte buffer for object names.
RBD image names can be up to 96 chars long (100 with the .rbd suffix),
which results in the object name for the image being truncated, and a
subsequent map failure.
Increase the oid buffer in request messages, in order to avoid the
truncation.
Signed-off-by: Stratos Psomadakis <psomas@grnet.gr>
Signed-off-by: Sage Weil <sage@newdream.net>
Diffstat (limited to 'net/ceph')
-rw-r--r-- | net/ceph/osd_client.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c index 733e46008b89..f4f3f58f5234 100644 --- a/net/ceph/osd_client.c +++ b/net/ceph/osd_client.c | |||
@@ -244,7 +244,7 @@ struct ceph_osd_request *ceph_osdc_alloc_request(struct ceph_osd_client *osdc, | |||
244 | ceph_pagelist_init(req->r_trail); | 244 | ceph_pagelist_init(req->r_trail); |
245 | } | 245 | } |
246 | /* create request message; allow space for oid */ | 246 | /* create request message; allow space for oid */ |
247 | msg_size += 40; | 247 | msg_size += MAX_OBJ_NAME_SIZE; |
248 | if (snapc) | 248 | if (snapc) |
249 | msg_size += sizeof(u64) * snapc->num_snaps; | 249 | msg_size += sizeof(u64) * snapc->num_snaps; |
250 | if (use_mempool) | 250 | if (use_mempool) |