summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* make: add tmalloc lib dep in tcmalloc guardfix-no-tcmalloc-buildNoah Watkins2013-09-131-1/+1
| | | | | | Fixes --without-tcmalloc on boxes without libtcmalloc. Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
* Merge branch 'wip-6226'David Zafman2013-09-122-1/+8
|\
| * osd/ReplicatedPG.cc: Verify that recovery is truly completeDavid Zafman2013-09-121-0/+7
| | | | | | | | | | | | | | | | | | | | | | Backportable change to insure that even if no new ops started or are running that indeed recovery is complete. Prevents some error condition or unforseen code path from crashing an osd. Backport: dumpling, cuttlefish Signed-off-by: David Zafman <david.zafman@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
| * osd/OSD.cc: Use MIN() so that we don't exceed osd_recovery_max_activeDavid Zafman2013-09-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | Caused by 944f3b73531af791c90f0f061280160003545c63 Fixes: #6291 Backport: dumpling Signed-off-by: David Zafman <david.zafman@inktank.com> Reviewed-by: Samuel Just <sam.just@inktank.com>
* | Merge pull request #589 from ceph/wip-6279Gregory Farnum2013-09-121-0/+1
|\ \ | |/ |/| | | mon/MDSMonitor: don't reset incarnation when creating newfs Reviewed-by: Greg Farnum <greg@inktank.com>
| * mon/MDSMonitor: don't reset incarnation when creating newfsYan, Zheng2013-09-121-0/+1
|/ | | | | | Fixes: #6279 Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
* Merge pull request #587 from kri5/masterYehuda Sadeh2013-09-112-0/+2
|\ | | | | | | | | rgw-admin: Adds --metadata-key option to help Reviwed-by: Yehuda Sadeh <yehuda@inktank.com>
| * rgw-admin: Adds --metadata-key option to helpChristophe Courtaut2013-09-112-0/+2
|/ | | | Signed-off-by: Christophe Courtaut <christophe.courtaut@gmail.com>
* osd: bind objecter messenger to cluster addressGreg Farnum2013-09-101-0/+2
| | | | | | | | We don't want it binding to whatever willy-nilly, and as an OSD even its "client" traffic should go on the cluster address. Signed-off-by: Greg Farnum <greg@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* osd: name the objecter's messenger "ms_objecter" instead of "hbclient"Greg Farnum2013-09-101-1/+1
| | | | | | | Bad copypasta on initial create? Signed-off-by: Greg Farnum <greg@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* Objecter: rename cancel_op -> cancel_linger_opGreg Farnum2013-09-102-7/+5
| | | | | | | | This makes it possible to converse about op_cancel and cancel_linger_op without getting too confused. Signed-off-by: Greg Farnum <greg@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* Merge pull request #580 from ceph/wip-6033-redirectsGregory Farnum2013-09-109-51/+228
|\ | | | | Reviewed-by: Sage Weil <sage@inktank.com>
| * test: update cache test since OSDs support redirectsGreg Farnum2013-09-101-12/+12
| | | | | | | | Signed-off-by: Greg Farnum <greg@inktank.com>
| * osd: implement basic caching policies in ReplicatedPGGreg Farnum2013-09-102-17/+72
| | | | | | | | | | | | | | | | Right now these are very basic and aren't as sophisticated as we want them to end up, but we have a skeleton for where to put the decision-making logic. Signed-off-by: Greg Farnum <greg@inktank.com>
| * Objecter: follow redirect replies from the OSDGreg Farnum2013-09-101-8/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | If we get back a redirect reply, we clean up the Op's external references and re-send using the target_oloc and target_oid. To facilitate this, recalc_op_target() now only fills them in and overrides them with pool cache semantics if they're empty. Keep in mind that this is a pretty simple redirect formula -- the Objecter will keep following redirects forever if that's what the OSDs send back. The client is not providing any synchronization right now. Signed-off-by: Greg Farnum <greg@inktank.com>
| * Objecter: write a helper function to clean up ops that need to be retriedGreg Farnum2013-09-102-4/+11
| | | | | | | | | | | | | | | | We have a little block to clean them up if we get back EAGAIN, but it's actually leaking map references; we will also use this for redirects from the OSDs. Signed-off-by: Greg Farnum <greg@inktank.com>
| * MOSDOpReply: add a redirect memberGreg Farnum2013-09-101-1/+13
| | | | | | | | | | | | | | | | | | | | | | When present, clients must send the request to the location specified by the redirect (by using the combine_with_locator() function on request_redirect_t). A separate mechanism must be used to ensure that clients see and respect the redirect, as we do not bump up the minimum required version to decode. Signed-off-by: Greg Farnum <greg@inktank.com>
| * Objecter: add an Op::target_oid, and use it when submitting OpsGreg Farnum2013-09-102-2/+5
| | | | | | | | | | | | | | For now it's just a copy of base_oid, but soon we will allow it to be overwritten for OSD-driven redirects. Signed-off-by: Greg Farnum <greg@inktank.com>
| * Objecter: rename Op::oid -> Op::base_oidGreg Farnum2013-09-102-8/+8
| | | | | | | | | | | | | | | | | | Analagous to the oloc->base_oloc rename we did in e2fcad09d94d965867147627b73e99da9454436f, we may specify a different target name for a redirect. Rename the existing oid to base_oid to avoid any confusion. Signed-off-by: Greg Farnum <greg@inktank.com>
| * osd: create a new request_redirect_tGreg Farnum2013-09-103-0/+77
| | | | | | | | | | | | | | We'll use this so that the OSD can tell the Objecter to redirect a request to a different object somewhere else. Signed-off-by: Greg Farnum <greg@inktank.com>
| * osd: add empty() function to object_locator_tGreg Farnum2013-09-091-0/+4
| | | | | | | | Signed-off-by: Greg Farnum <greg@inktank.com>
| * MOSDOpReply: more const-correctnessGreg Farnum2013-09-091-1/+1
| | | | | | | | | | | | get_map_epoch() is a non-reference getter -- mark it as const! Signed-off-by: Greg Farnum <greg@inktank.com>
| * ReplicatedPG: do not meaninglessly fill in the reqid on make_writeable() cloningGreg Farnum2013-09-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This reqid is used to fill in a map that is used for giving clients the correct version on replayed ops, unless the reqid is blank (in which case it doesn't go into the map). Indirect clones are not ops that the client wants to observe and the version is incorrect right now, so don't fill it in. Note that this should not have actually caused any buggy behavior, because the map would have simply been overwritten by the real requested event a short time later (while still protected by locks and things). But it's very confusing. Signed-off-by: Greg Farnum <greg@inktank.com>
* | Merge pull request #585 from ceph/wip-osd-pool-create-syntaxSage Weil2013-09-101-1/+1
|\ \ | | | | | | | | | | | | fix ceph tool (syntax error in command specification prevents anything from working) Reviewed-by: Sage Weil <sage@inktank.com>
| * | mon: fix syntax error in osd pool create argsJosh Durgin2013-09-101-1/+1
|/ / | | | | | | | | | | Just missing a space between pgp_num and properties specification. Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
* | Merge pull request #584 from dachary/masterSage Weil2013-09-101-2/+2
|\ \ | | | | | | | | | | | | autoconf: use $(UNITTEST_CXXFLAGS) in tests Reviewed-by: Sage Weil <sage@inktank.com>
| * | autoconf: use $(UNITTEST_CXXFLAGS) in testsLoic Dachary2013-09-101-2/+2
| | | | | | | | | | | | | | | | | | | | | As suggested by Roald van Loon https://github.com/ceph/ceph/pull/538/files#r6260751 Signed-off-by: Loic Dachary <loic@dachary.org>
* | | Merge pull request #578 from dachary/wip-6113Sage Weil2013-09-105-7/+43
|\ \ \ | |/ / |/| | | | | | | | mon: add key[=value] ... to osd pool create Reviewed-by: Sage Weil <sage@inktank.com>
| * | mon: add key[=value] ... to osd pool createLoic Dachary2013-09-105-7/+43
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With the introduction of the erasure code pool, arguments to be interpreted depending on the pool type must be introduced. For instance the erasure code pool loads a plugin at run time will use easure-code-k=10 to split each object in 10. The arguments are described as name=properties,type=CephString,n=N,req=false,goodchars=[A-Za-z0-9-_.=] If key=value it is stored in the new properties data member of pg_pool_t as properties[key] = value, otherwise the value is the empty string. The pg_pool_t version is bumped to 10 and the encode/decode methods modified to take the properties into account. The generate_test_instances method creates a two entries map, one of which is the empty string to cover the case when no value is specified. http://tracker.ceph.com/issues/6113 refs #6113 Signed-off-by: Loic Dachary <loic@dachary.org>
* | crushtool: do not dump core with non-unique bucket IDsDavid Zafman2013-09-098-17/+49
| | | | | | | | | | | | | | | | | | | | | | Return -EEXIST on duplicate ID BUG FIX: crush_add_bucket() mixes error returns and IDs Add optional argument to return generated ID Fixes: #6246 Signed-off-by: David Zafman <david.zafman@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
* | doc/release-notes: v0.67.3Sage Weil2013-09-092-0/+736
| | | | | | | | Signed-off-by: Sage Weil <sage@inktank.com>
* | Merge pull request #569 from ceph/wip-osd-statDan Mick2013-09-092-3/+19
|\ \ | | | | | | osd: expose bytes used/avail via perf / asok
| * | osd: expose bytes used/avail via perf / asokSage Weil2013-09-092-3/+19
| | | | | | | | | | | | | | | | | | | | | This values are already sent to the monitor. Expose them via the admin socket too so collectd/diamond/whatever can pick them up. Signed-off-by: Sage Weil <sage@inktank.com>
* | | Merge pull request #581 from dachary/masterSage Weil2013-09-091-2/+2
|\ \ \ | | | | | | | | | | | | | | | | autoconf: use $(LIBOSD) $(LIBCOMMON) instead of libosd.a libcommon.la Reviewed-by: Sage Weil <sage@inktank.com>
| * | | autoconf: use $(LIBOSD) $(LIBCOMMON) instead of libosd.a libcommon.laLoic Dachary2013-09-101-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | hardcoded library names in unit test dependencies break compilation Signed-off-by: Loic Dachary <loic@dachary.org>
* | | | doc: Syntax fix to suppress gitbuilder errors.John Wilkins2013-09-091-2/+2
| | | | | | | | | | | | | | | | Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* | | | doc: Removed mkcephfs reference.John Wilkins2013-09-096-7/+1
| | | | | | | | | | | | | | | | Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* | | | doc: Syntax fixes to suppress gitbuilder warnings.John Wilkins2013-09-091-0/+6
| | | | | | | | | | | | | | | | Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* | | | doc: Syntax fixes to suppress gitbuilder warnings.John Wilkins2013-09-091-1/+1
| | | | | | | | | | | | | | | | Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* | | | doc: Syntax fixes to suppress gitbuilder warnings.John Wilkins2013-09-091-15/+15
| | | | | | | | | | | | | | | | Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* | | | doc: Syntax fixes to suppress gitbuilder warnings.John Wilkins2013-09-091-27/+33
| | | | | | | | | | | | | | | | Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* | | | doc: Syntax fixes to suppress gitbuilder warnings.John Wilkins2013-09-091-5/+6
| | | | | | | | | | | | | | | | Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* | | | doc: Syntax fixes to suppress gitbuilder warnings.John Wilkins2013-09-091-36/+36
| | | | | | | | | | | | | | | | Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* | | | doc: Syntax fixes to remove gitbuilder errors.John Wilkins2013-09-091-123/+0
|/ / / | | | | | | | | | Signed-off-by: John Wilkins <john.wilkins@inktank.com>
* | | Merge pull request #518 from dachary/wip-5878athanatos2013-09-099-0/+788
|\ \ \ | | | | | | | | | | | | | | | | erasure plugin mechanism and abstract API Reviewed-by: Samuel Just <sam.just@inktank.com>
| * | | ErasureCodePlugin: plugin registry tests and exampleLoic Dachary2013-09-093-0/+101
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | libec_example.la is a fully functional plugin based on ErasureCodeExample to test the ErasureCodePlugin abstract interface. It is dynamically loaded to test the ErasureCodePluginRegistry implementation. Although the plugin is built in the test directory, it will be installed. noinst_LTLIBRARIES won't build the shared library, only the static version which is not suitable for testing. http://tracker.ceph.com/issues/5878 refs #5878 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | ErasureCodePlugin: plugin registryLoic Dachary2013-09-093-0/+166
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A ErasureCodePluginRegistry singleton holds all erasure plugin objects derived from ErasureCodePlugin and dlopen(2) handles for the lifetime of the OSD and is cleaned up by the destructor. The registry has a single entry point ( method factory ) and should be used as follows: map<std::string,std::string> parameters; parameters["directory"] = "/usr/lib/ceph/erasure-code"; ErasureCodeInterfaceRef erasure_code; ErasureCodePluginRegistry &instance = ErasureCodePluginRegistry::instance(); instance.factory("jerasure", parameters, &erasure_code)); If the plugin requested ( "jerasure" in the example above ) is not found in the *plugins* data member, the load method is called and will: * dlopen(parameters["erasure-code-directory"] + "jerasure") * f = dlsym("__erasure_code_init") * f("jerasure") * check that it registered "jerasure" The plugin is expected to do something like instance.add(plugin_name, new ErasureCodePluginJerasure()); to register itself. The factory method is protected with a Mutex to avoid race conditions when using the same plugin from two threads. The erasure_codelib_LTLIBRARIES variable is added to the Makefile and the plugins are expected to add themselves and be installed in the $(libdir)/erasure-code http://tracker.ceph.com/issues/5878 refs #5878 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | ErasureCodePlugin: plugin interfaceLoic Dachary2013-09-092-0/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When dynamically loaded, a plugin is expected to define int __erasure_code_init(char *plugin_name); When called, it is responsible for registering an ErasureCodePlugin derived object that provides a factory method from which the concrete implementation of the ErasureCodeInterface object can be generated: virtual int factory(const map<std::string,std::string> &parameters, ErasureCodeInterfaceRef *erasure_code) { *erasure_code = ErasureCodeInterfaceRef(new ErasureCodeExample(parameters)); return 0; } The plugin instance contains the library data member which is used to store the handle of the shared library. It is opaque to the plugin. http://tracker.ceph.com/issues/5878 refs #5878 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | ErasureCode: example implementation : K=2 M=1Loic Dachary2013-09-093-0/+267
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | An erasure code implementation designed for tests. Although it is fully functional and could be used on actual data, it is mainly provided for testing purposes. It splits data in two, computes an XOR parity and can sustain the loss of one chunk. The constructor will usleep(3) for parameters["usleep"] microseconds so that the caller can create race conditions. http://tracker.ceph.com/issues/5878 refs #5878 Signed-off-by: Loic Dachary <loic@dachary.org>
| * | | ErasureCode: abstract interfaceLoic Dachary2013-09-092-0/+211
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The erasure coded pool relies on this abstract interface to encode and decode the chunks stored in the OSD. It has been designed to be generic enough to accomodate the libraries and algorithms that are most likely to be used. It does not claim to be universal. http://tracker.ceph.com/issues/5878 refs #5878 Signed-off-by: Loic Dachary <loic@dachary.org>