]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
10 years ago0.94.1.3 v0.94.1.3
Jenkins [Thu, 25 Jun 2015 19:58:55 +0000 (12:58 -0700)]
0.94.1.3

10 years agorgw: fix assignment of copy obj attributes
Yehuda Sadeh [Wed, 17 Jun 2015 18:35:18 +0000 (11:35 -0700)]
rgw: fix assignment of copy obj attributes

Fixes: #11563
Clarify the confusing usage of set_copy_attrs() by switching the source and
destinatiion params (attrs, src_attrs). Switch to use attrs instead of
src_attrs afterwards. In one of the cases we originally used the wrong
variable.

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

10 years agorgw: improve metadata handling on copy operation of Swift API.
Radoslaw Zarzynski [Sat, 21 Mar 2015 14:53:08 +0000 (15:53 +0100)]
rgw: improve metadata handling on copy operation of Swift API.

Fixes: #10645
Backport: hammer
Signed-off-by: Radoslaw Zarzynski <rzarzynski@mirantis.com>
(cherry picked from commit a00cb31cc52e91bfacdd15e0af60be74e66c1996)
(cherry picked from commit efbfe6fced72d07309ccf1f1a219c037b7f535fa)

10 years agorgw: improve code formatting ONLY.
Radoslaw Zarzynski [Tue, 7 Apr 2015 12:09:57 +0000 (14:09 +0200)]
rgw: improve code formatting ONLY.

Signed-off-by: Radoslaw Zarzynski <rzarzynski@mirantis.com>
(cherry picked from commit 214c8b32b1b04885005e929a7ed2d4354b3ea20b)
(cherry picked from commit bc6eb8d5f0a66aec3fbda0b794d008a3157a8154)

10 years agorgw: Swift API. Allows setting attributes with COPY object operation.
Dmytro Iurchenko [Fri, 20 Feb 2015 16:31:03 +0000 (18:31 +0200)]
rgw: Swift API. Allows setting attributes with COPY object operation.

http://developer.openstack.org/api-ref-objectstorage-v1.html says: "With COPY, you can add additional metadata to the object."

Fixes: #10662
Backport: hammer
Reported-by: Ahmad Faheem <ahmad.faheem@ril.com>
Signed-off-by: Dmytro Iurchenko <diurchenko@mirantis.com>
(cherry picked from commit 1b722bbcd691e0a4a39ea77cd28e309fd723ec88)

10 years agorgw: civetweb should use unique request id
Orit Wasserman [Thu, 23 Apr 2015 15:36:47 +0000 (17:36 +0200)]
rgw: civetweb should use unique request id

max_req_id was moved to RGWRados and changed to atomic64_t.

The same request id resulted in gc giving the same idtag to all objects
resulting in a leakage of rados objects. It only kept the last deleted object in
it's queue, the previous objects were never freed.

Fixes: 10295
Backport: Hammer, Firefly

Signed-off-by: Orit Wasserman <owasserm@redhat.com>
(cherry picked from commit c26225980c2fd018e70033a453d635533fcdefec)

10 years agorgw: use correct oid when creating gc chains
Yehuda Sadeh [Thu, 23 Apr 2015 22:33:03 +0000 (15:33 -0700)]
rgw: use correct oid when creating gc chains

Fixes: #11447
Backport: hammer

When creating gc chain, use the appropriate oid, otherwise objects will
leak.

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

10 years agorgw: fix reset_loc()
Yehuda Sadeh [Wed, 17 Jun 2015 22:11:28 +0000 (15:11 -0700)]
rgw: fix reset_loc()

Fixes: #11974
Only need to set locator for underscore if namespace is empty

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

10 years agotests: verify librbd blocking aio code path
Jason Dillaman [Tue, 2 Jun 2015 14:33:35 +0000 (10:33 -0400)]
tests: verify librbd blocking aio code path

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

10 years agolibrbd: new rbd_non_blocking_aio config option
Jason Dillaman [Tue, 2 Jun 2015 02:56:11 +0000 (22:56 -0400)]
librbd: new rbd_non_blocking_aio config option

Setting this option to false reverts librbd to legacy behavior
where AIO operations could potentially block.

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

10 years agolibrbd: AioRequest::send no longer returns a result
Jason Dillaman [Thu, 9 Apr 2015 17:33:09 +0000 (13:33 -0400)]
librbd: AioRequest::send no longer returns a result

The librados calls used by AioRequest::send should always return
zero unless there is a bug.

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

10 years agotests: update librbd AIO tests to remove result code
Jason Dillaman [Thu, 9 Apr 2015 01:55:36 +0000 (21:55 -0400)]
tests: update librbd AIO tests to remove result code

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

10 years agoThrottle: added pending_error method to SimpleThrottle
Jason Dillaman [Thu, 9 Apr 2015 01:48:21 +0000 (21:48 -0400)]
Throttle: added pending_error method to SimpleThrottle

Allow the client of SimpleThrottle to detect an async error
so that it can exit early.

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

10 years agolibrbd: internal AIO methods no longer return result
Jason Dillaman [Thu, 9 Apr 2015 01:37:50 +0000 (21:37 -0400)]
librbd: internal AIO methods no longer return result

All failures should be returned via the AioCompletion.

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

10 years agolibrbd: add new fail method to AioCompletion
Jason Dillaman [Thu, 9 Apr 2015 00:18:50 +0000 (20:18 -0400)]
librbd: add new fail method to AioCompletion

Helper method to handle passing fatal errors generated within
librbd (not from the OSDs) back to the client.

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

10 years agolibrbd: avoid blocking AIO API methods
Jason Dillaman [Wed, 8 Apr 2015 23:06:52 +0000 (19:06 -0400)]
librbd: avoid blocking AIO API methods

Enqueue all AIO API methods within the new librbd thread pool to
reduce the possibility of any blocking operations. To maintain
backwards compatibility with the legacy return codes of the API's
AIO methods, it's still possible to block attempting to acquire
the snap_lock.

Fixes: #11056
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 3a7b5e30efdb21aa1a0aeb68a5d02a1ac2a5faf3)
(cherry picked from commit cf6e1f50ea7b5c2fd6298be77c06ed4765d66611)

10 years agolibrbd: add task pool / work queue for requests
Jason Dillaman [Wed, 8 Apr 2015 21:24:08 +0000 (17:24 -0400)]
librbd: add task pool / work queue for requests

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

10 years agoWorkQueue: added virtual destructor
Jason Dillaman [Mon, 11 May 2015 21:05:49 +0000 (17:05 -0400)]
WorkQueue: added virtual destructor

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

10 years agoWorkQueue: add new ContextWQ work queue
Jason Dillaman [Wed, 8 Apr 2015 20:46:34 +0000 (16:46 -0400)]
WorkQueue: add new ContextWQ work queue

The queue holds a collection of Context pointers that will
be completed by the thread pool.

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

10 years agopackaging: include ceph_perf_objectstore
Ken Dreyer [Fri, 13 Mar 2015 22:08:35 +0000 (16:08 -0600)]
packaging: include ceph_perf_objectstore

The /usr/bin/ceph_perf_objectstore file is installed by default. Prior
to this commit it was missing from the packaging. This caused the RPM to
fail to build in mock.

Add ceph_perf_objectstore to the "ceph-test" RPM and Debian package.

If we end up developing further ceph_perf_* utilities, it would make
sense to glob them all with a wildcard, similar to what we are doing
with all the ceph_test_* utilities in ceph-test.

Signed-off-by: Ken Dreyer <kdreyer@redhat.com>
(cherry picked from commit 338b44bc74bc4597939c5c58f2a6f2cb08de7d9c)
(cherry picked from commit 95818dac1522c218662ec12bd42c470d8394b3b9)

10 years ago0.94.1.2 v0.94.1.2
Jenkins [Wed, 27 May 2015 23:44:15 +0000 (16:44 -0700)]
0.94.1.2

10 years agoinit-radosgw.sysv: remove
Sage Weil [Thu, 7 May 2015 22:40:05 +0000 (15:40 -0700)]
init-radosgw.sysv: remove

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

10 years agoinit-radosgw: unify init-radosgw[.sysv]
Sage Weil [Thu, 7 May 2015 22:39:22 +0000 (15:39 -0700)]
init-radosgw: unify init-radosgw[.sysv]

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

10 years agoinit-radosgw: look in /var/lib/ceph/radosgw
Sage Weil [Thu, 7 May 2015 22:29:11 +0000 (15:29 -0700)]
init-radosgw: look in /var/lib/ceph/radosgw

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

10 years agorgw: merge manifests correctly when there's prefix override
Yehuda Sadeh [Thu, 14 May 2015 00:05:22 +0000 (17:05 -0700)]
rgw: merge manifests correctly when there's prefix override

Fixes: #11622
Backport: hammer, firefly

Prefix override happens in a manifest when a rados object does not
conform to the generic prefix set on the manifest. When merging
manifests (specifically being used in multipart objects upload), we need
to check if the rule that we try to merge has a prefix that is the same
as the previous rule. Beforehand we checked if both had the same
override_prefix setting, but that might not apply as both manifests
might have different prefixes.

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

10 years agorgw: restore buffer of multipart upload after EEXIST
Yehuda Sadeh [Tue, 12 May 2015 23:40:10 +0000 (16:40 -0700)]
rgw: restore buffer of multipart upload after EEXIST

Fixes #11604
Backport: hammer, firefly

When we need to restart a write of part data, we need to revert to
buffer to before the write, otherwise we're going to skip some data.

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

10 years agocommon/admin_socket: close socket descriptor in destructor
Jon Bernard [Fri, 8 May 2015 15:54:06 +0000 (11:54 -0400)]
common/admin_socket: close socket descriptor in destructor

Long-running processes that do not reuse a single client connection will
see accumulating file descriptors as a result of not closing the
listening socket.  In this case, eventually the system will reach
file-max and subsequent connections will fail.

Fixes: #11535
Signed-off-by: Jon Bernard <jbernard@tuxion.com>
(cherry picked from commit 88fabb1ee6cd3c7d211ca46919055195e32245db)

10 years agoOSD: handle the case where we resurrected an old, deleted pg
Samuel Just [Tue, 21 Apr 2015 06:45:57 +0000 (23:45 -0700)]
OSD: handle the case where we resurrected an old, deleted pg

Prior to giant, we would skip pgs in load_pgs which were not present in
the current osdmap.  Those pgs would eventually refer to very old
osdmaps, which we no longer have causing the assertion failure in 11429
once the osd is finally upgraded to a version which does not skip the
pgs.  Instead, if we do not have the map for the pg epoch, complain to
the osd log and skip the pg.

Fixes: 11429
Signed-off-by: Samuel Just <sjust@redhat.com>
(cherry picked from commit fbfd50de5b9b40d71d2e768418a8eca28b1afaca)

10 years agorgw: set a special object locator if object starts with underscore
Yehuda Sadeh [Wed, 22 Apr 2015 00:31:41 +0000 (17:31 -0700)]
rgw: set a special object locator if object starts with underscore

Fixes: #11442
Backport: hammer

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

10 years agorgw-admin: a tool to fix object locator issue
Yehuda Sadeh [Wed, 22 Apr 2015 22:39:05 +0000 (15:39 -0700)]
rgw-admin: a tool to fix object locator issue

Objects that start with underscore need to have an object locator,
this is due to an old behavior that we need to retain. Some objects
might have been created without the locator. This tool creates a new
rados object with the appropriate locator.

Syntax:

$ ./radosgw-admin bucket check --check-head-obj-locator \
                               --bucket=<bucket> [--fix]

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

10 years agorgw: don't use rgw_socket_path if frontend is configured
Yehuda Sadeh [Thu, 19 Mar 2015 03:49:13 +0000 (20:49 -0700)]
rgw: don't use rgw_socket_path if frontend is configured

Fixes: #11160
Backport: hammer, firefly

Previously if we wanted to use the tcp fcgi socket, we needed to clear
rgw_socket_path.

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

10 years agocls_rgw: use multimap to keep pending operations in bucket index
Yehuda Sadeh [Tue, 31 Mar 2015 00:34:57 +0000 (17:34 -0700)]
cls_rgw: use multimap to keep pending operations in bucket index

Fixes: #11256
Multiple concurrent requests might be sent using the same tag, need the
entry map to be able to hold multiple entries.

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

10 years agoceph_json: add decode / encoder for multimap
Yehuda Sadeh [Mon, 13 Apr 2015 23:33:17 +0000 (16:33 -0700)]
ceph_json: add decode / encoder for multimap

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

10 years agorgw: generate new tag for object when setting object attrs
Yehuda Sadeh [Fri, 27 Mar 2015 23:32:48 +0000 (16:32 -0700)]
rgw: generate new tag for object when setting object attrs

Fixes: #11256
Backport: firefly, hammer

Beforehand we were reusing the object's tag, which is problematic as
this tag is used for bucket index updates, and we might be clobbering a
racing update (like object removal).

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

10 years agorgw: update keystone cache with token info
Yehuda Sadeh [Tue, 3 Mar 2015 19:03:35 +0000 (11:03 -0800)]
rgw: update keystone cache with token info

Fixes: #11125
Backport: hammer, firefly

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

10 years agocivetweb: update max num of threads
Yehuda Sadeh [Tue, 21 Apr 2015 18:08:45 +0000 (11:08 -0700)]
civetweb: update max num of threads

Fixes: #10243
cherry-picked upstream fixed into submodule

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

10 years agorgw: send X-Copied-From-Last-Modified header of Swift API.
Radoslaw Zarzynski [Tue, 17 Mar 2015 13:07:34 +0000 (14:07 +0100)]
rgw: send X-Copied-From-Last-Modified header of Swift API.

Fixes: #10663
Backport: hammer
Signed-off-by: Radoslaw Zarzynski <rzarzynski@mirantis.com>
(cherry picked from commit e7724a1d8c0872362c19f578fe30ac2cf3dada90)

Conflicts:
src/rgw/rgw_rados.cc

10 years agorgw: dump object metadata in response for COPY request of Swift API.
Radoslaw Zarzynski [Tue, 17 Mar 2015 13:06:37 +0000 (14:06 +0100)]
rgw: dump object metadata in response for COPY request of Swift API.

Fixes: #10663
Backport: hammer
Signed-off-by: Radoslaw Zarzynski <rzarzynski@mirantis.com>
(cherry picked from commit c52b75edeaeef19471b9aca772bf08055bf04031)

10 years agorgw: refactor dumping metadata of Swift objects.
Radoslaw Zarzynski [Fri, 13 Mar 2015 16:59:01 +0000 (17:59 +0100)]
rgw: refactor dumping metadata of Swift objects.

Backport: hammer
Signed-off-by: Radoslaw Zarzynski <rzarzynski@mirantis.com>
(cherry picked from commit ccf6eaac6f7068289c4a4ffd3f0481d497ba7c87)

10 years agorgw: add support for X-Copied-From{-Account} headers of Swift API.
Radoslaw Zarzynski [Fri, 13 Mar 2015 17:37:39 +0000 (18:37 +0100)]
rgw: add support for X-Copied-From{-Account} headers of Swift API.

Fixes: #10663
Backport: hammer
Signed-off-by: Radoslaw Zarzynski <rzarzynski@mirantis.com>
(cherry picked from commit 94f1375ccb9df02cdd8f6828153ae2e3a7ad36b1)

10 years agorgw: send ETag, Last-Modified in response for copying Swift cobject.
Radoslaw Zarzynski [Wed, 11 Mar 2015 13:08:03 +0000 (14:08 +0100)]
rgw: send ETag, Last-Modified in response for copying Swift cobject.

Fixes: #11087
Backport: hammer
Signed-off-by: Radoslaw Zarzynski <rzarzynski@mirantis.com>
(cherry picked from commit 385fe4b4bbbd4a9aab92abf2a813090deeaa037e)

10 years agoinit-radosgw: run RGW as root
Ken Dreyer [Wed, 22 Apr 2015 22:36:42 +0000 (16:36 -0600)]
init-radosgw: run RGW as root

The ceph-radosgw service fails to start if the httpd package is not
installed. This is because the init.d file attempts to start the RGW
process with the "apache" UID. If a user is running civetweb, there is
no reason for the httpd or apache2 package to be present on the system.

Switch the init scripts to use "root" as is done on Ubuntu.

http://tracker.ceph.com/issues/11453 Refs: #11453

Reported-by: Vickey Singh <vickey.singh22693@gmail.com>
Signed-off-by: Ken Dreyer <kdreyer@redhat.com>
(cherry picked from commit 47339c5ac352d305e68a58f3d744c3ce0fd3a2ac)

10 years agorgw: remove meta file after deleting bucket
Orit Wasserman [Fri, 3 Apr 2015 11:43:31 +0000 (13:43 +0200)]
rgw: remove meta file after deleting bucket
The meta file is deleted only if the bucket meta data is not synced

Signed-off-by: Orit Wasserman <owasserm@redhat.com>
Fixes: #11149
Backport: hammer, firefly
(cherry picked from commit dfdc7afb59cc8e32cf8bff55faa09076c853de06)

10 years agoMove ceph-dencoder build to client
Boris Ranto [Mon, 13 Apr 2015 10:38:58 +0000 (12:38 +0200)]
Move ceph-dencoder build to client

The patch simply moves the ceph-dencoder build from server part of the
Makefiles to client part of the Makefiles.

Signed-off-by: Boris Ranto <branto@redhat.com>
10 years agoRework mds/Makefile.am to support a dencoder client build
Boris Ranto [Mon, 13 Apr 2015 10:36:07 +0000 (12:36 +0200)]
Rework mds/Makefile.am to support a dencoder client build

The patch adds all the mds sources to DENCODER_SOURCES to allow a
dencoder client build. The patch also splits the Makefile.am file to
better accomodate the change.

Signed-off-by: Boris Ranto <branto@redhat.com>
10 years agorgw/Makefile.am: Populate DENCODER_SOURCES properly
Boris Ranto [Mon, 13 Apr 2015 10:33:00 +0000 (12:33 +0200)]
rgw/Makefile.am: Populate DENCODER_SOURCES properly

Dencoder is built if ENABLE_CLIENT is set. However, the rgw/Makefile.am
populated DENCODER_SOURCES only if WITH_RADOSGW was set. The patch fixes
this and populates DENCODER_SOURES if ENABLE_CLIENT is set.

Signed-off-by: Boris Ranto <branto@redhat.com>
10 years agoDencoder should never be built with tcmalloc
Boris Ranto [Mon, 13 Apr 2015 10:32:30 +0000 (12:32 +0200)]
Dencoder should never be built with tcmalloc

The patch adds disabled perfglue stubs to DENCODER sources in order to
avoid tcmalloc-enabled ceph-dencoder builds.

Signed-off-by: Boris Ranto <branto@redhat.com>
10 years ago0.94.1 v0.94.1
Jenkins [Fri, 10 Apr 2015 19:04:50 +0000 (12:04 -0700)]
0.94.1

10 years agoMerge pull request #4328 from dachary/wip-11364-hammer
Loic Dachary [Fri, 10 Apr 2015 15:51:38 +0000 (17:51 +0200)]
Merge pull request #4328 from dachary/wip-11364-hammer

v4 bucket feature detection

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agocrush: fix has_v4_buckets() 4328/head
Sage Weil [Fri, 10 Apr 2015 15:43:45 +0000 (08:43 -0700)]
crush: fix has_v4_buckets()

alg, not type!

This bug made us incorrectly think we were using v4 features when user type
5 was being used.  That's currently 'rack' with recent crush maps, but
was other types for clusters that were created with older versions.  This
is clearly problematic as it will lock out non-hammer clients incorrectly,
breaking deployments on upgrade.

Fixes: #11364
Backport: hammer
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 38b35ab9d17eb84ac178c4cd3ebcf2ec0f66d8b6)

10 years agocrush: fix dump of has_v4_buckets
Sage Weil [Fri, 10 Apr 2015 00:17:59 +0000 (17:17 -0700)]
crush: fix dump of has_v4_buckets

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

10 years agocrush/mapper: fix divide-by-0 in straw2
Sage Weil [Thu, 9 Apr 2015 21:42:34 +0000 (14:42 -0700)]
crush/mapper: fix divide-by-0 in straw2

If the item weight is 0 we don't want to divide; instead draw a minimal
value.

Fixes: #11357
Reported-by: Yann Dupont <yd@objoo.org>
Tested-by: Yann Dupont <yd@objoo.org>
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 64d1e900ec4f5831972ec80e8d0129604669f5bb)

10 years agoosd: fix negative degraded objects during backfilling
Guang Yang [Thu, 26 Feb 2015 08:13:12 +0000 (08:13 +0000)]
osd: fix negative degraded objects during backfilling

When there is deleting requests during backfilling, the reported number of degraded
objects could be negative, as the primary's num_objects is the latest (locally) but
the number for replicas might not reflect the deletings. A simple fix is to ignore
the negative subtracted value.

Signed-off-by: Guang Yang <yguang@yahoo-inc.com>
(cherry picked from commit 14d7e36d3c978844da73d0e1c8a3a1ec863bac15)

10 years ago0.94 v0.94
Jenkins [Tue, 7 Apr 2015 17:05:41 +0000 (10:05 -0700)]
0.94

10 years agodebian: remove lttng checking from rules
Josh Durgin [Mon, 6 Apr 2015 18:08:33 +0000 (11:08 -0700)]
debian: remove lttng checking from rules

This can be done better in a separate script, which puts these in
CEPH_EXTRA_CONFIGURE_ARGS. In particular, this lets us enable
lttng for gitbuilder builds, but not release builds.

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

10 years agoMerge pull request #4246 from ceph/wip-11113-hammer
Sage Weil [Mon, 6 Apr 2015 15:55:51 +0000 (08:55 -0700)]
Merge pull request #4246 from ceph/wip-11113-hammer

librbd: snap_remove should ignore -ENOENT errors

10 years agoMerge pull request #4250 from athanatos/wip-11265
Sage Weil [Mon, 6 Apr 2015 15:07:28 +0000 (08:07 -0700)]
Merge pull request #4250 from athanatos/wip-11265

ECTransaction: write out the hinfo key on touch as well

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4251 from athanatos/wip-11284
Sage Weil [Mon, 6 Apr 2015 15:07:15 +0000 (08:07 -0700)]
Merge pull request #4251 from athanatos/wip-11284

ReplicatedPG::promote_object: do not create obc if not promoting

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4167 from dzafman/wip-11184
Samuel Just [Thu, 2 Apr 2015 04:03:37 +0000 (21:03 -0700)]
Merge pull request #4167 from dzafman/wip-11184

Fix 11184 by filtering the log

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agolibrbd: snap_remove should ignore -ENOENT errors 4246/head
Jason Dillaman [Mon, 16 Mar 2015 22:40:49 +0000 (18:40 -0400)]
librbd: snap_remove should ignore -ENOENT errors

If the attempt to deregister the snapshot from the parent
image fails with -ENOENT, ignore the error as it is safe
to assume that the child is not associated with the parent.

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

10 years agolibrbd: get_parent_info should protect against invalid parent
Jason Dillaman [Mon, 16 Mar 2015 22:35:07 +0000 (18:35 -0400)]
librbd: get_parent_info should protect against invalid parent

get_parent_info should return -ENOENT if the image does not
have an associated parent image.

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

10 years agoMerge pull request #4230 from athanatos/wip-11244
Samuel Just [Tue, 31 Mar 2015 16:47:10 +0000 (09:47 -0700)]
Merge pull request #4230 from athanatos/wip-11244

ReplicatedPG::cancel_pull: requeue waiters as well

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4219 from liewegas/wip-scrub-mtime
Samuel Just [Tue, 31 Mar 2015 16:45:46 +0000 (09:45 -0700)]
Merge pull request #4219 from liewegas/wip-scrub-mtime

osd: do not update mtime when recording digest

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #4229 from athanatos/wip-scrub-hitsets
Sage Weil [Tue, 31 Mar 2015 16:39:32 +0000 (09:39 -0700)]
Merge pull request #4229 from athanatos/wip-scrub-hitsets

ReplicatedPG: don't write hitset while scrubbing, update scrub_cstat

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4228 from athanatos/wip-11280
Sage Weil [Tue, 31 Mar 2015 16:38:48 +0000 (09:38 -0700)]
Merge pull request #4228 from athanatos/wip-11280

Wip 11280

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4207 from ceph/wip-11177
Samuel Just [Tue, 31 Mar 2015 16:26:56 +0000 (09:26 -0700)]
Merge pull request #4207 from ceph/wip-11177

common: fix logging default channel to be 'cluster' not 'default' (11177)

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoReplicatedPG::cancel_pull: requeue waiters as well 4230/head
Samuel Just [Thu, 26 Mar 2015 17:26:48 +0000 (10:26 -0700)]
ReplicatedPG::cancel_pull: requeue waiters as well

If we are in recovery_wait, we might not recover that object as part of
recover_primary for some time.  Worse, if we are waiting on a backfill
which is blocked waiting on a copy_from on the missing object in
question, it can become a dead lock.

Fixes: 11244
Backport: firefly
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoReplicatedPG: don't write hitset while scrubbing, update scrub_cstat 4229/head
Samuel Just [Sun, 29 Mar 2015 22:30:52 +0000 (15:30 -0700)]
ReplicatedPG: don't write hitset while scrubbing, update scrub_cstat

Fixes: 11263
Fixes: 11262
Backport: firefly
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoReplicatedPG: in do_op, requeue op if we requeue waiters in agent_choose_mode 4228/head
Samuel Just [Mon, 30 Mar 2015 21:04:29 +0000 (14:04 -0700)]
ReplicatedPG: in do_op, requeue op if we requeue waiters in agent_choose_mode

The current op might be ordered after a waiter.

Fixes: 11280
Backport: firefly
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoReplicatedPG: requeue waiting_for_active before waiting_for_cache_not_full
Samuel Just [Mon, 30 Mar 2015 20:22:26 +0000 (13:22 -0700)]
ReplicatedPG: requeue waiting_for_active before waiting_for_cache_not_full

The waiting_for_cache_not_full waiters must be dequeued first.

Fixes: 11267
Backport: firefly
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoReplicatedPG::promote_object: do not create obc if not promoting 4251/head
Samuel Just [Tue, 31 Mar 2015 15:41:09 +0000 (08:41 -0700)]
ReplicatedPG::promote_object: do not create obc if not promoting

Otherwise, we can leave an incorrect cached obc around.

Introduced: 65bb4df599541cd2e0f195b905f24f529e255c00
Fixes: 11284
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoECTransaction: write out the hinfo key on touch as well 4250/head
Samuel Just [Sun, 29 Mar 2015 22:46:59 +0000 (15:46 -0700)]
ECTransaction: write out the hinfo key on touch as well

This way, even empty objects have the hinfo key written.  That way,
touch and touch->append->truncate end up with the same state.

Fixes: 11265
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoosd: drop unused utime_t now arg to issue_repop 4219/head
Sage Weil [Mon, 30 Mar 2015 14:13:43 +0000 (07:13 -0700)]
osd: drop unused utime_t now arg to issue_repop

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoosd: do not update mtime when recording digest
Jianpeng Ma [Mon, 30 Mar 2015 14:17:40 +0000 (07:17 -0700)]
osd: do not update mtime when recording digest

The user mtime and local_mtime are normally set in finish_ctx based on the
value of ctx->mtime; clear that to avoid this update.

Signed-off-by: Jianpeng Ma <jianpeng.ma@intel.com>
[Sage: simplified]
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4131 from t-miyamae/wip-mshec-documentation-h2
Loic Dachary [Mon, 30 Mar 2015 12:37:08 +0000 (14:37 +0200)]
Merge pull request #4131 from t-miyamae/wip-mshec-documentation-h2

erasure code: add shec's documentation / change default layout

Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agotest: Add testing for PGLog::filter_log() 4167/head
David Zafman [Fri, 27 Mar 2015 05:32:25 +0000 (22:32 -0700)]
test: Add testing for PGLog::filter_log()

Indirectly tests pg_log_t::filter_log()

Signed-off-by: David Zafman <dzafman@redhat.com>
10 years agoosd: Create a filter_log for PGLog
David Zafman [Thu, 26 Mar 2015 22:49:16 +0000 (15:49 -0700)]
osd: Create a filter_log for PGLog

This could be tested as a way to test pg_log_t::filter_log()

Signed-off-by: David Zafman <dzafman@redhat.com>
10 years agoceph-objectstore-tool, osd: Filter the pg_log_t for objects no longer in pg
David Zafman [Thu, 26 Mar 2015 22:53:42 +0000 (15:53 -0700)]
ceph-objectstore-tool, osd: Filter the pg_log_t for objects no longer in pg

Fixes: #11184
Signed-off-by: David Zafman <dzafman@redhat.com>
10 years agocommon: send cluster log messages to 'cluster' channel by default 4207/head
Sage Weil [Fri, 27 Mar 2015 22:35:21 +0000 (15:35 -0700)]
common: send cluster log messages to 'cluster' channel by default

The CLOG_CHANNEL_DEFAULT constant was being abused for two purposes:

 - the default channel to log messages to
 - the name of the config option key in the key/value pair string that is
   used for the default option, e.g. "default=true foo=false bar=false"

Fix this by making the config option key CLOG_CONFIG_DEFAULT_KEY and
replacing throughout, and changing CLOG_CHANNEL_DEFAULT to "cluster" (as
it should be and has been historically).

Fixes: #11177
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4194 from athanatos/wip-11199
Sage Weil [Fri, 27 Mar 2015 15:15:29 +0000 (08:15 -0700)]
Merge pull request #4194 from athanatos/wip-11199

ReplicatedPG: trim backfill intervals based on peer's last_backfill_star...

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4195 from athanatos/wip-11197
Sage Weil [Fri, 27 Mar 2015 15:10:20 +0000 (08:10 -0700)]
Merge pull request #4195 from athanatos/wip-11197

PG: set/clear CREATING in Primary state entry/exit

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4196 from athanatos/wip-move-code
Kefu Chai [Fri, 27 Mar 2015 02:24:22 +0000 (10:24 +0800)]
Merge pull request #4196 from athanatos/wip-move-code

osd: Wip move code

Reviewed-by: Kefu Chai <kchai@redhat.com>
10 years agoceph-objectstore-tool: Fix message and make it debug only to stderr
David Zafman [Tue, 24 Mar 2015 22:12:31 +0000 (15:12 -0700)]
ceph-objectstore-tool: Fix message and make it debug only to stderr

Signed-off-by: David Zafman <dzafman@redhat.com>
10 years agoceph-objectstore-tool: Remove bogus comment and eliminate a debug message
David Zafman [Thu, 26 Mar 2015 22:54:48 +0000 (15:54 -0700)]
ceph-objectstore-tool: Remove bogus comment and eliminate a debug message

Signed-off-by: David Zafman <dzafman@redhat.com>
10 years agoosd/: Move ReplicatedBackend methods into ReplicatedBackend.cc 4196/head
Samuel Just [Thu, 26 Mar 2015 17:50:19 +0000 (10:50 -0700)]
osd/: Move ReplicatedBackend methods into ReplicatedBackend.cc

Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoReplicatedPG: remove unused C_OnPushCommit
Samuel Just [Thu, 26 Mar 2015 17:44:00 +0000 (10:44 -0700)]
ReplicatedPG: remove unused C_OnPushCommit

Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoPG: set/clear CREATING in Primary state entry/exit 4195/head
Samuel Just [Tue, 24 Mar 2015 17:48:02 +0000 (10:48 -0700)]
PG: set/clear CREATING in Primary state entry/exit

Previously, we did not actually set it when we got a pg creation message from
the mon.  It would actually get set on the first start_peering_interval after
that point.  If we don't get that far, but do send a stat update to the mon, we
can end up with 11197.  Instead, let's just set it and clear it upon entry into
and exit from the Primary state.

Fixes: 11197
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #4128 from dzafman/wip-11139-hammer
Samuel Just [Wed, 25 Mar 2015 15:29:31 +0000 (08:29 -0700)]
Merge pull request #4128 from dzafman/wip-11139-hammer

ceph-objectstore-tool: Use exit status 11 for incompatible import attemp...

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #4124 from ceph/wip-omap-clear
Samuel Just [Wed, 25 Mar 2015 15:27:59 +0000 (08:27 -0700)]
Merge pull request #4124 from ceph/wip-omap-clear

osd: fix omap_clear handling

Reviewed-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #4170 from ceph/hammer-11205
Gregory Farnum [Wed, 25 Mar 2015 04:35:29 +0000 (21:35 -0700)]
Merge pull request #4170 from ceph/hammer-11205

qa/workunits/fs/misc: fix filelock_interrupt.py

Reviewed-by: Greg Farnum <gfarnum@redhat.com>
10 years agoqa/workunits/fs/misc: fix filelock_interrupt.py 4170/head
Yan, Zheng [Mon, 2 Mar 2015 13:04:25 +0000 (21:04 +0800)]
qa/workunits/fs/misc: fix filelock_interrupt.py

Handle the case that kernel does not support fcntl.F_OFD_SETLK.
Also fix the code that checks if fnctl fails with errno == EINTR.

Fixes: 11205
Signed-off-by: Yan, Zheng <zyan@redhat.com>
(cherry picked from commit 4ececa3dc4a21b98f61a592da9e2be60a0d71625)

10 years agoReplicatedPG: trim backfill intervals based on peer's last_backfill_started 4194/head
Samuel Just [Tue, 24 Mar 2015 22:14:34 +0000 (15:14 -0700)]
ReplicatedPG: trim backfill intervals based on peer's last_backfill_started

Otherwise, we fail to trim the peer's last_backfill_started and get bug 11199.

1) osd 4 backfills up to 31bccdb2/mira01213209-286/head (henceforth: foo)

2) Interval change happens

3) osd 0 now finds itself backfilling to 4 (lb=foo) and osd.5
(lb=b6670ba2/mira01213209-160/snapdir//1, henceforth: bar)

4) recover_backfill causes both 4 and 5 to scan forward, so 4 has an interval
starting at foo, 5 has an interval starting at bar.

5) Once those have come back, recover_backfill attempts to trim off the
last_backfill_started, but 4's interval starts after that, so foo remains in
osd 4's interval (this is the bug)

7) We serve a copyfrom on foo (sent to 4 as well).

8) We eventually get to foo in the backfilling. Normally, they would have the
same version, but of course we don't update osd.4's interval from the log since
it should not have received writes in that interval. Thus, we end up trying to
recover foo on osd.4 anyway.

9) But, an interval change happens between removing foo from osd.4 and
completing the recovery, leaving osd.4 without foo, but with lb >= foo

Fixes: #11199
Backport: firefly
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #4162 from athanatos/wip-11156
Sage Weil [Tue, 24 Mar 2015 19:15:21 +0000 (12:15 -0700)]
Merge pull request #4162 from athanatos/wip-11156

ReplicatedPG::promote_object: check scrubber and block if necessary

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4163 from athanatos/wip-revert-degraded-writes
Samuel Just [Tue, 24 Mar 2015 16:31:13 +0000 (09:31 -0700)]
Merge pull request #4163 from athanatos/wip-revert-degraded-writes

Wip revert degraded writes

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #4152 from ceph/wip-11145
Sage Weil [Tue, 24 Mar 2015 01:11:08 +0000 (18:11 -0700)]
Merge pull request #4152 from ceph/wip-11145

rgw: shut down timer before erroring out

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agorgw: shut down timer before erroring out 4152/head
Yehuda Sadeh [Mon, 23 Mar 2015 23:21:14 +0000 (16:21 -0700)]
rgw: shut down timer before erroring out

Fixes: #11145
Backport: hammer

Clean up initialization timer, otherwise if we error out, we'll assert.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agoReplicatedPG::promote_object: check scrubber and block if necessary 4162/head
Samuel Just [Fri, 20 Mar 2015 22:28:15 +0000 (15:28 -0700)]
ReplicatedPG::promote_object: check scrubber and block if necessary

Otherwise, we might attempt to promote into an in-progress scrub
interval causing 11156.  I would have added a return value to
promote_object(), but could not find an existing user which
cared to distinguish the cases, even with a null op passed.
All existing users are in maybe_handle_cache.  The ones which
pass a null op are for promoting the object in parallel
with a proxy -- a case where not actually performing the promote
does not really matter.

Fixes: #11156
Signed-off-by: Samuel Just <sjust@redhat.com>
10 years agoMerge pull request #4125 from dzafman/wip-11176-hammer
Loic Dachary [Mon, 23 Mar 2015 19:37:14 +0000 (20:37 +0100)]
Merge pull request #4125 from dzafman/wip-11176-hammer

ceph-objectstore-tool: Output only unsupported features when incomatible

Reviewed-by: Loic Dachary <ldachary@redhat.com>
10 years agoMerge pull request #4145 from ceph/wip-hammer-rgw
Sage Weil [Mon, 23 Mar 2015 19:30:47 +0000 (12:30 -0700)]
Merge pull request #4145 from ceph/wip-hammer-rgw

Wip hammer rgw

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoosd/: s/is_degraded_object/is_degraded_or_backfilling_object 4163/head
Samuel Just [Tue, 17 Feb 2015 18:16:57 +0000 (10:16 -0800)]
osd/: s/is_degraded_object/is_degraded_or_backfilling_object

Currently, this method also returns true if the object is backfilling.
This commit was reverted earlier in the branch in order to make the
other reverts clean.  It's actually a nice rename though, so I'm
re-cherry-picking it.

Signed-off-by: Samuel Just <sjust@redhat.com>
Conflicts:
src/osd/ReplicatedPG.cc