summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* rgw: fix multi deletewip-5931-bobtailYehuda Sadeh2013-08-121-1/+1
| | | | | | | | | | | | | | | Fixes: #5931 Backport: bobtail, cuttlefish Fix a bad check, where we compare the wrong field. Instead of comparing the ret code to 0, we compare the string value to 0 which generates implicit casting, hence the crash. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> (cherry picked from commit f9f1c48ad799da2b4be0077bf9d61ae116da33d7) Conflicts: src/rgw/rgw_rest_s3.cc
* ceph-fuse: create finisher threads after fork()Sage Weil2013-06-241-24/+29
| | | | | | | | | | | | | The ObjectCacher and MonClient classes both instantiate Finisher threads. We need to make sure they are created *after* the fork(2) or else the process will fail to join() them on shutdown, and the threads will not exist while fuse is doing useful work. Put CephFuse on the heap and move all this initalization into the child block, and make sure errors are passed back to the parent. Fix-proposed-by: Alexandre Marangone <alexandre.maragone@inktank.com> Signed-off-by: Sage Weil <sage@inktank.com>
* debian: update postinst, prerm hooksSage Weil2013-06-216-4/+114
| | | | | | | | This syncs up the hooks with the latest master versions. In particular, do not blindly stop/restart daemons on package upgrade! Fixes: #5414 Signed-off-by: Sage Weil <sage@inktank.com>
* os/FileStore: use fdatasync(2) instead of sync_file_range(2)Sage Weil2013-06-191-8/+2
| | | | | | | | | This fixes data corruption on XFS. Backported from ffade3c85dfffa13a16edd9630a52d99eb8a413d. Fixes: #4976 Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* chmod +x iogen.shSage Weil2013-06-171-0/+0
| | | | Signed-off-by: Sage Weil <sage@inktank.com>
* rgw: escape prefix correctly when listing objectsYehuda Sadeh2013-06-171-2/+6
| | | | | | | | | | | Fixes: #5362 When listing objects prefix needs to be escaped correctly (the same as with the marker). Otherwise listing objects with prefix that starts with underscore doesn't work. Backport: bobtail, cuttlefish Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
* rgw: translate object marker to raw formatYehuda Sadeh2013-06-171-12/+5
| | | | | | | | | Fixes: #4600 Object marker should be treated as an object, so that name is formatted correctly when getting the raw oid. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> (cherry picked from commit b083dece36a050ec15ac41a275aeef0ece1ac009)
* adding iogen.shtamil2013-06-131-0/+18
| | | | Signed-off-by: tamil <tamil.muthamizhan@inktank.com>
* osd: do not include logbl in scrub mapSage Weil2013-06-073-14/+6
| | | | | | | | | | | | | | | This is a potentially use object/file, usually prefixed by a zeroed region on disk, that is not used by scrub at all. It dates back to f51348dc8bdd5071b7baaf3f0e4d2e0496618f08 (2008) and the original version of scrub. This *might* fix #4179. It is not a leak per se, but I observed 1GB scrub messages going over the write. Maybe the allocations are causing fragmentation, or the sub_op queues are growing. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com> (cherry picked from commit 0b036ecddbfd82e651666326d6f16b3c000ade18)
* rgw: handle deep uri resourcesYehuda Sadeh2013-06-071-0/+25
| | | | | | | | | | | | In case of deep uri resources (ones created beyond a single level of hierarchy, e.g. auth/v1.0) we want to create a new empty handlers for the path if no handlers exists. E.g., for auth/v1.0 we need to have a handler for 'auth', otherwise the default S3 handler will be used, which we don't want. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com> (cherry picked from commit ad3934e335399f7844e45fcfd17f7802800d2cb3)
* rgw: fix get_resource_mgr() to correctly identify resourceYehuda Sadeh2013-06-071-2/+2
| | | | | | | | | | | Fixes: #5262 The original test was not comparing the correct string, ended up with the effect of just checking the substring of the uri to match the resource. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com> (cherry picked from commit 8d55b87f95d59dbfcfd0799c4601ca37ebb025f5)
* PG: don't write out pg map epoch every handle_activate_mapSamuel Just2013-06-063-2/+18
| | | | | | | | | | | | | | | | | We don't actually need to write out the pg map epoch on every activate_map as long as: a) the osd does not trim past the oldest pg map persisted b) the pg does update the persisted map epoch from time to time. To that end, we now keep a reference to the last map persisted. The OSD already does not trim past the oldest live OSDMapRef. Second, handle_activate_map will trim if the difference between the current map and the last_persisted_map is large enough. Fixes: #4731 Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com>
* rgw: only append prefetched data if reading from headYehuda Sadeh2013-05-311-17/+17
| | | | | | | | | | | | Fixes: #5209 Backport: bobtail, cuttlefish If the head object wrongfully contains data, but according to the manifest we don't read from the head, we shouldn't copy the prefetched data. Also fix the length calculation for that data. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com> (cherry picked from commit c5fc52ae0fc851444226abd54a202af227d7cf17)
* rgw: don't copy object idtag when copying objectYehuda Sadeh2013-05-311-0/+1
| | | | | | | | | | | | Fixes: #5204 When copying object we ended up also copying the original object idtag which overrode the newly generated one. When refcount put is called with the wrong idtag the count does't go down. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com> (cherry picked from commit b1312f94edc016e604f1d05ccfe2c788677f51d1)
* osd: initialize new_state field when we use itSage Weil2013-05-291-1/+4
| | | | | | | | | | | If we use operator[] on a new int field its value is undefined; avoid reading it or using |= et al until we initialize it. Fixes: #4967 Backport: cuttlefish, bobtail Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: David Zafman <david.zafman@inktank.com> (cherry picked from commit 50ac8917f175d1b107c18ecb025af1a7b103d634)
* HashIndex: sync top directory during start_split,merge,col_splitSamuel Just2013-05-281-3/+12
| | | | | | | | | | | | Otherwise, the links might be ordered after the in progress operation tag write. We need the in progress operation tag to correctly recover from an interrupted merge, split, or col_split. Fixes: #5180 Backport: cuttlefish, bobtail Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com> (cherry picked from commit 5bca9c38ef5187c7a97916970a7fa73b342755ac)
* Merge remote-tracking branch 'upstream/wip_scrub_tphandle_bobtail' into bobtailSamuel Just2013-05-234-33/+66
|\ | | | | | | | | Fixes: #5159 Reviewed-by: Sage Weil <sage@inktank.com>
| * PG: ping tphandle during omap loop as wellSamuel Just2013-05-232-0/+8
| | | | | | | | Signed-off-by: Samuel Just <sam.just@inktank.com>
| * PG: reset timeout in _scan_list for each object, read chunkSamuel Just2013-05-231-0/+2
| | | | | | | | Signed-off-by: Samuel Just <sam.just@inktank.com>
| * OSD,PG: pass tphandle down to _scan_listSamuel Just2013-05-233-33/+56
| | | | | | | | Signed-off-by: Samuel Just <sam.just@inktank.com>
* | rgw: iterate usage entries from correct entryYehuda Sadeh2013-05-231-3/+16
|/ | | | | | | | | | | | | | Fixes: #5152 When iterating through usage entries, and when user id was provided, we started at the user's first entry and not from the entry indexed by the request start time. This commit fixes the issue. Backport: bobtail Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com> (cherry picked from commit 8b3a04dec8be13559716667d4b16cde9e9543feb)
* mon: be a bit more verbose about osd mark down eventsSage Weil2013-05-221-0/+1
| | | | | | | | Put these in the cluster log; they are interesting. This is a backport of 87767fb1fb9a52d11b11f0b641cebbd9998f089e. Signed-off-by: Sage Weil <sage@inktank.com>
* rgw: protect ops log socket formatterYehuda Sadeh2013-05-212-1/+4
| | | | | | | | | Fixes: #4905 Ops log (through the unix domain socket) uses a formatter, which wasn't protected. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> (cherry picked from commit d48f1edb07a4d8727ac956f70e663c1b4e33e1dd)
* librbd: make image creation defaults configurableJosh Durgin2013-05-165-8/+142
| | | | | | | | | | | | | | | Programs using older versions of the image creation functions can't set newer parameters like image format and fancier striping. Setting these options lets them use all the new functionality without being patched and recompiled to use e.g. rbd_create3(). This is particularly useful for things like qemu-img, which does not know how to create format 2 images yet. Refs: #5067 backport: cuttlefish, bobtail Signed-off-by: Josh Durgin <josh.durgin@inktank.com> (cherry picked from commit aacc9adc4e9ca90bbe73ac153cc754a3a5b2c0a1)
* rbd.py: fix stripe_unit() and stripe_count()Josh Durgin2013-05-161-0/+20
| | | | | | | | | These matched older versions of the functions, but would segfault using the current versions. backport: cuttlefish, bobtail Signed-off-by: Josh Durgin <josh.durgin@inktank.com> (cherry picked from commit 53ee6f965e8f06c7256848210ad3c4f89d0cb5a0)
* cls_rbd: make sure stripe_unit is not larger than object sizeJosh Durgin2013-05-162-2/+12
| | | | | | | | Test a few other cases too. backport: cuttlefish, bobtail Signed-off-by: Josh Durgin <josh.durgin@inktank.com> (cherry picked from commit 810306a2a76eec1c232fd28ec9c351e827fa3031)
* mon: fix validatation of mds ids in mon commandsSage Weil2013-05-142-14/+40
| | | | | | | | | | Fixes: #4996 Signed-off-by: Sage Weil <sage@inktank.com> (cherry picked from commit 5c305d63043762027323052b4bb3ae3063665c6f) Conflicts: src/mon/MDSMonitor.cc
* v0.56.6v0.56.6Gary Lowell2013-05-032-1/+7
|
* ceph.spec.in: Fix platform dependeciesGary Lowell2013-05-031-5/+0
| | | | | | Picked up an incorrect dependency merging the rbd udev rules update. Signed-off-by: Gary Lowell <gary.lowell@inktank.com>
* rgw: don't send tail to gc if copying object to itselfYehuda Sadeh2013-05-032-2/+6
| | | | | | | | | | | Fixes: #4776 Backport: bobtail Need to make sure that when copying an object into itself we don't send the tail to the garbage collection. Signed-off-by: Yehuda Sadeh <yehuda@inktank.com> Reviewed-by: Greg Farnum <greg@inktank.com> (cherry picked from commit de5d1da810732ee48f41e8be18257053d862301b)
* ceph_common.sh: re-sync get_name_list with masterSage Weil2013-05-031-9/+9
| | | | | | We backported various items but didn't catch all the changes! :( Signed-off-by: Sage Weil <sage@inktank.com>
* v0.56.5v0.56.5Gary Lowell2013-05-022-1/+7
|
* ceph.spec.in: fix udev rules.d files handlingDanny Al-Gaaf2013-05-021-2/+5
| | | | | | | | Move 50-rbd.rules into the ceph base package since the related ceph-rbdnamer binary is part of this package. Use correct install pattern. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
* debian: only start/stop upstart jobs if upstart is presentSage Weil2013-05-024-3/+45
| | | | | | | | | | This avoids errors on non-upstart distros (like wheezy). Signed-off-by: Sage Weil <sage@inktank.com> (cherry picked from commit 030bf8aaa15837f898e453161eeaf1d52fc5779d) Conflicts: debian/ceph-mds.postinst
* debian: stop ceph-mds before uninstalling ceph-mdsSage Weil2013-05-021-0/+5
| | | | | | Fixes: #4384 Signed-off-by: Sage Weil <sage@inktank.com> (cherry picked from commit 9eb0d91b867ab980135d7c6ff6347d69d0a8a794)
* Makefile.am: Add -lpthread to fix build on newer ld in Raring RingtailDan Mick2013-05-011-4/+4
| | | | | | | | | Signed-off-by: Dan Mick <dan.mick@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com> (cherry picked from commit 98f532e8000af281fa03b24da9ad2fda81755270) Conflicts: src/Makefile.am
* Merge remote-tracking branch 'gh/bobtail-deploy' into bobtail-nextSage Weil2013-05-0117-1144/+2056
|\
| * Fix journal partition creationAlexandre Marangone2013-04-291-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With OSD sharing data and journal, the previous code created the journal partiton from the end of the device. A uint32_t is used in sgdisk to get the last sector, with large HD, uint32_t is too small. The journal partition will be created backwards from the a sector in the midlle of the disk leaving space before and after it. The data partition will use whichever of these spaces is greater. The remaining will not be used. This patch creates the journal partition from the start as a workaround. Signed-off-by: Alexandre Marangone <alexandre.marangone@inktank.com> (cherry picked from commit 56619ab91732bd2eacbef388311954f4e0230a30)
| * ceph.spec.in: put ceph-disk-* et al in correct sbindirSage Weil2013-04-261-4/+4
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
| * debian: fix ceph.installSage Weil2013-04-261-4/+4
| | | | | | | | | | | | This got out of sync somewhere in cherry-picking all of these patches. Signed-off-by: Sage Weil <sage@inktank.com>
| * Makefile.am: install ceph-* python scripts to /usr/bin directlyDanny Al-Gaaf2013-04-261-2/+7
| | | | | | | | | | | | | | | | | | Install ceph-* scripts directly to $(prefix)$(sbindir) (which normaly would be /usr/sbin) instead of moving it around after installation in SPEC file or debian files. Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de> (cherry picked from commit 4d16f38f48e276497190c8bc03abc55c40e18eed)
| * ceph-disk: CalledProcessError has no output keyword on 2.6Gary Lowell2013-04-261-2/+4
| | | | | | | | | | Signed-off-by: Gary Lowell <gary.lowell@inktank.com> (cherry picked from commit a793853850ee135de14b9237f7023cadcdb8575c)
| * ceph-disk: fix some (local) variable namesDanny Al-Gaaf2013-04-261-36/+37
| | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de> (cherry picked from commit c4eb7e6ddd593cd45ab8343da01355be7382723e)
| * ceph-disk: fix naming of local variable in is_mounted()Danny Al-Gaaf2013-04-261-4/+4
| | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de> (cherry picked from commit 3dd8b461219e64bb0f7a210dba5a9ab7c644f014)
| * ceph-disk: merge twice defined function is_mounted(dev)Danny Al-Gaaf2013-04-261-21/+11
| | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de> (cherry picked from commit eaf31bf9f90ba9709a57a6870dbafa21142dae2c)
| * ceph-disk: define exception typeDanny Al-Gaaf2013-04-261-2/+2
| | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de> (cherry picked from commit 4c6d6442a89adc5b56e99cb4d2ed572f2ad192c9)
| * ceph-disk: fix Redefining name 'uuid' from outer scopeDanny Al-Gaaf2013-04-261-6/+6
| | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de> (cherry picked from commit 058eb923c5b7dab611901fdd1724ce2a7c180827)
| * ceph-disk: add missing space after commaDanny Al-Gaaf2013-04-261-2/+2
| | | | | | | | | | Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de> (cherry picked from commit 0080d1df7c7950e051840a543fc4bdabe6cc53e5)
| * ceph-disk list: say 'unknown cluster $UUID' when cluster is unknownSage Weil2013-04-261-0/+2
| | | | | | | | | | | | | | This makes it clearer that an old osd is in fact old. Signed-off-by: Sage Weil <sage@inktank.com> (cherry picked from commit e9b3f2e6e93426d631d4f8101fb431a523b0d88a)
| * ceph-disk: handle missing journal_uuid field gracefullySage Weil2013-04-261-5/+7
| | | | | | | | | | | | | | Only lower if we know it's not None. Signed-off-by: Sage Weil <sage@inktank.com> (cherry picked from commit 562e1716bd4b5372716e502a5e4dd872d381bfb7)