]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
9 years agolibrbd: split large AioWrite journal events 9048/head
Jason Dillaman [Fri, 6 May 2016 04:08:38 +0000 (00:08 -0400)]
librbd: split large AioWrite journal events

Ensure that AioWrite journal events fit within a single
journal object.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 70b9fbf2745c795fe345f0298a2f30af80a12985)

9 years agojournal: prohibit journal entries larger than the soft object size
Jason Dillaman [Fri, 6 May 2016 01:30:18 +0000 (21:30 -0400)]
journal: prohibit journal entries larger than the soft object size

This avoids complications like a librbd write event of 128MB trying
to fit within a 24MB journal object.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit d5f307dec10429a1ffc042919b71ac25466a1b72)

9 years agoMerge pull request #9036 from dillaman/wip-15814
Jason Dillaman [Tue, 10 May 2016 17:28:11 +0000 (13:28 -0400)]
Merge pull request #9036 from dillaman/wip-15814

jewel: librbd: fix get/list mirror image status API

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agorbd-mirror: fixup to get/list mirror image status API 9036/head
Mykola Golub [Tue, 10 May 2016 09:29:12 +0000 (12:29 +0300)]
rbd-mirror: fixup to get/list mirror image status API

- embed name and rbd_mirror_image_info_t into rbd_mirror_image_status_t;
- index image status list by image id to make 'start' work correctly;
- provide rbd_mirror_image_status_list_cleanup function.

Fixes: #15771
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
(cherry picked from commit e6c709b3a8be489a900178b8b0d962705d5687e9)

9 years agoMerge pull request #9003 from dillaman/wip-15743
Jason Dillaman [Tue, 10 May 2016 17:15:23 +0000 (13:15 -0400)]
Merge pull request #9003 from dillaman/wip-15743

jewel: librbd: reduce log level for image format 1 warning

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #9010 from dillaman/wip-15736
Jason Dillaman [Tue, 10 May 2016 17:13:27 +0000 (13:13 -0400)]
Merge pull request #9010 from dillaman/wip-15736

jewel: rbd-mirror: admin socket commands to start/stop/restart mirroring

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agorbd-mirror: admin socket commands to start/stop/restart mirroring 9010/head
Mykola Golub [Thu, 28 Apr 2016 06:32:33 +0000 (09:32 +0300)]
rbd-mirror: admin socket commands to start/stop/restart mirroring

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
(cherry picked from commit a22cf518f9cc0872f72a8a850ea01558094ebd00)

9 years agoqa/workunits/rbd: fix rbd-mirror log file name
Mykola Golub [Sun, 1 May 2016 19:04:46 +0000 (22:04 +0300)]
qa/workunits/rbd: fix rbd-mirror log file name

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
(cherry picked from commit 4c28fc2aa378c10ce6e78b1a2f98d5e14ac211e9)

9 years agorbd-mirror: make image replayer asok commands available when not started
Mykola Golub [Thu, 28 Apr 2016 06:23:35 +0000 (09:23 +0300)]
rbd-mirror: make image replayer asok commands available when not started

Initially the asok commands were registered only after the image
replayer start (and unregistered on stop) because their names were
built using remote pool and image names, which became known only after
start.

Now, the asok commands are registered on the image replayer construction
using the temporary name "remote_pool_name/global_image_id". They are
re-registered using "remote_pool_name/remote_image_name" when the
image replayer is started.  Also the commands are not unregistered on
the image replayer stop.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
(cherry picked from commit 21790484dc66e97e7625b5b2afabb7efe3a92b08)

9 years agoqa/workunits/rbd: add env vars to adapt rbd_mirror.sh to teuthology
Josh Durgin [Sat, 2 Apr 2016 01:15:33 +0000 (18:15 -0700)]
qa/workunits/rbd: add env vars to adapt rbd_mirror.sh to teuthology

With these set, this script can work in teuthology, where we want to
control the how daemons run and their log locations, valgrind
settings, etc. The workunit task always sets CEPH_ID, and allows
other env vars to be configured optionally.

The RBD_MIRROR_USE_EXISTING_CLUSTER option can also speed up local testing.

Signed-off-by: Josh Durgin <jdurgin@redhat.com>
(cherry picked from commit dcd11a1f262e0c56bb1b37d54283cda06abbf4c7)

9 years agoqa: rbd_mirror.sh: change parameters to cluster rather than daemon name
Josh Durgin [Thu, 7 Apr 2016 23:57:14 +0000 (16:57 -0700)]
qa: rbd_mirror.sh: change parameters to cluster rather than daemon name

Daemon name is only useful to differentiate asok and pid filenames, so
just inline its use there. Everywhere else replace the 'daemon'
parameter with cluster or local_cluster as appropriate.

Remove the CLUSTER{1,2}_DAEMON vars as well, since they are no longer
used.

Signed-off-by: Josh Durgin <jdurgin@redhat.com>
(cherry picked from commit 5fe64fa806f3bbdbdb950a5643238cc2508814b0)

9 years agoMerge pull request #9005 from dillaman/wip-15716
Jason Dillaman [Tue, 10 May 2016 17:04:09 +0000 (13:04 -0400)]
Merge pull request #9005 from dillaman/wip-15716

jewel: rbd-nbd: fix rbd-nbd aio callback error handling

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agojewel: librbd: unlock image if journal error encountered during lock
Jason Dillaman [Tue, 10 May 2016 17:03:38 +0000 (13:03 -0400)]
jewel: librbd: unlock image if journal error encountered during lock

jewel: librbd: unlock image if journal error encountered during lock

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #9009 from dillaman/wip-15713
Jason Dillaman [Tue, 10 May 2016 17:02:24 +0000 (13:02 -0400)]
Merge pull request #9009 from dillaman/wip-15713

jewel: librbd: possible race condition leads to use-after-free

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agolibrbd: possible race condition leads to use-after-free 9009/head
Jason Dillaman [Tue, 3 May 2016 11:41:30 +0000 (07:41 -0400)]
librbd: possible race condition leads to use-after-free

The invoke async operation state machine can complete before the
owner lock is released.  Use a stack reference to prevent
use-after-free.

Fixes: http://tracker.ceph.com/issues/15690
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit d9421a25b582e41550526714b71fb55f05abb1de)

9 years agoMerge pull request #9004 from dillaman/wip-15708
Jason Dillaman [Tue, 10 May 2016 16:53:30 +0000 (12:53 -0400)]
Merge pull request #9004 from dillaman/wip-15708

jewel: rbd: help message distinction between commands and aliases

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #8972 from Abhishekvrshny/wip-15697-jewel
Jason Dillaman [Tue, 10 May 2016 16:53:00 +0000 (12:53 -0400)]
Merge pull request #8972 from Abhishekvrshny/wip-15697-jewel

jewel: python: clone operation will fail if config overridden with "rbd default format = 1"

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #9008 from dillaman/wip-15698
Jason Dillaman [Tue, 10 May 2016 16:50:43 +0000 (12:50 -0400)]
Merge pull request #9008 from dillaman/wip-15698

jewel: rbd-mirror: lockdep error during bootstrap

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agolibrbd: disable automatic refresh of image upon lock message 9008/head
Jason Dillaman [Mon, 2 May 2016 14:33:50 +0000 (10:33 -0400)]
librbd: disable automatic refresh of image upon lock message

There is no need to refresh the image upon request/release/acquire
of the exclusive lock.  The next IO or maintenance op will kick off
the refresh.  This is interfering with the refresh state machine
unit test case (since two concurrent refreshes shouldn't be possible).

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit ee617a0ca56d752daf62bfffa59219b2c540a428)

9 years agolibrbd: update_features should release lock if acquired
Jason Dillaman [Mon, 2 May 2016 14:26:29 +0000 (10:26 -0400)]
librbd: update_features should release lock if acquired

There is a small window where requests are unblocked and before
the image is shut down where new requests can be accepted.  These
are correctly canceled during the shut down, but it can lead to
warning messages.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 608e09851396a9eeb7cf6dc1c7f687ef7a033601)

9 years agolibrbd: avoid applying refreshed image config within librados callback
Jason Dillaman [Mon, 2 May 2016 13:27:29 +0000 (09:27 -0400)]
librbd: avoid applying refreshed image config within librados callback

There is a potential that a synchronous API call could deadlock a
image refresh.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit ce5c701bc47b0959f8453b6b92dee4804d3b1d75)

9 years agorbd-mirror: don't use temporary string for snap operation
Jason Dillaman [Mon, 2 May 2016 12:42:35 +0000 (08:42 -0400)]
rbd-mirror: don't use temporary string for snap operation

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 06faf83bbfab000c8200a9cbe781adb0082b3f7b)

9 years agolibrbd: avoid recursive locking within operation state machine
Jason Dillaman [Mon, 2 May 2016 12:31:54 +0000 (08:31 -0400)]
librbd: avoid recursive locking within operation state machine

Fixes: http://tracker.ceph.com/issues/15664
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 91a4890ee78c25391c1548fdacb2b51c46a47415)

9 years agoMerge pull request #8869 from Abhishekvrshny/wip-15669-jewel
Jason Dillaman [Tue, 10 May 2016 16:47:01 +0000 (12:47 -0400)]
Merge pull request #8869 from Abhishekvrshny/wip-15669-jewel

jewel: Errors encountered disabling object-map while flatten is in-progress

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #8870 from Abhishekvrshny/wip-15668-jewel
Jason Dillaman [Tue, 10 May 2016 16:46:12 +0000 (12:46 -0400)]
Merge pull request #8870 from Abhishekvrshny/wip-15668-jewel

jewel: rbd disk-usage CLI command should support calculating full image usage

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #8868 from Abhishekvrshny/wip-15666-jewel
Jason Dillaman [Tue, 10 May 2016 16:35:41 +0000 (12:35 -0400)]
Merge pull request #8868 from Abhishekvrshny/wip-15666-jewel

jewel: rbd CLI to retrieve rbd mirror state for a pool / specific image

Conflicts:
src/tools/rbd_mirror/ImageReplayer.cc: trivial resolution

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #9046 from dillaman/wip-fix-snapc-validation-jewel
Jason Dillaman [Tue, 10 May 2016 16:33:33 +0000 (12:33 -0400)]
Merge pull request #9046 from dillaman/wip-fix-snapc-validation-jewel

jewel: librbd: put the validation of image snap context earlier

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agolibrbd: put the validation of image snap context earlier 9046/head
runsisi [Wed, 20 Apr 2016 01:55:39 +0000 (09:55 +0800)]
librbd: put the validation of image snap context earlier

we'd better validate the snap context right after we got the mutable
metadata before we could go any further

Signed-off-by: runsisi <runsisi@zte.com.cn>
(cherry picked from commit ca8ae66ba42e7a598ad23ed911938589dc288456)

9 years agoMerge pull request #8867 from Abhishekvrshny/wip-15661-jewel
Jason Dillaman [Tue, 10 May 2016 16:31:10 +0000 (12:31 -0400)]
Merge pull request #8867 from Abhishekvrshny/wip-15661-jewel

jewel: Parent image is closed twice if error encountered while opening

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #8866 from Abhishekvrshny/wip-15660-jewel
Jason Dillaman [Tue, 10 May 2016 16:30:12 +0000 (12:30 -0400)]
Merge pull request #8866 from Abhishekvrshny/wip-15660-jewel

jewel: rbd-mirror can crash if start up is interrupted

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #9044 from dillaman/wip-librbd-bad-header-jewel
Jason Dillaman [Tue, 10 May 2016 16:29:02 +0000 (12:29 -0400)]
Merge pull request #9044 from dillaman/wip-librbd-bad-header-jewel

jewel: librbd: does not crash if image header is too short

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agolibrbd: does not crash if image header is too short 9044/head
Kefu Chai [Wed, 27 Apr 2016 16:59:34 +0000 (00:59 +0800)]
librbd: does not crash if image header is too short

if something goes wrong with the object, and returns a chunk shorter
than expected, don't panic

Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit 7b52183addda83f98c8b1f37d3de20ca0fc4687b)

9 years agoMerge pull request #8803 from SUSE/wip-15605-jewel
Jason Dillaman [Tue, 10 May 2016 16:26:48 +0000 (12:26 -0400)]
Merge pull request #8803 from SUSE/wip-15605-jewel

jewel: Potential double free of SetSnapRequest instance

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #8865 from Abhishekvrshny/wip-15649-jewel
Jason Dillaman [Tue, 10 May 2016 16:16:09 +0000 (12:16 -0400)]
Merge pull request #8865 from Abhishekvrshny/wip-15649-jewel

jewel: possible double-free of object map invalidation request upon error

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
9 years agoMerge pull request #8930 from theanalyst/wip-15707-jewel
Yehuda Sadeh [Tue, 10 May 2016 15:31:02 +0000 (08:31 -0700)]
Merge pull request #8930 from theanalyst/wip-15707-jewel

jewel: multisite: Issues with Deleting Buckets

9 years agoMerge pull request #9029 from theanalyst/wip-15680
Yehuda Sadeh [Tue, 10 May 2016 15:30:52 +0000 (08:30 -0700)]
Merge pull request #9029 from theanalyst/wip-15680

jewel: rgw: radosgw-admin zone set cuts pool names short if name starts with a period

9 years agoMerge pull request #9022 from yehudasa/wip-rgw-leak-3-jewel
Yehuda Sadeh [Tue, 10 May 2016 15:30:03 +0000 (08:30 -0700)]
Merge pull request #9022 from yehudasa/wip-rgw-leak-3-jewel

jewel: rgw: leak fixes

9 years agoMerge pull request #9021 from yehudasa/wip-rgw-xstorageurl-fix-jewel
Yehuda Sadeh [Tue, 10 May 2016 15:29:52 +0000 (08:29 -0700)]
Merge pull request #9021 from yehudasa/wip-rgw-xstorageurl-fix-jewel

jewel: rgw: fix printing wrong X-Storage-Url in Swift's TempAuth.

9 years agoMerge pull request #9020 from yehudasa/wip-15597-jewel
Yehuda Sadeh [Tue, 10 May 2016 15:29:27 +0000 (08:29 -0700)]
Merge pull request #9020 from yehudasa/wip-15597-jewel

jewel: rgw: fix issue #15597

9 years agoMerge pull request #9019 from yehudasa/wip-rgw-admin-zonegroup-jewel
Yehuda Sadeh [Tue, 10 May 2016 15:29:18 +0000 (08:29 -0700)]
Merge pull request #9019 from yehudasa/wip-rgw-admin-zonegroup-jewel

jewel: radosgw-admin: add missing --zonegroup-id to usage

9 years agoMerge pull request #9018 from yehudasa/wip-15626-jewel
Yehuda Sadeh [Tue, 10 May 2016 15:29:03 +0000 (08:29 -0700)]
Merge pull request #9018 from yehudasa/wip-15626-jewel

rgw: add AWS4 completion support for RGW_OP_SET_BUCKET_WEBSITE

9 years agoMerge pull request #9017 from yehudasa/wip-15625-jewel
Yehuda Sadeh [Tue, 10 May 2016 15:28:50 +0000 (08:28 -0700)]
Merge pull request #9017 from yehudasa/wip-15625-jewel

jewel: rgw: segfault at RGWAsyncGetSystemObj

9 years agoMerge pull request #9016 from yehudasa/wip-rgw-admin-modify-jewel
Yehuda Sadeh [Tue, 10 May 2016 15:28:37 +0000 (08:28 -0700)]
Merge pull request #9016 from yehudasa/wip-rgw-admin-modify-jewel

jewel: radosgw-admin: update usage for zone[group] modify

9 years agoMerge pull request #9015 from yehudasa/wip-rgw-zonegroup-remove-jewel
Yehuda Sadeh [Tue, 10 May 2016 15:27:56 +0000 (08:27 -0700)]
Merge pull request #9015 from yehudasa/wip-rgw-zonegroup-remove-jewel

jewel: radosgw-admin: zonegroup remove command

9 years agotest: update rbd integration cram test to remove format 1 warning 9003/head
Jason Dillaman [Tue, 10 May 2016 12:33:03 +0000 (08:33 -0400)]
test: update rbd integration cram test to remove format 1 warning

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 098038fad47b181a9ddd11767397082b05405be5)

9 years agorgw: fix suffix in RGWZoneParams::fix_pool_names() 9029/head
Yehuda Sadeh [Mon, 25 Apr 2016 22:09:47 +0000 (15:09 -0700)]
rgw: fix suffix in RGWZoneParams::fix_pool_names()

Fixes: http://tracker.ceph.com/issues/15598
Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 6f6b0c925994b0369eda390a6b3fd20005e70c9b)

9 years agorgw: code cleanup 9020/head
Yehuda Sadeh [Mon, 9 May 2016 21:23:03 +0000 (14:23 -0700)]
rgw: code cleanup

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit d53ffbfe65611425b08af71e0d24bfe2a0076f1e)

9 years agorgw: upgrade default zonegroup and set correct zone[group] id
Yehuda Sadeh [Tue, 26 Apr 2016 18:31:43 +0000 (11:31 -0700)]
rgw: upgrade default zonegroup and set correct zone[group] id

Fixes: http://tracker.ceph.com/issues/15597
Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 27806c71922eef2f4cde360d7ba40dee9d5bd4bd)

9 years agorgw: RGWHTTPClient requests can unregister themselves early 9022/head
Yehuda Sadeh [Thu, 5 May 2016 17:57:05 +0000 (10:57 -0700)]
rgw: RGWHTTPClient requests can unregister themselves early

No need to wait for req_state to complete anymore.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 91f61d68bf5fc39152d75fbc633f088e17d53d9e)

Conflicts:
src/rgw/rgw_http_client.cc

9 years agorgw: move around sync_env.init()
Yehuda Sadeh [Thu, 5 May 2016 01:08:38 +0000 (18:08 -0700)]
rgw: move around sync_env.init()

call sync_env.init() even if we're initalized in RGWRemoteDataLog::init()

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 3d8442effc1c175e0b7c5064ed41bc642f6cdcb0)

9 years agorgw: rados crs, explicit cleanup
Yehuda Sadeh [Tue, 3 May 2016 19:01:55 +0000 (12:01 -0700)]
rgw: rados crs, explicit cleanup

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 1c876eb3873692042c0af3644f8ee3ad15ffdbf5)

9 years agorgw: RGWHTTPManager, avoid referring to req_data->client when completing
Yehuda Sadeh [Tue, 3 May 2016 19:00:46 +0000 (12:00 -0700)]
rgw: RGWHTTPManager, avoid referring to req_data->client when completing

this is past calling req_data->finish(), client can be destroyed by now

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 7ada4df124a71eae413e7dec0e25264a8deffcad)

9 years agorgw: civetweb_callback() refer to store inside lock
Yehuda Sadeh [Tue, 3 May 2016 18:59:11 +0000 (11:59 -0700)]
rgw: civetweb_callback() refer to store inside lock

pe->store might change when reconfiguring

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 2ca38dab071c7d20a224a4e1dacfd68548fe52dd)

9 years agorgw: RGWPeriodPusher, stop http manager explicitly
Yehuda Sadeh [Tue, 3 May 2016 17:03:14 +0000 (10:03 -0700)]
rgw: RGWPeriodPusher, stop http manager explicitly

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 98433e589f2a8b519726ed23b1565c5eb331c68e)

9 years agorgw: RGWHTTPManager, can call stop() more than once
Yehuda Sadeh [Tue, 3 May 2016 17:02:02 +0000 (10:02 -0700)]
rgw: RGWHTTPManager, can call stop() more than once

destructor calls stop(), but it can be also called explicitly, if caller
wants to ensure requests are not being handled anymore.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit bdce81a2ae00f154420386e107a104cbf100d96d)

9 years agorgw: RGWReadRESTResourceCR, fix refcounting
Yehuda Sadeh [Tue, 3 May 2016 17:01:33 +0000 (10:01 -0700)]
rgw: RGWReadRESTResourceCR, fix refcounting

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit d1ec31def71505dc95139fbdd3b49c92fec1d296)

9 years agorgw: RGWReadRemoteDataLogShardCR fix destructor
Yehuda Sadeh [Tue, 3 May 2016 16:59:47 +0000 (09:59 -0700)]
rgw: RGWReadRemoteDataLogShardCR fix destructor

was missing destructor, constructor was broken

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 95162a4c1bf61f7329e363b7efd5686f7e1025f0)

9 years agorgw: RGWDataSyncStatusManager, cleanup if failing init
Yehuda Sadeh [Tue, 3 May 2016 01:13:17 +0000 (18:13 -0700)]
rgw: RGWDataSyncStatusManager, cleanup if failing init

init can be called more than once, ended up with leaking some resources

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 14cd44e0847fd914068f48dd0208ce7c1fe4eecb)

9 years agorgw: rest crs, explicitly call cleanup
Yehuda Sadeh [Fri, 29 Apr 2016 20:04:13 +0000 (13:04 -0700)]
rgw: rest crs, explicitly call cleanup

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit a3a3f4f5883f3fc2bf47a7ebfa538206b7ab51d9)

9 years agorgw: more leaks fixes
Yehuda Sadeh [Fri, 29 Apr 2016 00:03:21 +0000 (17:03 -0700)]
rgw: more leaks fixes

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit cb797d4fd754b4a33eb34c249da3aabc65a7aba3)

9 years agorgw: drop a reference to http op
Yehuda Sadeh [Wed, 27 Apr 2016 23:39:36 +0000 (16:39 -0700)]
rgw: drop a reference to http op

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 4442d1c19acfc28c2dd4a011365ebebe08750963)

9 years agorgw: fix printing wrong X-Storage-Url in Swift's TempAuth. 9021/head
Radoslaw Zarzynski [Sun, 24 Apr 2016 15:41:55 +0000 (17:41 +0200)]
rgw: fix printing wrong X-Storage-Url in Swift's TempAuth.

If the option "rgw_swift_account_in_url" is being set to true,
both user and subuser IDs will be present in the X-Storage-Url
header generated by the implementation of Swift API's TempAuth.
This patch rectifies this behavior and makes that only the user
identifier will be placed there.

Fixes: http://tracker.ceph.com/issues/15667
Signed-off-by: Radoslaw Zarzynski <rzarzynski@mirantis.com>
(cherry picked from commit 88f4c67d822388d2038454a25ead7e9a11f404b5)

9 years agoradosgw-admin: add missing --zonegroup-id to usage 9019/head
Casey Bodley [Tue, 26 Apr 2016 19:20:45 +0000 (15:20 -0400)]
radosgw-admin: add missing --zonegroup-id to usage

also clarified that --rgw-zone takes the zone by name

Signed-off-by: Casey Bodley <cbodley@redhat.com>
Reported-by: John Wilkins <jowilkin@redhat.com>
(cherry picked from commit 97fad754565b262529073e1b9f8d1799bfdfe0de)

9 years agorgw: don't allow any concurrent sync requests on the same key 9017/head
Yehuda Sadeh [Wed, 27 Apr 2016 22:09:55 +0000 (15:09 -0700)]
rgw: don't allow any concurrent sync requests on the same key

We used to allow concurrent requests, as long as these had different op,
which wasn't correct.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit edea6d58dd25995bcc1ed4fc5be6f72ce4a6835a)

9 years agorgw: collect children after waiting for them
Yehuda Sadeh [Tue, 26 Apr 2016 22:59:33 +0000 (15:59 -0700)]
rgw: collect children after waiting for them

Otherwise we're going to busy loop there.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 806fb85d18653910863ba6b8cb56b8db1a0fa3d2)

9 years agorgw: don't pass object context into async coroutines
Yehuda Sadeh [Tue, 26 Apr 2016 22:29:41 +0000 (15:29 -0700)]
rgw: don't pass object context into async coroutines

Fixes: http://tracker.ceph.com/issues/15625
The async read data/attrs coroutines may outlive the callers. Instead
of introducing a complicated refcounting scheme, just don't pass it in.
Anyway, it was not thread safe, and the benefit of using it is not
clear.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit b225d1758057efc30721aad25447d54fa36e4cb2)

9 years agorgw: check for status >= 0
Yehuda Sadeh [Fri, 22 Apr 2016 00:24:16 +0000 (17:24 -0700)]
rgw: check for status >= 0

Fixes: #15565
check only verified that status was > 0, so we ended not updating mtime for
the target object. This resulted in a continuous sync of objects.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 255f19d9ef964536f2db17f70749f489330262a6)

9 years agorgw: don't try to delete object if does not exist
Yehuda Sadeh [Fri, 22 Apr 2016 21:23:22 +0000 (14:23 -0700)]
rgw: don't try to delete object if does not exist

If we know that the object does not exist, no need to remove it.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 8d59a30d56b5f197a293f7fba6ebb1a630a33a05)

9 years agorgw, cls/rgw: store removed object mtime in bi log
Yehuda Sadeh [Fri, 22 Apr 2016 18:55:28 +0000 (11:55 -0700)]
rgw, cls/rgw: store removed object mtime in bi log

Store the mtime of the object that was removed in the bucket index log.
This will be used in data sync.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
(cherry picked from commit 80d64049937e1930ea8273fdad76a51493a5e14a)

9 years agorgw: add AWS4 completion support for RGW_OP_SET_BUCKET_WEBSITE 9018/head
Javier M. Mellid [Wed, 27 Apr 2016 18:28:08 +0000 (20:28 +0200)]
rgw: add AWS4 completion support for RGW_OP_SET_BUCKET_WEBSITE

Fixes: http://tracker.ceph.com/issues/15626
Signed-off-by: Javier M. Mellid <jmunhoz@igalia.com>
(cherry picked from commit 05373354e4725c3fc675df652fbf97da26160bcb)

9 years agoradosgw-admin: update usage for zone[group] modify 9016/head
Casey Bodley [Wed, 27 Apr 2016 22:06:45 +0000 (18:06 -0400)]
radosgw-admin: update usage for zone[group] modify

the help strings indicated that only --master could be changed

Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit 410d432d11541a29c3fd4608a070cecf8dc2766e)

9 years agotest/rgw: add test_zonegroup_remove 9015/head
Casey Bodley [Fri, 6 May 2016 18:26:46 +0000 (14:26 -0400)]
test/rgw: add test_zonegroup_remove

Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit e2b27c7266f0ace372dbf94e062598fd7a575795)

9 years agotest/rgw: index zones by name instead of insertion order
Casey Bodley [Fri, 6 May 2016 18:26:23 +0000 (14:26 -0400)]
test/rgw: index zones by name instead of insertion order

Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit 6327ade12bf0255c3b35bd6407f1dd2bcc6936fa)

9 years agoradosgw-admin: add missing 'zonegroup remove'
Casey Bodley [Mon, 2 May 2016 15:38:24 +0000 (11:38 -0400)]
radosgw-admin: add missing 'zonegroup remove'

Fixes: http://tracker.ceph.com/issues/15684
Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit db0fa48ed5958d37928f893acd44cd66b6b9b990)

9 years agorgw: RGWZoneGroup::remove_zone() takes zone id
Casey Bodley [Mon, 2 May 2016 15:36:58 +0000 (11:36 -0400)]
rgw: RGWZoneGroup::remove_zone() takes zone id

Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit 3a451511fb38a5f1cd83ca3610c91141e7279f63)

9 years agolibrbd: unlock image if journal error encountered during lock 9007/head
Jason Dillaman [Tue, 3 May 2016 14:15:08 +0000 (10:15 -0400)]
librbd: unlock image if journal error encountered during lock

Explicitly unlock to prevent a client from accidentally blacklisting
itself when retrying the lock.

Fixes: http://tracker.ceph.com/issues/15709
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit a11f5e8e55fc448ed60616cbf66a3ea7db2247b9)

9 years agoMerge pull request #9006 from athanatos/wip-15655-jewel
Sage Weil [Mon, 9 May 2016 17:54:58 +0000 (13:54 -0400)]
Merge pull request #9006 from athanatos/wip-15655-jewel

OSDMonitor: avoid underflow in reweight-by-utilization if max_change=1

Reviewed-by: Sage Weil <sage@redhat.com>
9 years agorbd-nbd: Fix aio_callback error handling 9005/head
cy.l@inwinstack.com [Sat, 30 Apr 2016 07:22:29 +0000 (15:22 +0800)]
rbd-nbd: Fix aio_callback error handling

Change aio_callback return code handling for NBD_CMD_READ command.

Tracker:
http://tracker.ceph.com/issues/15604

Signed-off-by: Chang-Yi Lee <cy.l@inwinstack.com>
(cherry picked from commit ee211295441b126a995c07820176cfc966ab61c5)

9 years agoFix RBD-NBD aio_callback error handling
cy.l@inwinstack.com [Wed, 27 Apr 2016 03:00:25 +0000 (11:00 +0800)]
Fix RBD-NBD aio_callback error handling

Tracker-Id: #15604

Signed-off-by: Chang-Yi Lee <cy.l@inwinstack.com>
(cherry picked from commit f8f6c1dc865b7ed642fec3f416e5eca5e91523d0)

9 years agorbd:make a distinction of help message between ''rbd snap rollback" and "rbd snap... 9004/head
YongQiang [Fri, 22 Apr 2016 15:20:31 +0000 (11:20 -0400)]
rbd:make a distinction of help message between ''rbd snap rollback" and "rbd snap revert"

Fixes: https://tracker.ceph.com/issues/15521
Signed-off-by: Yongqiang He <he.yongqiang@h3c.com>
(cherry picked from commit 1bf26509c6efd06a8facc0e45ab42255592ca74d)

9 years agolibrbd: reduce log level for image format 1 warning
Jason Dillaman [Wed, 4 May 2016 17:36:06 +0000 (13:36 -0400)]
librbd: reduce log level for image format 1 warning

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit c87f383b65ccc2e91645394f1c75de1c2d52e1e1)

9 years agoosdc/Objecter: fix race condition for sortbitwise flag detection
xie xingguo [Tue, 26 Apr 2016 07:12:17 +0000 (15:12 +0800)]
osdc/Objecter: fix race condition for sortbitwise flag detection

During list_objects/list_nobjects(), we are checking osdmap's
sortbitwise flag setting without holding rwlock in hand, which
is a potential race condition.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
(cherry picked from commit 7fb6be706be2454cc2a831df29808997f0aa5ab3)

9 years agolibrbd: default clone operation to image format 2 8972/head
Jason Dillaman [Mon, 2 May 2016 19:06:51 +0000 (15:06 -0400)]
librbd: default clone operation to image format 2

Image format 1 doesn't support clones, so unless the user
overrode the setting, default to format 2.

Fixes: http://tracker.ceph.com/issues/15685
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit f24c70f54343aa6698af8ac1f0774282b0659968)

9 years agolibrbd: add rbd_image_options_is_set helper method to API
Jason Dillaman [Mon, 2 May 2016 18:51:31 +0000 (14:51 -0400)]
librbd: add rbd_image_options_is_set helper method to API

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 2633b045e0b57827cc10c2e7707bd5a5e344e59a)

9 years agorgw_op: pass delete bucket op to master zone first 8930/head
Abhishek Lekshmanan [Tue, 19 Apr 2016 13:20:53 +0000 (15:20 +0200)]
rgw_op: pass delete bucket op to master zone first

Basically first ask the master to process a delete bucket request before
we process it in the zone locally, otherwise we reach a situation where
we drop the bucket locally and master will still maintain an index

Fixes: http://tracker.ceph.com/issues/15540
Signed-off-by: Abhishek Lekshmanan <abhishek@suse.com>
(cherry picked from commit da6b44a6e47399493adae53ad3c36a029f1e2a23)

9 years agorgw: add errno entry for -ENOTEMPTY
Abhishek Lekshmanan [Tue, 19 Apr 2016 13:20:07 +0000 (15:20 +0200)]
rgw: add errno entry for -ENOTEMPTY

currently if master returns an -ENOTEMTPY, we return a -EIO as we dont
have an entry for this

Signed-off-by: Abhishek Lekshmanan <abhishek@suse.com>
(cherry picked from commit 40c3bfef8cc3bce7d15fbb0e135c1a909ee59368)

9 years agofix deb package /etc/default/ceph location
Alexandre Derumier [Thu, 28 Apr 2016 20:48:52 +0000 (22:48 +0200)]
fix deb package /etc/default/ceph location

commit 7384a14f243519547a61534d22e21e6069aae016 have introduce
the /etc/default/ceph file at a wrong location : /etc/default/ceph/ceph

(cherry picked from commit 13804fafd4c33068d8ed6d0480b594daec0f9341)

9 years agomon/OSDMonitor: improve reweight_by_utilization() logic
xie xingguo [Tue, 26 Apr 2016 03:13:32 +0000 (11:13 +0800)]
mon/OSDMonitor: improve reweight_by_utilization() logic

By calling reweight_by_utilization() method, we are aiming at an evener result
of utilization among all osds. To achieve this, we shall decrease weights of
osds which are currently overloaded, and try to increase weights of osds which
are currently underloaded when it is possible.
However, we can't do this all at a time in order to avoid a massive pg migrations
between osds. Thus we introduce a max_osds limit to smooth the progress.

The problem here is that we have sorted the utilization of all osds in a descending
manner and we always try to decrease the weights of the most overloaded osds
since they are most likely to encounter a nearfull/full transition soon, but
we won't increase the weights from the most underloaded(least utilized by contrast)
at the same time, which I think is not quite reasonable.

Actually, the best thing would probably be to iterate over teh low and high osds
in parallel, and do the ones that are furthest from the average first.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
(cherry picked from commit e7a32534ebc9e27f955ff2d7a8d1db511383301e)

9 years agomon/OSDMonitor: avoid potential expensive grace calculation
xie xingguo [Mon, 25 Apr 2016 07:43:03 +0000 (15:43 +0800)]
mon/OSDMonitor: avoid potential expensive grace calculation

The grace calculation during check_failure() is now very complicated
and time-consuming. Therefore we shall skip this when it is possible.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
(cherry picked from commit 3557903d5d57642179b2ae137bedc389974b1956)

9 years agomon/OSDMonitor: max_osds must be > 0 for reweight-by-*
Sage Weil [Sat, 30 Apr 2016 02:01:56 +0000 (22:01 -0400)]
mon/OSDMonitor: max_osds must be > 0 for reweight-by-*

Include a few test cases.

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 84bd0dce18f6dd0c35d7e6cfee91ce8c5a0f4db7)

9 years agoMerge pull request #8787 from xiaoxichen/wip-15631
John Spray [Tue, 3 May 2016 13:05:23 +0000 (08:05 -0500)]
Merge pull request #8787 from xiaoxichen/wip-15631

jewel: CephFSVolumeClient should isolate volumes by RADOS namespace

Reviewed-by: John Spray <john.spray@redhat.com>
9 years agoOSDMonitor: avoid underflow in reweight-by-utilization if max_change=1 9006/head
Samuel Just [Thu, 28 Apr 2016 20:47:48 +0000 (13:47 -0700)]
OSDMonitor: avoid underflow in reweight-by-utilization if max_change=1

Fixes: http://tracker.ceph.com/issues/15655
Signed-off-by: Samuel Just <sjust@redhat.com>
(cherry picked from commit c121bc51a5a877a49094cfbd3bd16af1f3ae5090)

9 years agorbd: disk usage now includes all snapshots by default 8870/head
Jason Dillaman [Thu, 28 Apr 2016 19:53:59 +0000 (15:53 -0400)]
rbd: disk usage now includes all snapshots by default

Added a new "--from-snap" optional to restrict the calculation to
specific subsets of snapshots and the HEAD revision.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 1ccdcb5b6c1cfd176a86df4f115a88accc81b4d0)

9 years agolibrbd: block RPC requests while updating features 8869/head
Jason Dillaman [Thu, 28 Apr 2016 16:48:59 +0000 (12:48 -0400)]
librbd: block RPC requests while updating features

Disabling the journal and object map require acquiring the exclusive
lock locally.  We don't want to start executing long-running ops
for this quick process.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit db7aaff0f6d7a57e2b36d22b609f915f9b2b3893)

9 years agolibrbd: return -ESHUTDOWN when a refresh is requested on a closed image
Jason Dillaman [Thu, 28 Apr 2016 16:43:24 +0000 (12:43 -0400)]
librbd: return -ESHUTDOWN when a refresh is requested on a closed image

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit ed132a1eb10e6b2eb4bc465658eb0379daca3d67)

9 years agolibrbd: synchronous block_writes should return possible error result
Jason Dillaman [Thu, 28 Apr 2016 16:42:49 +0000 (12:42 -0400)]
librbd: synchronous block_writes should return possible error result

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 88e76cb3c9a74b4718ad39c827f2194666f5be2a)

9 years agolibrbd: refresh image before executing maint op
Jason Dillaman [Thu, 28 Apr 2016 15:46:20 +0000 (11:46 -0400)]
librbd: refresh image before executing maint op

If a maint op is interrupted and restarted, it's possible that the
image will need to be refreshed.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 9cf6821bd9f58c181720a5c8156cec5ab33d35d4)

9 years agolibrbd: reduce log level when lock owner not detected
Jason Dillaman [Thu, 28 Apr 2016 15:10:25 +0000 (11:10 -0400)]
librbd: reduce log level when lock owner not detected

This can happen under normal operating conditions and the
lock request is automatically retried.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 5a4893b7a7e50cc399696e1d0cb4d4f8785e723d)

9 years agolibrbd: reduce log level for interrupted maint ops
Jason Dillaman [Thu, 28 Apr 2016 14:52:15 +0000 (10:52 -0400)]
librbd: reduce log level for interrupted maint ops

Fixes: http://tracker.ceph.com/issues/15572
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 1617328402345c68bf5d54828da6d687e51ef42b)

9 years agoqa/workunits/rbd: test mirror status in pool directory 8868/head
Mykola Golub [Sun, 24 Apr 2016 16:39:40 +0000 (19:39 +0300)]
qa/workunits/rbd: test mirror status in pool directory

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
(cherry picked from commit f15cd51a1ddbd4079a8218bc2446a4bf68f95107)