summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* test/librados/cmd.cc: tolerate thrashing on pg_command testswip-6122Sage Weil2013-08-261-3/+6
| | | | | | | | We may get ENXIO (osd down) or ENOENT (pg dne (yet) on the target osd) if there is thrashing going on. Fixes: #6122 Signed-off-by: Sage Weil <sage@inktank.com>
* rados-config: do not load ceph.confSage Weil2013-08-231-1/+2
| | | | | | Fixes: #2901 Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* osd/ReplicatedPG: require write payload match lengthSage Weil2013-08-231-8/+4
| | | | | | | | Hopefully this won't break old clients; I can't think of any. We *should* be picky about our requests. Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* osd/ReplicatedPG: verify we have enough data for WRITE and WRITEFULLSage Weil2013-08-231-0/+8
| | | | | | Fixes: #2207 Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* ReplicatedPG: mark stats invalid when marking unfound lostSamuel Just2013-08-231-2/+5
| | | | | | Fixes: #3660 Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* ReplicatedPG: make watch timeout configurableSamuel Just2013-08-232-2/+2
| | | | | | Fixes: #2354 Signed-off-by: Samuel Just <sam.just@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* osd/OSDCap: allow . for unquoted stringsSage Weil2013-08-232-1/+2
| | | | | Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* mon/MonCap: allow . in unquoted stringSage Weil2013-08-232-1/+2
| | | | | | Fixes: #5967 Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* librados: make safe and complete callback arguments separateSage Weil2013-08-231-9/+13
| | | | | | Fixes: #2914 Signed-off-by: Sage Weil <sage@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* mds: remove waiting lock before merging with neighboursDavid Disseldorp2013-08-231-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CephFS currently deadlocks under CTDB's ping_pong POSIX locking test when run concurrently on multiple nodes. The deadlock is caused by failed removal of a waiting_locks entry when the waiting lock is merged with an existing lock, e.g: Initial MDS state (two clients, same file): held_locks -- start: 0, length: 1, client: 4116, pid: 7899, type: 2 start: 2, length: 1, client: 4110, pid: 40767, type: 2 waiting_locks -- start: 1, length: 1, client: 4116, pid: 7899, type: 2 Waiting lock entry 4116@1:1 fires: handle_client_file_setlock: start: 1, length: 1, client: 4116, pid: 7899, type: 2 MDS state after lock is obtained: held_locks -- start: 0, length: 2, client: 4116, pid: 7899, type: 2 start: 2, length: 1, client: 4110, pid: 40767, type: 2 waiting_locks -- start: 1, length: 1, client: 4116, pid: 7899, type: 2 Note that the waiting 4116@1:1 lock entry is merged with the existing 4116@0:1 held lock to become a 4116@0:2 held lock. However, the now handled 4116@1:1 waiting_locks entry remains. When handling a lock request, the MDS calls adjust_locks() to merge the new lock with available neighbours. If the new lock is merged, then the waiting_locks entry is not located in the subsequent remove_waiting() call because adjust_locks changed the new lock to include the old locks. This fix ensures that the waiting_locks entry is removed prior to modification during merge. Signed-off-by: David Disseldorp <ddiss@suse.de> Reviewed-by: Greg Farnum <greg@inktank.com>
* doc: Fixed broken link by adding Transitioning to ceph-deploy to this doc.John Wilkins2013-08-231-13/+44
| | | | | | fixes: 6107 Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* Merge pull request #495 from kri5/wip-5820Yehuda Sadeh2013-08-231-0/+3
|\ | | | | | | | | rgw: rgw-admin throw an error when invalid flag is passed Reviewed-by: Yehuda Sadeh <yehuda@inktank.com>
| * rgw: rgw-admin throw an error when invalid flag is passedChristophe Courtaut2013-08-131-0/+3
| | | | | | | | | | | | fix #5820 http://tracker.ceph.com/issues/5820 Signed-off-by: Christophe Courtaut <christophe.courtaut@gmail.com>
* | Merge pull request #533 from ceph/wip-osd-healthy-tuanbleSage Weil2013-08-232-1/+6
|\ \ | | | | | | | | | | | | osd: add 'osd heartbeat min healthy ratio' tunable Reviewed-by: Samuel Just <sam.just@inktank.com>
| * | osd: add 'osd heartbeat min healthy ratio' tunableSage Weil2013-08-222-1/+6
| | | | | | | | | | | | | | | | | | This was hard-coded to 1/3; make it tunable. Signed-off-by: Sage Weil <sage@inktank.com>
* | | doc/release-notes: v0.67.2Sage Weil2013-08-232-0/+231
| | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | | Merge pull request #528 from kri5/wip-radosgw-admin-helpYehuda Sadeh2013-08-232-0/+2
|\ \ \ | | | | | | | | | | | | | | | | rgw: Adds --system option help to radosgw-admin Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
| * | | rgw: Adds --system option help to radosgw-adminChristophe Courtaut2013-08-232-0/+2
| | | | | | | | | | | | | | | | Signed-off-by: Christophe Courtaut <christophe.courtaut@gmail.com>
* | | | QA: Compile fsstress if missing on machine.Sandon Van Ness2013-08-221-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some distro's have a lack of ltp-kernel packages and all we need is fstress. This just modified the shell script to download/compile fstress from source and copy it to the right location if it doesn't currently exist where it is expected. It is a very small/quick compile and currently only SLES and debian do not have it already. Reviewed-by: Sage Weil <sage@inktank.com> Signed-off-by: Sandon Van Ness <sandon@inktank.com>
* | | | init-ceph: behave if incompletely installedSage Weil2013-08-221-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | e.g., Debian 'removed, config remains' state Fixes: #5695 Signed-off-by: Sage Weil <sage@inktank.com>
* | | | Merge remote-tracking branch 'gh/next'Sage Weil2013-08-224-21/+29
|\ \ \ \
| * | | | rgw: fix crash when creating new zone on initYehuda Sadeh2013-08-221-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Moving the watch/notify init before the zone init, as we might need to send a notification. Reviewed-by: Sage Weil <sage@inktank.com> Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
| * | | | enable mds rejoin with active inodes' old parent xattrsAlexandre Oliva2013-08-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the parent xattrs of active inodes that the mds attempts to open during rejoin lack pool info (struct_v < 5), this field will be filled in with -1, causing the mds to retry fetching a backtrace with a pool number that matches the expected value, which fails and causes the err==-ENOENT branch to be taken and retry pool 1, which succeeds, but with pool -1, and so keeps on bouncing between the two retry cases forever. This patch arranges for the mds to go along with pool -1 instead of insisting that it be refetched, enabling it to complete recovery instead of eating cpu, network bandwidth and metadata osd's resources like there's no tomorrow, in what AFAICT is an infinite and very busy loop. This is not a new problem: I've had it even before upgrading from Cuttlefish to Dumpling, I'd just never managed to track it down, and force-unmounting the filesystem and then restarting the mds was an easier (if inconvenient) work-around, particularly because it always hit when the filesystem was under active, heavy-ish use (or there wouldn't be much reason for caps recovery ;-) There are two issues not addressed in this patch, however. One is that nothing seems to proactively update the parent xattr when it is found to be outdated, so it remains out of date forever. Not even renaming top-level directories causes the xattrs to be recursively rewritten. AFAICT that's a bug. The other is that inodes that don't have a parent xattr (created by even older versions of ceph) are reported as non-existing in the mds rejoin message, because the absence of the parent xattr is signaled as a missing inode (?failed to reconnect caps for missing inodes?). I suppose this may cause more serious recovery problems. I suppose a global pass over the filesystem tree updating parent xattrs that are out-of-date would be desirable, if we find any parent xattrs still lacking current information; it might make sense to activate it as a background thread from the backtrace decoding function, when it finds a parent xattr that's too out-of-date, or as a separate client (ceph-fsck?). Backport: dumpling, cuttlefish Signed-off-by: Alexandre Oliva <oliva@gnu.org> Reviewed-by: Zheng, Yan <zheng.z.yan@intel.com>
| * | | | ceph-monstore-tool: shut up coveritySage Weil2013-08-211-0/+1
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
| * | | | store: fix issues reported by coverityYan, Zheng2013-08-212-12/+19
| | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com> Reviewed-by: Sage Weil <sage@inktank.com>
* | | | | yasm-wrapper: more futzing to behave on fedora 19Sage Weil2013-08-221-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some new arguments, and behave (return success) when the touch target isn't specified. Signed-off-by: Sage Weil <sage@inktank.com>
* | | | | ceph.spec.in: remove trailing paren in previous commitGary Lowell2013-08-221-1/+1
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Gary Lowell <gary.lowell@inktank.com>
* | | | | ceph.spec.in: Don't invoke debug_package macro on centos.Gary Lowell2013-08-221-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the redhat-rpm-config package is installed, the debuginfo rpms will be built by default. The build will fail when the package installed and the specfile also invokes the macro. Signed-off-by: Gary Lowell <gary.lowell@inktank.com>
* | | | | Merge pull request #414 from dachary/wip-5510athanatos2013-08-2210-291/+225
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | replace ObjectContext pointers with shared_ptr Reviewed-by: Samuel Just <sam.just@inktank.com>
| * | | | | ReplicatedPG: create ObjectContext with SharedPtrRegistryLoic Dachary2013-08-221-10/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | All new ObjectContext are replaced with calls to SharedPtrRegistry::lookup_or_create to ensure that they are all registered. Because the constructor is invoked with no argument, care is taken to always initialize the destructor_callback data member immediately afterwards. ReplicatedPG::get_object_context contains a redundant call to get_snapset_context that is removed. http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | ReplicatedPG: replace object_contexts.find with object_contexts.lookupLoic Dachary2013-08-221-12/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The std::map equivalent of find is SharedPtrRegistry::lookup http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | ReplicatedPG: add Context to cleanup the PG after an ObjectContext deletionLoic Dachary2013-08-222-1/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ReplicatedPG::C_PG_ObjectContext is added to encapsulate a call to ReplicatedPG::object_context_destructor_callback method which is reponsible for * manually de-allocating the SnapSetContext of the ObjectContext if any. It will eventually be managed by a SharedPtrRegistry. ReplicatedPG::C_PG_ObjectContext must be added to the destructor_callback member of ObjectContext immediately after it is created. http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | ReplicatedPG: replace map iterators with SharedPtrRegistry::get_nextLoic Dachary2013-08-221-26/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SharedPtrRegistry does not provide an iterator equivalent to map<hobject_t, ObjectContext*>::iterator i It is replaced with a thread safe get_next method roughly used as follows: pair<hobject_t, ObjectContextRef> i; while (object_contexts.get_next(i.first, &i)) All occurences of the iterator are replaced with get_next style traversal. http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | ReplicatedPG: remove lookup_object_context methodLoic Dachary2013-08-222-18/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Both ReplicatedPG::lookup_object_context and ReplicatedPG::_lookup_object_context methods are provided by SharedPtrRegistry. http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | ReplicatedPG: remove reference counting logicLoic Dachary2013-08-222-93/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ObjectContext manual reference counting and managing the object_contexts object involves calls to * obc->ref++ and obc->get() * put_object_context and put_object_contexts * register_object_context * assertions on obc->registered They are all removed because SharedPtrRegistry provides the same service. http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | ReplicatedPG: ObjectContext * becomes ObjectContextRefLoic Dachary2013-08-224-99/+98
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The map of hobject_t to ObjectContext is made a SharedPtrRegistry owned by ReplicatedPG - map<hobject_t, ObjectContext*> object_contexts; + SharedPtrRegistry<hobject_t, ObjectContext> object_contexts; All ObjectContext pointers are changed into ObjectContextRef, i.e. shared_ptr. In Watch.h std::tr1::shared_ptr<ObjectContext> is used instead of ObjectContextRef because Watch.h is included before it is defined. http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | ReplicatedPG: ObjectContext is made compatible with SharedPtrRegistryLoic Dachary2013-08-222-16/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When creating a new object SharedPtrRegistry::lookup_or_create uses the default ObjectContext constructor with no argument. The existing ObjectContext constructor is modified to have no argument and the initialization that was previously done within the constructor is done by the caller (that only happens three times). The ObjectContext::get method is removed: its only purpose is to increment the ref. The ObjectContext::registered data member is removed as well as all the associated assert() The ObjectContext::destructor_callback data member Context is added and called by the destructor. It will allow the caller to perform additional cleanup, if necessary. All ObjectContext * data members are replaced with shared_ptr. http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | ReplicatedPG: add Mutex to protect snapset_contextsLoic Dachary2013-08-222-4/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | snapset_contexts_locks is added and locked in each function where snapset_contexts or the SnapSetContext::ref data member needs to be accessed or modified. http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | PG: remove unused PG::_condLoic Dachary2013-08-224-16/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | http://tracker.ceph.com/issues/5510 refs #5510 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | | | sharedptr_registry: add a variant of get_next() and the empty() methodLoic Dachary2013-08-221-0/+20
| | |_|/ / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The SharedPtrRegistry::get_next() method with a value of type VPtr instead of V is added because it is sometime more convenient to not copy the value when walking the registry. The SharedPtrRegistry::empty() predicate method is added. Signed-off-by: Loic Dachary <loic@dachary.org>
* | | | | Merge pull request #527 from ceph/wip-mon-fix-verbose-outputSage Weil2013-08-221-1/+0
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | mon: remove lingering debug output Reviewed-by: Sage Weil <sage@inktank.com>
| * | | | | mon: Monitor: remove lingering debug message from f087d84bJoao Eduardo Luis2013-08-221-1/+0
| | |_|/ / | |/| | | | | | | | | | | | | Signed-off-by: Joao Eduardo Luis <jecluis@gmail.com>
* | | | | Merge pull request #520 from ceph/wip-crcSage Weil2013-08-2224-150/+1140
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | This is better, faster intel optimized code. Reviewed-by: Yehuda Sadeh <yehuda.sadeh@inktank.com>
| * | | | | Makefile: move all crc code into libcrc.laSage Weil2013-08-221-22/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is simpler. Signed-off-by: Sage Weil <sage@inktank.com>
| * | | | | crc32c: add intel optimized crc32c implementationSage Weil2013-08-226-1/+763
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is from Intel's ISA-L library and licensed under BSD 3-clause. It needs to build with yasm, which means we go through all sorts of pain to make this work with libtool: - strip out args it doesn't understand with yasm-wrapper - detect whether it is recent enough during configure The code is conditional on: - build-time support (yasm) - run-time support (sse4.2) Signed-off-by: Sage Weil <sage@inktank.com>
| * | | | | arch: add cpu probingSage Weil2013-08-225-0/+102
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For now, just a check to see if we have SSE4.2. Signed-off-by: Sage Weil <sage@inktank.com>
| * | | | | yasm-wrapper: hide libtool insanity from yasmSage Weil2013-08-222-1/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | libtool passes all kinds of crap to yasm that yasm does not understand. Hide it with this ugly wrapper. Sigh. Signed-off-by: Sage Weil <sage@inktank.com>
| * | | | | build-depend on yasmSage Weil2013-08-212-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
| * | | | | crc32c: note intel crc code copyrightsSage Weil2013-08-212-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's a BSD 3-clause. Signed-off-by: Sage Weil <sage@inktank.com>
| * | | | | crc32c: add intel baseline algorithmSage Weil2013-08-214-2/+148
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is than the sctp code but probably slower. We'll add it anywhere just as a reference and to have a baseline for comparing performance. Signed-off-by: Sage Weil <sage@inktank.com>