summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* debug message refs (incoming ones at least)wip-refsSage Weil2013-07-181-0/+2
|
* debug Pipe refsSage Weil2013-07-181-1/+1
|
* debug refs on ConnectionSage Weil2013-07-184-5/+6
|
* osd: debug Session refsSage Weil2013-07-182-2/+2
|
* common/RefCountedObject: take cct for debuggingSage Weil2013-07-181-4/+9
|
* mon/MonClient: fix small leakSage Weil2013-07-181-0/+1
| | | | | | We need to delete the version_req_d here. Signed-off-by: Sage Weil <sage@inktank.com>
* mon/MonClient: better debugging on version requestsSage Weil2013-07-181-3/+8
| | | | | | Hunting a leak. Signed-off-by: Sage Weil <sage@inktank.com>
* msgr: mark addr-based [lazy_]send_message and get_connection deprecatedSage Weil2013-07-181-0/+9
| | | | Signed-off-by: Sage Weil <sage@inktank.com>
* client: mark_down by conSage Weil2013-07-181-1/+1
| | | | | | | | We have the con handy; use it. This avoids generate a spurious RESET event, which we do not need or do anything useful with. Note that in this case we are not attaching anything to the Connection priv field. Signed-off-by: Sage Weil <sage@inktank.com>
* mon: mark_down session by con, not addrSage Weil2013-07-181-5/+5
| | | | | | | We have the ConnectionRef here; use it. This avoids generating a spurious RESET event for the connection. Signed-off-by: Sage Weil <sage@inktank.com>
* mon: break con <-> session ref cycle in mon even if shutting downSage Weil2013-07-181-3/+6
| | | | | | | | If we get a reset during shutdown, we should still break the cycle to avoid tripping the valgrind leak detection. Note that we are touching no internal Monitor state here and the locking has not changed. Signed-off-by: Sage Weil <sage@inktank.com>
* msg/SimpleMessenger: remove duplicated interface docsSage Weil2013-07-182-218/+17
| | | | | | | Document these in the interface, not the implementation; having two copies clutters the header and invites them to get out of sync. Signed-off-by: Sage Weil <sage@inktank.com>
* msgr: update docs for mark_down, mark_down_all semanticsSage Weil2013-07-181-16/+26
| | | | | | | | * RESET events * note that the reset detection only happens if it is enabled in the policy. Signed-off-by: Sage Weil <sage@inktank.com>
* msgr: generate reset event on mark_down to addr (not con)Sage Weil2013-07-181-3/+6
| | | | | | | | If the caller is marking down an addr, they presumably don't have the Connection* handy, so we should generate a reset event to help them clean up con <-> session ref cycles. Signed-off-by: Sage Weil <sage@inktank.com>
* osd/ReplicatedPG: fix obc leak on invalid LIST_SNAPS opSage Weil2013-07-181-0/+1
| | | | | Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* osd: break con <-> session cycle when marking down old peersSage Weil2013-07-181-1/+3
| | | | | Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* osd: make ms_handle_reset debug more usefulSage Weil2013-07-181-1/+1
| | | | | Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* cls_lock: fix duration testSage Weil2013-07-181-3/+12
| | | | | | | | | | It's possible for us to just be really slow when getting the reply to the first op or doing the second op, resulting in a successful lock. If we do get a success, assert that at least that amount of time has passed to avoid any false positives. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Yehuda Sadeh <yehuda@inktank.com>
* mds: tracedn should be NULL for LOOKUPINO/LOOKUPHASH replyYan, Zheng2013-07-181-1/+1
| | | | | | Fixes: #5658 Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com> Reviewed-by: Sage Weil <sage@inktank.com>
* FileStore: add global replay guard for split, collection_renameSamuel Just2013-07-182-1/+85
| | | | | | | | | | | | In the event of a split or collection rename, we need to ensure that we don't replay any operations on objects within those collections prior to that point. Thus, we mark a global replay guard on the collection after doing a syncfs and make sure to check that in _check_replay_guard() for all object operations. Fixes: #5154 Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* msg/Pipe: do not hold pipe_lock for verify_authorizer()Sage Weil2013-07-181-2/+7
| | | | | | | | | | | | | We shouldn't hold the pipe_lock while doing the ms_verify_authorizer upcalls. Fix by unlocking a bit earlier, and verifying our state is still correct in the failure path. This regression was introduced by ecab4bb9513385bd765cca23e4e2fadb7ac4bac2. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
* mon: fix off-by-one in check for when sync falls behindSage Weil2013-07-181-1/+1
| | | | | | | | This is what e213b1bc25a212ffe42623c1d4b4eadf9f69319e intended to do but managed to bungle by using >= instead of >. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Joao Eduardo Luis <joao.luis@inktank.com>
* Merge pull request #444 from ceph/wip-osd-latencySage Weil2013-07-179-3/+198
|\ | | | | | | | | | | | | osd: include op queue age histogram in osd_stat_t Reviewed-by: Greg Farnum <greg@inktank.com> Reviewed-by: Dan Mick <dan.mick@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
| * mon: make 'health' warn about slow requestsSage Weil2013-07-173-0/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently we see slow request warnings go by in the cluster log, but they are not reflected by 'ceph health'. Use the new op queue histograms to raise a flag there as well. For example: HEALTH_WARN 59 requests are blocked > 32 sec; 2 osds have slow requests 21 ops are blocked > 65.536 sec 38 ops are blocked > 32.768 sec 16 ops are blocked > 65.536 sec on osd.1 23 ops are blocked > 32.768 sec on osd.1 5 ops are blocked > 65.536 sec on osd.2 15 ops are blocked > 32.768 sec on osd.2 2 osds have slow requests Fixes: #5505 Signed-off-by: Sage Weil <sage@inktank.com>
| * osd: include op queue age histogram in osd_stat_tSage Weil2013-07-176-3/+142
| | | | | | | | | | | | | | | | | | | | This includes a simple power-of-2 histogram of op ages in the op queue inside osd_stat_t. This can be used for a coarse view of overall cluster performance (it will get summed by the mon), to identify specific outlier osds who have a higher latency than the others, or to identify stuck ops. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* | rgw: drop unused assignmentSage Weil2013-07-171-2/+2
|/ | | | | | | | rgw/rgw_rados.cc: In member function 'virtual int RGWPutObjProcessor_Atomic::handle_data(ceph::bufferlist&, off_t, void**)': rgw/rgw_rados.cc:648:5: warning: parameter 'ofs' set but not used [-Wunused-but-set-parameter] Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Yehuda Sadeh <yehuda@inktank.com>
* qa/workunits/cephtool/test.sh: test 'osd create <uuid>'Sage Weil2013-07-171-0/+7
| | | | | | | Make sure it gives us back the same id. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Dan Mick <dan.mick@inktank.com>
* PG: start flush on primary only after we process the master logSamuel Just2013-07-171-5/+15
| | | | | | | | | | | | | Once we start serving reads, stray objects must have already been removed. Therefore, we have to flush all operations up to the transaction writing out the authoritative log. On replicas, we flush in Stray() if we will not eventually be activated and in ReplicaActive if we are in the acting set. This way a replica won't serve a replica read until the store is consistent. Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* ReplicatedPG: replace clean_up_local with a debug checkSamuel Just2013-07-175-13/+24
| | | | | | | | | | Stray objects should have been cleaned up in the merge_log transactions. Only on the primary have those operations necessarily been flushed at activate(). Fixes: 5084 Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* msgr: fix a typo/goto-cross from dd4addef2dGreg Farnum2013-07-171-1/+2
| | | | | | | We didn't build or review carefully enough! Signed-off-by: Greg Farnum <greg@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* Merge pull request #441 from ceph/wip-5626Sage Weil2013-07-176-23/+78
|\ | | | | | | | | msgr fixes for lossless peer sessions Reviewed-by: Greg Farnum <greg@inktank.com>
| * osd: make 'from dead osd' message more informativeSage Weil2013-07-171-1/+4
| | | | | | | | | | | | I thought I saw some weirdness here. Signed-off-by: Sage Weil <sage@inktank.com>
| * msg/Pipe: a bit of additional debug outputSage Weil2013-07-171-2/+7
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
| * msg/Pipe: hold pipe_lock during important parts of accept()Sage Weil2013-07-171-14/+28
| | | | | | | | | | | | | | | | | | | | | | | | Previously we did not bother with locking for accept() because we were not visible to any other threads. However, we need to close accepting Pipes from mark_down_all(), which means we need to handle interference. Fix up the locking so that we hold pipe_lock when looking at Pipe state and verify that we are still in the ACCEPTING state any time we retake the lock. Signed-off-by: Sage Weil <sage@inktank.com>
| * msgr: close accepting_pipes from mark_down_all()Sage Weil2013-07-171-0/+12
| | | | | | | | | | | | | | We need to catch these pipes too, particularly when doing a rebind(), to avoid them leaking through. Signed-off-by: Sage Weil <sage@inktank.com>
| * msgr: maintain list of accepting pipesSage Weil2013-07-173-0/+11
| | | | | | | | | | | | | | | | New pipes exist in a sort of limbo before we know who the peer is and add them to rank_pipe. Keep a list of them in accepting_pipes for that period. Signed-off-by: Sage Weil <sage@inktank.com>
| * msgr: adjust nonce on rebind()Sage Weil2013-07-171-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We can have a situation where: - we have a pipe to a peer - pipe goes to standby (on peer) - we rebind to a new port - .... - we rebind again to the same old port - we connect to peer and get reattached to the ancient pipe from two instances back. Avoid that by picking a new nonce each time we rebind. Add 1,000,000 each time so that the port is still legible in the printed output. Signed-off-by: Sage Weil <sage@inktank.com>
| * msgr: mark_down_all() after, not before, rebindSage Weil2013-07-171-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we are shutting down all old connections and binding to new ports, we want to avoid a sequence like: - close all prevoius connections - new connection comes in on old port - rebind to new ports -> connection from old port leaks through As a first step, close all connections after we shut down the old accepter and before we start the new one. Signed-off-by: Sage Weil <sage@inktank.com>
| * msg/Pipe: unlock msgr->lock earlier in accept()Sage Weil2013-07-171-4/+1
| | | | | | | | | | | | | | Small cleanup. Nothing needs msgr->lock for the previously larger window. Signed-off-by: Sage Weil <sage@inktank.com>
| * msg/Pipe: avoid creating empty out_q entrySage Weil2013-07-171-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We need to maintain the invariant that all sub queues in out_q are never empty. Fix discard_requeued_up_to() to avoid creating an entry unless we know it is already present. This bug leads to an incorrect reconnect attempt when - we accept a pipe (lossless peer) - they send some stuff, maybe - fault - we initiate reconnect, even tho we have nothing queued In particular, we shouldn't reconnect because we aren't checking for resets, and the fact that our out_seq is 0 while the peer's might be something else entirely will trigger asserts later. This fixes at least one source of #5626, and possibly #5517. Backport: cuttlefish Signed-off-by: Sage Weil <sage@inktank.com>
| * msg/Pipe: assert lock is held in various helpersSage Weil2013-07-171-0/+3
|/ | | | | | These all require that we hold pipe_lock. Signed-off-by: Sage Weil <sage@inktank.com>
* ceph_mon: obtain backup monmap if store is marked with 'force_sync'Joao Eduardo Luis2013-07-171-1/+2
| | | | | Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* mon/OSDMonitor: make 'osd pool mksnap ...' not expose uncommitted stateSage Weil2013-07-171-22/+25
| | | | | | | | We were returning success without waiting if the pending pool state had the snap. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Joao Eduardo Luis <joao.luis@inktank.com>
* qa/workunits/cephtest/test.sh: put 'osd ls' before any 'osd create' testsSage Weil2013-07-171-5/+4
| | | | | | | | A monc/mon connection fault or the dup command test flag may mean an extra osd id is created that we isn't actually up; reorder so that doesn't screw up 'osd ls'. Signed-off-by: Sage Weil <sage@inktank.com>
* mon: MonCommands: remove obsolete 'sync status' commandJoao Eduardo Luis2013-07-171-1/+0
| | | | | | | | Obsoleted by the sync refactor from da0aff28ab478bcc3136715f92bc1af8d4b403c1 Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* OSD::_try_resurrect_pg: fix cur/pgid confusionSamuel Just2013-07-161-2/+2
| | | | | | | | | | | | | | This bug prevented resurrection of ancestor pgs where necessary. Fixes: #5269 This may result in pg A being created just before pg B is resurrected and split into A and B resulting in one or the other operations getting and EEXIST. Backport: cuttlefish Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* mon/AuthMonitor: make 'auth del ...' idempotentSage Weil2013-07-161-2/+2
| | | | Signed-off-by: Sage Weil <sage@inktank.com>
* qa/workunits/cephtool/test.sh: mds cluster_down/up are idempotentSage Weil2013-07-161-4/+2
| | | | | | As of d45429b81ab9817284d6dca98077cb77b5e8280f; fix the test. Signed-off-by: Sage Weil <sage@inktank.com>
* ceph: send successful commands twice with CEPH_CLI_TEST_DUP_COMMANDSage Weil2013-07-161-0/+9
| | | | | | | | Monitor commands need to be idempotent. This helps us test this by simply issuing any successful command a second time so that we notice when a dup submission fails. Signed-off-by: Sage Weil <sage@inktank.com>
* mon/MDSMonitor: make 'mds cluster_{up,down}' idempotentSage Weil2013-07-161-6/+2
| | | | Signed-off-by: Sage Weil <sage@inktank.com>