summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* mds/Server: fix LOOKUPSNAPwip-mds-snapSage Weil2013-06-281-1/+2
| | | | | | | | | | | | | The current LOOKUPSNAP code path was dereferencing mdr->dn[0] and getting SEGV. Instead, set the do_lookup arg to false for getattr so that we do not try to dereference this; for snaps it will always be NULL as we are constructing a fake namespace for the .snap directory. (This happens in the path_traverse, the result of which is to set snapid--without any real dentry). With this fix, snaptest-0.sh passes. Signed-off-by: Sage Weil <sage@inktank.com>
* librados: fix cmd OSDCommand testSage Weil2013-06-281-2/+1
| | | | | | If we get ENXIO, buflen will be 0. Signed-off-by: Sage Weil <sage@inktank.com>
* ceph-disk: s/else if/elif/Greg Farnum2013-06-271-1/+1
| | | | | | Signed-off-by: Greg Farnum <greg@inktank.com> Reviewed-by: Joao Luis <joao.luis@inktank.com> (cherry picked from commit bd8255a750de08c1b8ee5e9c9a0a1b9b16171462)
* qa/workunits/misc/multiple_rsync: put tee output in /tmpSage Weil2013-06-261-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | 2013-06-25T10:29:15.811 INFO:teuthology.task.workunit.client.0.err:+ rsync -auv --exclude local/ /usr/ usr.2 2013-06-25T10:29:15.811 INFO:teuthology.task.workunit.client.0.err:+ tee a 2013-06-25T10:29:15.902 INFO:teuthology.task.workunit.client.0.out:sending incremental file list 2013-06-25T10:29:48.738 INFO:teuthology.task.workunit.client.0.out: 2013-06-25T10:29:48.740 INFO:teuthology.task.workunit.client.0.out:sent 1449972 bytes received 7477 bytes 43505.94 bytes/sec 2013-06-25T10:29:48.740 INFO:teuthology.task.workunit.client.0.out:total size is 3205268241 speedup is 2199.23 2013-06-25T10:29:48.740 INFO:teuthology.task.workunit.client.0.err:+ hexdump -C a 2013-06-25T10:29:48.741 INFO:teuthology.task.workunit.client.0.out:00000000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 |................| 2013-06-25T10:29:48.741 INFO:teuthology.task.workunit.client.0.out:00000010 00 00 00 00 00 00 00 00 00 00 00 00 00 00 0a 73 |...............s| 2013-06-25T10:29:48.742 INFO:teuthology.task.workunit.client.0.out:00000020 65 6e 74 20 31 34 34 39 39 37 32 20 62 79 74 65 |ent 1449972 byte| 2013-06-25T10:29:48.742 INFO:teuthology.task.workunit.client.0.out:00000030 73 20 20 72 65 63 65 69 76 65 64 20 37 34 37 37 |s received 7477| 2013-06-25T10:29:48.742 INFO:teuthology.task.workunit.client.0.out:00000040 20 62 79 74 65 73 20 20 34 33 35 30 35 2e 39 34 | bytes 43505.94| 2013-06-25T10:29:48.742 INFO:teuthology.task.workunit.client.0.out:00000050 20 62 79 74 65 73 2f 73 65 63 0a 74 6f 74 61 6c | bytes/sec.total| 2013-06-25T10:29:48.742 INFO:teuthology.task.workunit.client.0.out:00000060 20 73 69 7a 65 20 69 73 20 33 32 30 35 32 36 38 | size is 3205268| 2013-06-25T10:29:48.742 INFO:teuthology.task.workunit.client.0.out:00000070 32 34 31 20 20 73 70 65 65 64 75 70 20 69 73 20 |241 speedup is | 2013-06-25T10:29:48.743 INFO:teuthology.task.workunit.client.0.out:00000080 32 31 39 39 2e 32 33 0a |2199.23.| 2013-06-25T10:29:48.743 INFO:teuthology.task.workunit.client.0.out:00000088 This passes consistently when the output is in /tmp, but fails after a few iterations when on cephfs+kclient. Avoid the bug with this test. See: #5453 Signed-off-by: Sage Weil <sage@inktank.com>
* rgw: fix radosgw-admin buckets listYehuda Sadeh2013-06-262-7/+13
| | | | | | | | | | Fixes: #5455 Backport: cuttlefish This commit fixes a regression, where radosgw-admin buckets list operation wasn't returning any data. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* Handle non-existent front interface in maps from older MONsDavid Zafman2013-06-261-3/+6
| | | | | | | | | | Fix OSDService::get_con_osd_hb() to not try to get_connection() without front interface Fix OSD::handle_osd_map() to check for missing front interface Fixes: #5460 Signed-off-by: David Zafman <david.zafman@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* ceph-disk: do not mount over an osd directly in /var/lib/ceph/osd/$cluster-$idSage Weil2013-06-261-0/+7
| | | | | | | | | | | If we see a 'ready' file in the target OSD dir, do not mount our device on top of it. Among other things, this prevents ceph-disk activate on stray disks from stepping on teuthology osds. Fixes: #5445 Signed-off-by: Sage Weil <sage@inktank.com>
* cephtool/test.sh: add case for auth add with no capsDan Mick2013-06-261-0/+2
| | | | | | | Test case for failure in #5467. Supplying new auth info overwrites. Signed-off-by: Dan Mick <dan.mick@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* MonCommands.h: auth add doesn't require caps (it can use -i <file>)Dan Mick2013-06-261-1/+1
| | | | | | | | | This was a regression from the old behavior introduced by the CLI rewrite. Fixes: #5467 Signed-off-by: Dan Mick <dan.mick@inktank.com> Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
* Makefile.am: fix libglobal.la race with ceph_test_corsDan Mick2013-06-261-17/+16
| | | | | | | | | ceph_test_cors had libglobal.la in its _LDFLAGS macro definition; it should have been in _LDADD. Moreover, things using libglobal.la ought to be using LIBGLOBAL_LDA to add it to _LDADD. Fix them all. Signed-off-by: Dan Mick <dan.mick@inktank.com> Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
* Merge branch 'next'Gary Lowell2013-06-252-1/+7
|\
| * v0.65v0.65Gary Lowell2013-06-252-1/+7
| |
* | Merge pull request #380 from dachary/wip-4907Josh Durgin2013-06-251-6/+11
|\ \ | | | | | | | | | | | | get_xattr() can return more than 4KB Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
| * | get_xattr() can return more than 4KBLoic Dachary2013-06-251-6/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of failing if the attribute to be returned is larger than 4KB, double the buffer size each time librados.rados_getxattr returns -errno.ERANGE and try again. http://tracker.ceph.com/issues/4907 fixes #4907 Signed-off-by: Loic Dachary <loic@dachary.org>
* | | Merge pull request #379 from dachary/wip-5312Sage Weil2013-06-251-0/+4
|\ \ \ | |/ / |/| | | | | | | | skip TEST(EXT4StoreTest, _detect_fs) if DISK or MOUNTPOINT are undefined Reviewed-by: Sage Weil <sage@inktank.com>
| * | skip TEST(EXT4StoreTest, _detect_fs) if DISK or MOUNTPOINT are undefinedLoic Dachary2013-06-251-0/+4
|/ / | | | | | | | | | | | | | | | | | | | | | | | | The TEST(EXT4StoreTest, _detect_fs) test is meant to be run from qa/workunits/filestore/filestore.sh, after the ext4 file system was created. If the DISK and MOUNTPOINT environment variables are not defined, display a message explaining the expected environment and silentely skip the test. The tests in store_test.cc are not unit tests because they depend on their environment. http://tracker.ceph.com/issues/5312 fixes #5312 Signed-off-by: Loic Dachary <loic@dachary.org>
* | Merge remote-tracking branch 'gh/next'Sage Weil2013-06-246-5/+34
|\ \ | |/
| * mon/Elector: cancel election timer if we bootstrapSage Weil2013-06-241-0/+1
| | | | | | | | | | | | | | | | | | If we short-circuit and bootstrap, cancel our timer. Otherwise it will go off some time later when we are in who knows what state. Backport: cuttlefish Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Joao Eduardo Luis <joao.luis@inktank.com>
| * mon: cancel probe timeout on resetSage Weil2013-06-241-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we are probing and get (say) an election timeout that calls reset(), cancel the timer. Otherwise, we assert later with a splat like 2013-06-24 01:09:33.675882 7fb9627e7700 4 mon.b@0(leader) e1 probe_timeout 0x307a520 2013-06-24 01:09:33.676956 7fb9627e7700 -1 mon/Monitor.cc: In function 'void Monitor::probe_timeout(int)' thread 7fb9627e7700 time 2013-06-24 01:09:43.675904 mon/Monitor.cc: 1888: FAILED assert(is_probing() || is_synchronizing()) ceph version 0.64-613-g134d08a (134d08a9654f66634b893d493e4a92f38acc63cf) 1: (Monitor::probe_timeout(int)+0x161) [0x56f5c1] 2: (Context::complete(int)+0xa) [0x574a2a] 3: (SafeTimer::timer_thread()+0x425) [0x7059a5] 4: (SafeTimerThread::entry()+0xd) [0x7065dd] 5: (()+0x7e9a) [0x7fb966f62e9a] 6: (clone()+0x6d) [0x7fb9652f9ccd] NOTE: a copy of the executable, or `objdump -rdS <executable>` is needed to interpret this. Fixes: #5438 Backport: cuttlefish Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Joao Eduardo Luis <joao.luis@inktank.com>
| * mon/AuthMonitor: ensure initial rotating keys get encoded when ↵Sage Weil2013-06-241-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | create_initial called 2x The create_initial() method may get called multiple times; make sure it will unconditionally generate new/initial rotating keys. Move the block up so that we can easily assert as much. Broken by commit cd98eb0c651d9ee62e19c2cc92eadae9bed678cd. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Yehuda Sadeh <yehuda@inktank.com>
| * init-radosgw.sysv: remove -x debug modeSage Weil2013-06-241-1/+1
| | | | | | | | | | Fixes: #5443 Signed-off-by: Sage Weil <sage@inktank.com>
| * common/pick_addresses: behave even after internal_safe_to_start_threadsSage Weil2013-06-241-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ceph-mon recently started using Preforker to working around forking issues. As a result, internal_safe_to_start_threads got set sooner and calls to pick_addresses() which try to set string config values now fail because there are no config observers for them. Work around this by observing the change while we adjust the value. We assume pick_addresses() callers are smart enough to realize that their result will be reflected by cct->_conf and not magically handled elsewhere. Fixes: #5195, #5205 Backport: cuttlefish Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Dan Mick <dan.mick@inktank.com>
| * Add python-argparse to dependencies (for pre-2.7 systems)Dan Mick2013-06-241-1/+2
| | | | | | | | Signed-off-by: Dan Mick <dan.mick@inktank.com>
* | osd: tolerate racing threads starting recovery opsSage Weil2013-06-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | We sample the (max - active) recovery ops to know how many to start, but do not hold the lock over the full duration, such that it is possible to start too many ops. This isn't problematic except that our condition checks for being == max but not beyond it, and we will continue to start recovery ops when we shouldn't. Fix this by adjusting the conditional to be <=. Reported-by: Stefan Priebe <s.priebe@profihost.ag> Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: David Zafman <david.zafman@inktank.com>
* | Merge pull request #376 from dalgaaf/wip-da-SCA-cppcheck-3Sage Weil2013-06-247-13/+12
|\ \ | | | | | | Reviewed-by: Sage Weil <sage@inktank.com>
| * | test/librados/cmd.cc: use static_cast instead of C-Style castDanny Al-Gaaf2013-06-241-1/+1
| | | | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
| * | osdc/Objecter.cc: use static_cast instead of C-Style castDanny Al-Gaaf2013-06-241-1/+1
| | | | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
| * | mon/MonClient.cc: use static_cast instead of C-Style castDanny Al-Gaaf2013-06-241-1/+1
| | | | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
| * | common/cmdparse.cc: reduce scope of local variable 'pos'Danny Al-Gaaf2013-06-241-2/+1
| | | | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
| * | common/cmdparse.cc: remove unused variableDanny Al-Gaaf2013-06-241-1/+1
| | | | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
| * | osd/OSD.cc: prefer prefix ++operator for non-trivial iteratorDanny Al-Gaaf2013-06-241-1/+1
| | | | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
| * | OSDMonitor.cc: prefer prefix ++operator for non-trivial iteratorDanny Al-Gaaf2013-06-241-1/+1
| | | | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
| * | mon/MonCap.cc: use empty() instead of if(size())Danny Al-Gaaf2013-06-241-1/+1
| | | | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
| * | common/cmdparse.cc: prefer prefix ++operator for non-trivial iteratorDanny Al-Gaaf2013-06-241-4/+4
| | | | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
* | | debian, rpm: remove python-lockfile dependencySage Weil2013-06-242-2/+0
| | | | | | | | | | | | | | | | | | | | | As for 2a4953b697a3464862fd3913336edfd7eede2487 ceph-disk no longer uses this. Signed-off-by: Sage Weil <sage@inktank.com>
* | | Merge remote-tracking branch 'gh/next'Sage Weil2013-06-246-8/+27
|\ \ \ | |/ / |/| / | |/
| * mds: do not assume segment list is non-empty in standby_trim_segmentsSage Weil2013-06-242-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we restart standby replay shortly after startup, before we actually have any segments, we an trigger a segfault here: ceph version 0.64-441-gc39b99c (c39b99cdecceaca77f66eafbcc38387406826406) 1: ceph-mds() [0x975caa] 2: (()+0xfcb0) [0x7fc33b5a5cb0] 3: (MDLog::standby_trim_segments()+0x192) [0x78a932] 4: (MDS::C_MDS_StandbyReplayRestartFinish::finish(int)+0x39) [0x595f69] 5: (Journaler::_finish_reprobe(int, unsigned long, Context*)+0x190) [0x7917b0] 6: (Filer::_probed(Filer::Probe*, object_t const&, unsigned long, utime_t)+0x558) [0x7c6b38] 7: (Objecter::C_Stat::finish(int)+0xc0) [0x7c7930] 8: (Objecter::handle_osd_op_reply(MOSDOpReply*)+0xe48) [0x7b2c78] 9: (MDS::handle_core_message(Message*)+0xae8) [0x589858] 10: (MDS::_dispatch(Message*)+0x2f) [0x589a1f] 11: (MDS::ms_dispatch(Message*)+0x1d3) [0x58b4a3] 12: (DispatchQueue::entry()+0x3f1) [0x943861] 13: (DispatchQueue::DispatchThread::entry()+0xd) [0x86e32d] Fixes: #5333 Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com> (cherry picked from commit abd0ff64e108b7670a062b3fa39baaf3d3e48fb3)
| * Merge pull request #374 from ceph/wip-5427Sage Weil2013-06-243-6/+11
| |\ | | | | | | Reviewed-by: Joao Eduardo Luis <joao.luis@inktank.com>
| | * mon/AuthMonitor: make initial auth include rotating keysSage Weil2013-06-233-6/+11
| |/ | | | | | | | | | | | | | | This closes a very narrow race during mon creation where there are no service keys. Fixes: #5427 Signed-off-by: Sage Weil <sage@inktank.com>
| * mon: do not leak no_reply messagesSage Weil2013-06-231-1/+5
| | | | | | | | | | | | | | | | | | I think I assumed no_reply() was releasing the references, but it is not. Which is better, since send_reply() doesn't either. Fix the leaks by dropping the message ref explicitly. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Joao Eduardo Luis <joao.luis@inktank.com>
| * mon: fix leak of MOSDFailure messagesSage Weil2013-06-232-0/+10
| | | | | | | | | | | | | | | | We need to discard/cancel/free the failure report messages before we cancel a report out. Assert in the dtor to ensure we didn't forget. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Joao Eduardo Luis <joao.luis@inktank.com>
| * debian: ceph-common requires matching version of python-cephSage Weil2013-06-221-1/+1
| | | | | | | | | | | | If they skew the ceph_argparse.py module may be missing. Signed-off-by: Sage Weil <sage@inktank.com>
* | Merge pull request #375 from ceph/wip-msgrGregory Farnum2013-06-232-60/+71
|\ \ | | | | | | | | | | | | misc msgr fixes Reviewed-by: Greg Farnum <greg@inktank.com>
| * | msgr: clear_pipe+queue reset when replacing lossy connectionsSage Weil2013-06-232-3/+10
| | | | | | | | | | | | | | | | | | | | | | | | We already handle the lossless replacement and lossy fault paths, but not the lossy replacement. This fixes an assert(!cleared) in the reaper. Adjust comments appropriately. Signed-off-by: Sage Weil <sage@inktank.com>
| * | msgr: reaper: make sure pipe has been cleared (under pipe_lock)Sage Weil2013-06-231-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | All paths to pipe shutdown should have cleared the con->pipe reference already. Assert as much. Also, do it under pipe_lock! Signed-off-by: Sage Weil <sage@inktank.com>
| * | msg/Pipe: goto fail_unlocked on early failures in accept()Sage Weil2013-06-231-55/+46
| | | | | | | | | | | | | | | | | | | | | | | | Instead of duplicating an incomplete cleanup sequence (that does not clear_pipe()), goto fail_unlocked and do the cleanup in a generic way. s/rc/r/ while we are here. Signed-off-by: Sage Weil <sage@inktank.com>
| * | msgr: clear con->pipe inside pipe_lock on mark_downSage Weil2013-06-231-0/+10
| | | | | | | | | | | | | | | | | | We need to do this under protection of the pipe_lock. Signed-off-by: Sage Weil <sage@inktank.com>
| * | msgr: clear_pipe inside pipe_lock on mark_down_allSage Weil2013-06-231-1/+1
|/ / | | | | | | | | | | | | | | | | Observed a segfault in rebind -> mark_down_all -> clear_pipe -> put that may have been due to a racing thread clearing the connection_state pointer. Do the clear_pipe() call under the protection of pipe_lock, as we do in all other contexts. Signed-off-by: Sage Weil <sage@inktank.com>
* | Merge branch 'next'Dan Mick2013-06-215-941/+987
|\ \ | |/ | | | | | | Conflicts: src/ceph.in
| * Add header comments and Inktank copyrights to ceph.in/ceph_argparse.pyDan Mick2013-06-212-0/+25
| | | | | | | | Signed-off-by: Dan Mick <dan.mick@inktank.com>