Jason Dillaman [Fri, 21 Aug 2015 15:32:39 +0000 (11:32 -0400)]
Objecter: pg_interval_t::is_new_interval needs pgid from previous pool
When increasing the pg_num of a pool, an assert would fail since the
calculated pgid seed would be for the pool's new pg_num value instead
of the previous pg_num value.
Fixes: #10399
Backport: infernalis, hammer, firefly Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit f20f7a23e913d09cc7fc22fb3df07f9938ddc144)
Conflicts: (hobject_t sort order not backported, trivial resolution)
src/osdc/Objecter.cc
src/osdc/Objecter.h
Sage Weil [Tue, 4 Aug 2015 17:21:50 +0000 (13:21 -0400)]
mon: disallow post-hammer OSDs if there are up pre-hammer OSDs
Force *all* OSDs to upgrade to hammer before allowing post-hammer
OSDs to join. This prevents any pre-hammer OSDs from running at
the same time as a post-hammer OSD.
This commit, as well as the definition of the sentinal post-hammer
feature, should get backported to hammer stable series.
Sage Weil [Fri, 27 Mar 2015 17:03:22 +0000 (10:03 -0700)]
osd: fix fallback logic; move into be_select_auth_object
The fallback behavior was printing a promising message but then doing
a 'continue' and not actually scrubbing the object. Instead, fall back to
a less-bad auth inside be_select_auth_object.
Sage Weil [Thu, 26 Mar 2015 20:52:20 +0000 (13:52 -0700)]
osd: move recorded vs on disk digest warning into be_compare_scrubmaps
This is a better place for it. While we are here, change the wording to
clearly call out the 'recorded' digest (from object_info_t) vs the 'on
disk' digest (what we observed during scrub).
Sage Weil [Thu, 26 Mar 2015 20:44:25 +0000 (13:44 -0700)]
osd: be precise about "known" vs "best guess"
We cannot assume that the auth info has the "known" digest; all replicas
may have a matching digest that does not match the oi, or we may choose
a different auth info for some other reason. Verify that the digest
matches the oi before calling it "known".
Sage Weil [Thu, 26 Mar 2015 20:24:11 +0000 (13:24 -0700)]
osd: record digest if object is clean (vs entire scrub chunk)
If an individual object is clean, record it in the missing_digest map.
If not, leave it out. This lets us drop the old condition that only
recorded any digests if the entire scrub chunk was clean.
The post-hammer wip-temp branch changed hobject_t::get_min() so that pool
is INT64_MIN instead of -1 and neglected to deal with the encoding compat
with older versions. Compensate on hammer by mapping INT64_MIN to -1
locally. See commit ff99af38df830e215359bfb8837bf310a2023a4d.
Note that this means upgrades from hammer to post-hammer *must* include
this fix prior to the upgrade. This will need to be well-documented in the
release notes.
Master gets a similar fix so that they map our min value to the new
INT64_MIN one on decode.
Fixes: #12536 (for hammer) Signed-off-by: Sage Weil <sage@redhat.com>
debian/control: ceph-common (>> 0.94.2) must be >= 0.94.2-2
The d8733be2ef8874b9a858a7ffddfb81b9b656e9a6 backport introduced a
regression by adding an incorrect Depends / Break combo supposed to
reflect the fact that ceph_argparse moved from ceph to ceph-common after
v0.94.2. It assumed the package is released under the 0.94.2 version
where in reality it is released under the 0.94.2-1xxx version (where xxx
is trusty, jessie etc.).
The Depends / Break combo is changed to use 0.94.2-2 instead.
See also http://tracker.ceph.com/issues/12529 for a larger discussion.
Yehuda Sadeh [Fri, 26 Jun 2015 23:56:28 +0000 (16:56 -0700)]
rgw: conversion tool to fix broken multipart objects
Fixes: #12079
Broken multipart objects: multipart objects that created on 0.94.2
and that start with underscore have a bad locator on their tail objects.
This extends the tool that was needed for older issue we've had with
hammer multipart objects (that start with underscore). The same usage
applies:
mon: PaxosService: call post_refresh() instead of post_paxos_update()
Whenever the monitor finishes committing a proposal, we call
Monitor::refresh_from_paxos() to nudge the services to refresh. Once
all services have refreshed, we would then call each services
post_paxos_update().
However, due to an unfortunate, non-critical bug, some services (mainly
the LogMonitor) could have messages pending in their
'waiting_for_finished_proposal' callback queue [1], and we need to nudge
those callbacks.
This patch adds a new step during the refresh phase: instead of calling
directly the service's post_paxos_update(), we introduce a
PaxosService::post_refresh() which will call the services
post_paxos_update() function first and then nudge those callbacks when
appropriate.
[1] - Given the monitor will send MLog messages to itself, and given the
service is not readable before its initial state is proposed and
committed, some of the initial MLog's would be stuck waiting for the
proposal to finish. However, by design, we only nudge those message's
callbacks when an election finishes or, if the leader, when the proposal
finishes. On peons, however, we would only nudge those callbacks if an
election happened to be triggered, hence the need for an alternate path
to retry any message waiting for the initial proposal to finish.
Samuel Just [Fri, 24 Jul 2015 22:38:18 +0000 (15:38 -0700)]
Log::reopen_log_file: take m_flush_mutex
Otherwise, _flush() might continue to write to m_fd after it's closed.
This might cause log data to go to a data object if the filestore then
reuses the fd during that time.
Jason Dillaman [Tue, 23 Jun 2015 15:14:51 +0000 (11:14 -0400)]
librbd: only update image flags when holding exclusive lock
It was possible for a client to open an image while another client
was shrinking an image. This would result in the former invalidating
the object map on-disk if it openned the image between updating the
image header and resizing the object map.
Ken Dreyer [Tue, 14 Apr 2015 13:58:17 +0000 (07:58 -0600)]
debian: move ceph_argparse into ceph-common
Prior to this commit, if a user installed the "ceph-common" Debian
package without installing "ceph", then /usr/bin/ceph would crash
because it was missing the ceph_argparse library.
Ship the ceph_argparse library in "ceph-common" instead of "ceph". (This
was the intention of the original commit that moved argparse to "ceph", 2a23eac54957e596d99985bb9e187a668251a9ec)
http://tracker.ceph.com/issues/11388 Refs: #11388
Reported-by: Jens Rosenboom <j.rosenboom@x-ion.de> Signed-off-by: Ken Dreyer <kdreyer@redhat.com>
(cherry picked from commit 110608e5bdd9e2f03020ad41f0c2d756684d4417)
Conflicts:
debian/ceph.install
There is no ceph_daemon.py in hammer
debian/control
Depends/Replaces/Breaks version adapted (from 9.0.0 to 0.94.2)
also adapted ceph-dbg Replaces/Breaks
Zhiqiang Wang [Fri, 20 Mar 2015 08:15:42 +0000 (16:15 +0800)]
test: potential memory leak in FlushAioPP
Should call the release function instead of deleting it to free
librbd::RBD::AioCompletion and librbd::AioCompletion. Otherwise there is
a potential memory leak.
Jason Dillaman [Tue, 28 Apr 2015 14:56:15 +0000 (10:56 -0400)]
krbd: fix incorrect types in the krbd API
The C API functions were referencing the C++ CephContext
instead of the C rados_config_t. Additionally, the ceph
namespace was missing on the Formatter class.
Thorsten Behrens [Sun, 15 Mar 2015 23:13:38 +0000 (00:13 +0100)]
Conditional-compile against minimal tcmalloc.
Certain older systems (SLE11 in this case) do not provide the full
tcmalloc functionality, due to e.g. incomplete libunwind
pieces. Use --with-tcmalloc-minimal to enable the cut-down
version.
Here's how the various mem allocator switches interact now:
--with-jemalloc: overrides --with-tcmalloc & --with-tcmalloc-minimal
--with-tcmalloc-minimal: overrides --with-tcmalloc
--with-tcmalloc: the default. use --without-tcmalloc to disable