summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* qa: don't suppress output from rbd commandswip-rbd-workunit-debugJosh Durgin2013-03-011-71/+81
| | | | | | This makes debugging failures much easier. Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
* msgr: drop messages on cons with CLOSED PipesSage Weil2013-02-281-0/+2
| | | | | | | | | | | | | | | | | | | | | | Back in commit 6339c5d43974f4b495f15d199e01a141e74235f5, we tried to make this deal with a race between a faulting pipe and new messages being queued. The sequence is - fault starts on pipe - fault drops pipe_lock to unregister the pipe - user (objecter) queues new message on the con - submit_message reopens a Pipe (due to this bug) - the message managed to make it out over the wire - fault finishes faulting, calls ms_reset - user (objecter) closes the con - user (objecter) resends everything It appears as though the previous patch *meant* to drop *m on the floor in this case, which is what this patch does. And that fixes the crash I am hitting; see #4271. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
* FileJournal::wrap_read_bl: adjust pos before returningSamuel Just2013-02-281-0/+2
| | | | | | | | | | | | Otherwise, we may feed an offset past the end of the journal to check_header in read_entry and incorrectly determine that the entry is corrupt. Fixes: 4296 Backport: bobtail Backport: argonaut Reviewed-by: Sage Weil <sage@inktank.com> Signed-off-by: Samuel Just <sam.just@inktank.com>
* librbd: fix rollback sizeJosh Durgin2013-02-261-1/+1
| | | | | | | | | | | The duplicate calls to get_image_size() and get_snap_size() replaced by 5806226cf0743bb44eaf7bc815897c6846d43233 uncovered this. The first call was using the currently set snap_id instead of the snapshot being rolled back to. Fixes: #4272 Signed-off-by: Josh Durgin <josh.durgin@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* msg: fix entity_addr_t::is_same_host() for IPv6Sage Weil2013-02-261-1/+1
| | | | | | | We weren't checking the memcmp return value properly! Aie... Backport: bobtail Signed-off-by: Sage Weil <sage@inktank.com>
* ceph_common.sh: tolerate missing mds, mon, osds in confSage Weil2013-02-261-3/+3
| | | | | | | | With set -e this seems to fail (at least on some machines) if, say, there is no MDS in the conf file. This fixes it. Tested-by: Mark Nelson <mark.nelson@inktank.com> Signed-off-by: Sage Weil <sage@inktank.com>
* Merge remote-tracking branch 'gh/wip-4249' into nextSage Weil2013-02-251-16/+15
|\
| * librbd: drop snap_lock before invalidating cacheJosh Durgin2013-02-251-16/+15
| | | | | | | | | | | | | | | | | | | | | | | | Writeback will take the snap_lock, so read everything we need under it before invalidating the cache. This avoids a recursive lock when writeback uses snap_lock while snap_rollback() was holding it. Remove a not-very-useful debugging message that depended on snap_lock being held. Fixes: #4249 Backport: bobtail Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
* | systest: restrict list error acceptanceJosh Durgin2013-02-251-1/+1
| | | | | | | | | | | | | | | | Only ignore errors after the midway point if the midway_sem_post is defined. Signed-off-by: Josh Durgin <josh.durgin@inktank.com> (cherry picked from commit 5b24a68b6e7d57bac688021b822fb2f73494c3e9)
* | systest: fix race with pool deletionJosh Durgin2013-02-254-13/+19
|/ | | | | | | | | | | | The second test have pool deletion and object listing wait on the same semaphore to connect and start. This led to errors sometimes when the pool was deleted before it could be opened by the listing process. Add another semaphore so the pool deletion happens only after the listing has begun. Fixes: #4147 Signed-off-by: Josh Durgin <josh.durgin@inktank.com> (cherry picked from commit b0271e390564119e998e18189282252d54f75eb6)
* mds: reencode MDSMap in MMDSMap if MDSENC feature is not presentSage Weil2013-02-231-1/+2
| | | | | | | | | | | In some cases the MMDSMap message from mon -> client passes from leader -> peon -> client, and the leader doesn't encode with the correct feature bits. As with MMOSDMap, we reencode the nested MDSMap based on the features if relevant bits are not present. We forgot to include this with the mds encoding changes. Signed-off-by: Sage Weil <sage@inktank.com>
* qa/run_xfstests.sh: use $TESTDIR instead of /tmp/cephtestSage Weil2013-02-231-11/+12
| | | | Signed-off-by: Sage Weil <sage@inktank.com>
* osd: an interval can't go readwrite if its acting is emptySage Weil2013-02-231-1/+2
| | | | | | | | Let's not forget that min_size can be zero. Fixes: #4159 Signed-off-by: Sage Weil <sage@inktank.com> (cherry picked from commit 4277265d99647c9fe950ba627e5d86234cfd70a9)
* configuration parsing: give better error for missing =Dan Mick2013-02-211-2/+7
| | | | | | | | | | A ceph.conf line with "key" and no "= value" currently shows "unexpected character while parsing putative key value, at char N line M". There's no reason it can't be clearer. Fixes: #4229 Signed-off-by: Dan Mick <dan.mick@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* ceph_common.sh: fix iteration of items in ceph.confSage Weil2013-02-211-3/+3
| | | | | | This broke in c8f528a4070dd3aa0b25c435c6234032aee39b21. Signed-off-by: Sage Weil <sage@inktank.com>
* mds: use inode_t::layout for dir layout policyGreg Farnum2013-02-2111-214/+93
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This cherry-pick is going in the reverse direction of normal. That's because this direction makes for the minimal change -- this patchset is required to fix the loss of directory layouts we were previously seeing, but fixing it requires changing the encoding versions. So we wrote it on top of Bobtail and let it update the struct_v's as they existed then. Note that we here change a few encoding versions in ways which are NOT COMPATIBLE with previous development code (but not any releases). In particular, development code introduced and this removes the file_layout_policy_t, and some of the CInode and EMetaBlob encoding struct_v values were used in development code to mean one thing, but mean something different due to the Bobtail patch. Remove the default_file_layout struct, which was just a ceph_file_layout, and store it in the inode_t. Rip out all the annoying code that put this on the heap. To aid in this usage, add a clear_layout() function to inode_t. Signed-off-by: Sage Weil <sage.weil@dreamhost.com> Signed-off-by: Greg Farnum <greg@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com> (cherry picked from commit 36ed407e0f939a9bca57c3ffc0ee5608d50ab7ed) Conflicts: src/mds/CInode.cc src/mds/CInode.h src/mds/MDCache.cc src/mds/Server.cc src/mds/events/EMetaBlob.h Cherry-pick- Reviewed-by: Sage Weil <sage@inktank.com>
* mds: parse ceph.*.layout vxattr key/value contentSage Weil2013-02-212-1/+57
| | | | | | | | | Use qi to parse a strictly formatted set of key/value pairs. Be picky about whitespace. Any subset of recognized keys is allowed. Parse the same set of keys as the ceph.*.layout.* vxattrs. Signed-off-by: Sage Weil <sage@inktank.com> (cherry picked from commit 5551aa5b3b5c2e9e7006476b9cd8cc181d2c9a04)
* Fix failing > 4MB range requests through radosgw S3 API.Jan Harkes2013-02-211-4/+4
| | | | | | | | | | | | | | When a range request is made for more than rgw_get_obj_max_req_size bytes the first returned chunk sets 'ret' to STATUS_PARTIAL_CONTENT and all remaining chunks behave as if there is an error state and only return a minimal header. Fix this by passing STATUS_PARTIAL_CONTENT to set_req_state_err, but leave the 'ret' member variable untouched. Signed-off-by: Jan Harkes <jaharkes@cs.cmu.edu> Reviewed-by: Yehuda Sadeh <yehuda@inktank.com> (cherry picked from commit c83a01d4e8dcd26eec24c020c5b79fcfa4ae44a3)
* osd: clear recovery state on pg removalSage Weil2013-02-211-0/+4
| | | | | | | | | | | This ensures we release our in-progress recovery counters, which prevents recovery from getting blocked indefinitely when a pool removal races with recovery ops. Fixes: #4217 Backport: bobtail Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* rgw: refactor header grantsYehuda Sadeh2013-02-201-22/+11
| | | | | | Move definition to a static array. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
* rgw_acl: Support ACL grants in headers.caleb miles2013-02-2011-34/+244
| | | | | | | | | | | | | | | Issue 3669: Support S3 ACL grants specified in request headers. Allow requests, excluding POST object, to specify ACL grants in HTTP headers. Signed-off-by: caleb miles <caleb.miles@inktank.com> Conflicts: src/rgw/rgw_acl_s3.cc src/rgw/rgw_acl_s3.h src/rgw/rgw_rest_s3.cc src/rgw/rgw_rest_s3.h Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
* osd: lock pg in build_past_intervals_parallel()Sage Weil2013-02-201-0/+2
| | | | | | | | | Methods called by write_if_dirty() (get_osdmap()) assert that the pg is locked. Backport: bobtail Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* rgw: fix multipart uploads listingYehuda Sadeh2013-02-191-4/+4
| | | | | | | | | | Fixes: #4177 Backport: bobtail Listing multipart uploads had a typo, and was requiring the wrong resource (uploadId instead of uploads). Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
* rgw: don't copy object when it's copied into itselfYehuda Sadeh2013-02-191-25/+38
| | | | | | | | | | | Fixes: #4150 Backport: bobtail When object copied into itself, object will not be fully copied: tail reference count stays the same, head part is rewritten. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
* test/bufferlist: fix warningSage Weil2013-02-191-1/+1
| | | | | | | | | | In file included from test/bufferlist.cc:31:0: ../src/gtest/include/gtest/gtest.h: In function ‘testing::AssertionResult testing::internal::CmpHelperEQ(const char*, const char*, const T1&, const T2&) [with T1 = unsigned int, T2 = int]’: ../src/gtest/include/gtest/gtest.h:1300:30: instantiated from ‘static testing::AssertionResult testing::internal::EqHelper::Compare(const char*, const char*, const T1&, const T2&) [with T1 = unsigned int, T2 = int, bool lhs_is_null_literal = false]’ test/bufferlist.cc:1604:227: instantiated from here warning: ../src/gtest/include/gtest/gtest.h:1263:3: comparison between signed and unsigned integer expressions [-Wsign-compare] Signed-off-by: Sage Weil <sage@inktank.com>
* Merge branch 'master' of https://github.com/ceph/cephGary Lowell2013-02-197-37/+115
|\
| * testing: updating hadoop-internal testJoe Buck2013-02-191-12/+13
| | | | | | | | | | | | | | | | Small tweaks to the hadoop-internal test to better use existing environment varaibles. Signed-off-by: Joe Buck <jbbuck@gmail.com> Reviewed-by: Noah Watkins <noahwatkins@gmail.com>
| * qa: sample test for new replication testsNoah Watkins2013-02-191-15/+54
| | | | | | | | Signed-off-by: Joe Buck <jbbuck@gmail.com>
| * doc/release-notes: v0.57Sage Weil2013-02-191-0/+40
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
| * PG: remove weirdness log for last_complete < log.tailSamuel Just2013-02-191-6/+0
| | | | | | | | | | | | | | | | | | | | In the case of a divergent object prior to log.tail, last_complete may end up before log.tail. Backport: bobtail Fixes #4174 Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
| * os/FileStore: check replay guard on src for collection renameSage Weil2013-02-191-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This avoids a problematic sequence like: - rename A/ -> B/ - remove B/1...100 - destroy B/ - create A/ - write A/101... <crash> - replay A/ -> B/ - remove B/1...100 (fails but tolerated) - destroy B/ (fails with ENOTEMPTY) Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
| * osd: requeue pg waiters at the front of the finished queueSage Weil2013-02-191-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We could have a sequence like: - op1 - notify - op2 in the finished queue. Op1 gets put on waiting_for_pg, the notify creates the pg and requeues op1 (and the end), op2 is handled, and finally op1 is handled. That breaks ordering; see #2947. Instead, when we wake up a pg, queue the waiting messages at the front of the dispatch queue. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
| * osd: pull requeued requests off one at a timeSage Weil2013-02-191-13/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Pull items off the finished queue on at a time. In certain cases, an event may result in new items betting added to the finished queue that will be put at the *front* instead of the back. See latest incarnation of #2947. Note that this is a significant changed in behavior in that we can theoretically starve if an event keeps resulting in new events getting generated. Beware! Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
| * osd: fix printf warning on pg_log_entry_t::get_key_nameSage Weil2013-02-191-1/+1
| | | | | | | | | | | | | | warning: osd/osd_types.cc:1716:76: format '%lu' expects argument of type 'long unsigned int', but argument 5 has type 'version_t {aka long long unsigned int}' [-Wformat] warning: osd/osd_types.cc:1716:76: format '%lu' expects argument of type 'long unsigned int', but argument 5 has type 'version_t {aka long long unsigned int}' [-Wformat] Signed-off-by: Sage Weil <sage@inktank.com>
* | Merge branch 'next'Gary Lowell2013-02-193-1/+14
|\ \ | |/ |/|
| * v0.57v0.57Gary Lowell2013-02-192-1/+7
| |
| * qa: rbd map-snapshot-io: udevadm settleSage Weil2013-02-181-0/+7
| | | | | | | | | | | | | | | | | | Udev runs blkid on device close, thwarting any rbd unmap that immediately follows use of the device. Explicitly settle for now. See #4183. Signed-off-by: Sage Weil <sage@inktank.com>
* | qa: test_mon_workloadgen: use default config file pathSage Weil2013-02-191-1/+1
| | | | | | | | | | | | | | I'm not sure why we wouldn't. Also, this makes this test work without annoying plumbing to pass the explicit path through. Signed-off-by: Sage Weil <sage@inktank.com>
* | qa: mon/workloadgen.sh: drop TEST_CEPH_CONF codeSage Weil2013-02-191-12/+9
| | | | | | | | | | | | The binaries already pick up on CEPH_CONF, which will be set as needed. Signed-off-by: Sage Weil <sage@inktank.com>
* | rbd: udevadm settle before unmapSage Weil2013-02-191-0/+12
| | | | | | | | | | | | | | | | | | | | udev runs blkid on device close, and other such nonsense that can make unmap fail with EBUSY. Settle before we unmap to avoid this if possible. See #4183. Closes: #4186 Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Alex Elder <elder@inktank.com>
* | test: correcting hadoop-internal testsJoe Buck2013-02-191-6/+5
| | | | | | | | | | | | | | | | | | Changing the hadoop-internal tests to use the newly added $TESTDIR environment variable. Also, removed unneeded variables. Signed-off-by: Joe Buck <jbbuck@gmail.com> Reviewed-by: Sam Lang <sam.lang@inktank.com>
* | testing: adding a Hadoop wordcount testJoe Buck2013-02-191-0/+47
| | | | | | | | | | Signed-off-by: Joe Buck <jbbuck@gmail.com> Reviewed-by: Sam Lang <sam.lang@inktank.com>
* | debian: allow extra args to get passed to ./configure via the environmentSage Weil2013-02-181-1/+2
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | qa: rbd/map-snapshot-io: remove image when doneSage Weil2013-02-181-0/+1
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | qa: fix quoting of wget URLsSage Weil2013-02-183-5/+5
| | | | | | | | | | | | Broke this in ae0c2bbb50ab04467b5223a4f61bfca4b0830142. Signed-off-by: Sage Weil <sage@inktank.com>
* | osd: log weirdness if caller_ops hash gets bigger than the logSage Weil2013-02-181-0/+7
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | Merge pull request #65 from javacruft/wip-ocf-rbdSage Weil2013-02-181-1/+1
|\ \ | | | | | | | | | | | | Strip any trailing whitespace from rbd showmapped Reviewed-by: Sage Weil <sage@inktank.com>
| * | Strip any trailing whitespace from rbd showmappedJames Page2013-02-181-1/+1
|/ / | | | | | | | | | | | | | | More recent versions of ceph append a bit of whitespace to the line after the name of the /dev/rbdX device; this causes the monitor check to fail as it can't find the device name due to the whitespace. This fix excludes any characters after the /dev/rbdN match.
* | buffer: drop large malloc testsSage Weil2013-02-171-2/+4
| | | | | | | | | | | | These succeed on my machine and eat unseemly amounts of RAM. Signed-off-by: Sage Weil <sage@inktank.com>
* | buffer: put big buffer on heap, not stackSage Weil2013-02-171-3/+4
| | | | | | | | | | | | This fixes a segfault on my x86_64 wheezy box. Signed-off-by: Sage Weil <sage@inktank.com>