1- in reality we don't really care if pg_temp is set.
2- compare against acting_primary since that's what actually matters.
Signed-off-by: Sage Weil <sage@redhat.com>
The following error appears during make:
In file included from ceph/src/dmclock/support/src/run_every.cc:10:0:
ceph/src/dmclock/support/src/run_every.h:30:10: error: ‘function’ in namespace ‘std’ does not name a template type
std::function<void()> body;
^~~~~~~~
ceph/src/dmclock/support/src/run_every.h:46:12: error: ‘std::function’ has not been declared
std::function<void()> _body) :
^~~~~~~~
ceph/src/dmclock/support/src/run_every.h:46:20: error: expected ‘,’ or ‘...’ before ‘<’ token
std::function<void()> _body) :
^
ceph/src/dmclock/support/src/run_every.h: In constructor ‘crimson::RunEvery::RunEvery(D, int)’:
ceph/src/dmclock/support/src/run_every.h:48:7: error: class ‘crimson::RunEvery’ does not have any field named ‘body’
body(_body)
^~~~
ceph/src/dmclock/support/src/run_every.h:48:12: error: ‘_body’ was not declared in this scope
body(_body)
^~~~~
ceph/src/dmclock/support/src/run_every.cc: In member function ‘void crimson::RunEvery::run()’:
ceph/src/dmclock/support/src/run_every.cc:70:7: error: ‘body’ was not declared in this scope
body();
^~~~
ceph/src/dmclock/support/src/run_every.cc:70:7: note: suggested alternative: ‘bool’
body();
^~~~
bool
Signed-off-by: Jos Collin <jcollin@redhat.com>
it's better this way, as MgrClient is more like an internal consumer
of the services offered by OSD, instead of service privider. it could
prevent future problem if we can stop it earlier in the shutdown
process.
see also: http://tracker.ceph.com/issues/19638
Signed-off-by: Kefu Chai <kchai@redhat.com>
Creating a snapshot on >=Kraken OSDs using <=Jewel clients can result
in an improperly initialized snapshot namespace. As a result, attempting
to remove the snapshot using a >=Kraken client will result in an -EINVAL
error.
Fixes: http://tracker.ceph.com/issues/19413
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
We have a request that is queued before a pool exists, there is one
epoch where it exists, and then the pool disappears again. The two maps
are processed at the same time. For the first we set needs_resend, map to
an osd, and remove from the homeless sessin. For the second, the pool
dne, we set osd back to -1, and send a map check request. Finally,
handle_osd_maps scans need_resend, sees the pool dne, and removes from
need_resend. The difference from the "usual" case is that we are neither
on the need_resend list nor on the homeless session.
Fix this by concluding immediately that the pool existed (briefly) and
then no longer exists.
Fixes: http://tracker.ceph.com/issues/19552
Signed-off-by: Sage Weil <sage@redhat.com>
If the PG moves we will reconnect and fail to time out.
Wait for longer so that we mask the effects of osd thrashing.
Fixes: http://tracker.ceph.com/issues/19433
Signed-off-by: Sage Weil <sage@redhat.com>
* without this change, in OSDMonitor::update_pending_pgs(), creating_pgs
is updated directly without lock, and the change will be overwritten
with pending changes eventually. so we should update it using
pending_creatings
* also, should acquire the lock in OSDMonitor::send_pg_creates() when
reading creating_pgs_by_osd_epoch and createing_pgs.
Fixes: http://tracker.ceph.com/issues/19814
Signed-off-by: Kefu Chai <kchai@redhat.com>
Stop the MgrClient callbacks to report PG stats at the
start of shutdown() so that we don't get a callback
during/after we are done shutting down.
Protect the cb update with the MgrClient's lock so that
we don't race with MgrClient::send_report() itself.
Fixes: http://tracker.ceph.com/issues/19638
Signed-off-by: Sage Weil <sage@redhat.com>
This avoids contaminating libkv with ObjectStore/BlueStore. It also makes
the blustore kv startup slightly less weird (no need to skip the open
step).
Fixes: http://tracker.ceph.com/issues/19778
Signed-off-by: Sage Weil <sage@redhat.com>