]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
10 years agomds/RecoveryQueue: do not start prioritized items synchronously 2258/head
Sage Weil [Fri, 29 Aug 2014 15:29:35 +0000 (08:29 -0700)]
mds/RecoveryQueue: do not start prioritized items synchronously

When we prioritize an item move it into a second priority list/set, but
do not start immediately, so that we still obey the max.  When we go to
start an item, pull items first off the priority list, then off the regular
list.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomds/Locker: if a client asks for file caps, prioritize file recovery
Sage Weil [Thu, 14 Aug 2014 22:08:43 +0000 (15:08 -0700)]
mds/Locker: if a client asks for file caps, prioritize file recovery

This normally happens when a process opens the file.  Prioritize in that
case.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomds/Locker: prioritize file recovery on rd/wr/x lock
Sage Weil [Thu, 14 Aug 2014 22:06:47 +0000 (15:06 -0700)]
mds/Locker: prioritize file recovery on rd/wr/x lock

If someone specifically touches the file lock, prioritize recovery for this
file.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomds/RecoveryQueue: add method to prioritize a file recovery; fix logging
Sage Weil [Thu, 14 Aug 2014 21:52:40 +0000 (14:52 -0700)]
mds/RecoveryQueue: add method to prioritize a file recovery; fix logging

Add a prioritize() method to make file recovery start immediately for the
given inode.  Note that this doesn't respect the max recovery limit: if
someone stats it, they are blocking, and we start the recovery immediately.

Also fix up the dout logging a bit so that everything is prefixed
consistently.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomds: change mds_max_file_recover from 5 -> 32
Sage Weil [Thu, 14 Aug 2014 21:39:29 +0000 (14:39 -0700)]
mds: change mds_max_file_recover from 5 -> 32

These are reasonably cheap operations (stat) and we should be too worried
about queueing up a bunch of them.

Ideally this sort of thing would magically tune to the throughput we can
get from the cluster, but until then, let's choose a default that works for
more users.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomds: make max file recovers configurable
Sage Weil [Thu, 14 Aug 2014 21:38:08 +0000 (14:38 -0700)]
mds: make max file recovers configurable

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge branch 'wip-8639'
Sage Weil [Thu, 28 Aug 2014 17:59:40 +0000 (10:59 -0700)]
Merge branch 'wip-8639'

Reviewed-by: Joao Eduardo Luis <joao.luis@inktank.com>
10 years agotest/mon/*: prime mon with initial command before injection
Sage Weil [Thu, 28 Aug 2014 17:59:18 +0000 (10:59 -0700)]
test/mon/*: prime mon with initial command before injection

The osdmonitor_prepare_command is very fragile.  Send an initial command
to the mon beforehand.  This seems to prevent the initial command from
getting combined into an early mon proposal with some other stuff.

Alternatively, we could remove these tests and this mechanism entirely as
it is likely to great in the future when the next set of mon changes are
made, but they have shown themselves to be useful it catching other
regressions, so we'll patch them up for a bit longer.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #2344 from ceph/wip-8863
Samuel Just [Thu, 28 Aug 2014 17:34:10 +0000 (10:34 -0700)]
Merge pull request #2344 from ceph/wip-8863

osd/PG: fix crash from second backfill reservation rejection

Reviewed-by: Samuel Just <sam.just@inktank.com>
10 years agoMerge pull request #2297 from ceph/wip-9173
John Spray [Thu, 28 Aug 2014 16:20:20 +0000 (17:20 +0100)]
Merge pull request #2297 from ceph/wip-9173

Wip 9173

Reviewed-by: Greg Farnum <greg@inktank.com>
10 years agoMerge pull request #2299 from dachary/wip-jerasure-upgrade
Loic Dachary [Thu, 28 Aug 2014 16:10:12 +0000 (18:10 +0200)]
Merge pull request #2299 from dachary/wip-jerasure-upgrade

erasure-code: jerasure upgrade

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoerasure-code: assert the PluginRegistry lock is held when it must 2299/head
Loic Dachary [Sat, 23 Aug 2014 09:07:29 +0000 (11:07 +0200)]
erasure-code: assert the PluginRegistry lock is held when it must

Add lock to the preload method and assert that it is held by methods
requiring it. Although preload is called at bootstrap and does not
require the lock, adding it does not hurt and makes the lock policy
clearer to understand.

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: add Ceph version check to plugins
Loic Dachary [Thu, 21 Aug 2014 16:38:52 +0000 (18:38 +0200)]
erasure-code: add Ceph version check to plugins

Add the __erasure_code_version function to all plugins, to return the
Ceph version against which they have been compiled. When a plugin is
loaded, an error is thrown if the version of the plugin does not match
the version of the daemon loading it.

If the symbol does not exist, which will be true of older plugins, set
the version to "an older version" so it never matches.

http://tracker.ceph.com/issues/9167 Fixes: #9167

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: implement ErasureCodePluginRegistry::remove
Loic Dachary [Thu, 21 Aug 2014 16:37:14 +0000 (18:37 +0200)]
erasure-code: implement ErasureCodePluginRegistry::remove

Which is symmetric to the add method and used for test.

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: wrap lines for emacs compile command
Loic Dachary [Thu, 21 Aug 2014 16:35:52 +0000 (18:35 +0200)]
erasure-code: wrap lines for emacs compile command

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: jerasure preloads the plugin variant
Loic Dachary [Thu, 21 Aug 2014 16:31:02 +0000 (18:31 +0200)]
erasure-code: jerasure preloads the plugin variant

The variant selection depending on the available CPU features is
encapsulated in a helper. The helper is used in the factory() method and
in the load() method.

The factory() method may load a variant that is not the default, for
benchmark purposes. Such a variant is not preloaded by the load() method
and upgrading while running may be problematic. However, running with a
non standard variant is used for benchmarking and upgrades in this
context are not a concern.

http://tracker.ceph.com/issues/9153 Fixes: #9153

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: add Red Hat to copyright notices
Loic Dachary [Thu, 21 Aug 2014 16:28:30 +0000 (18:28 +0200)]
erasure-code: add Red Hat to copyright notices

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: remove unused errno.h include
Loic Dachary [Thu, 21 Aug 2014 16:27:06 +0000 (18:27 +0200)]
erasure-code: remove unused errno.h include

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: add directory to plugin init functions
Loic Dachary [Thu, 21 Aug 2014 16:22:18 +0000 (18:22 +0200)]
erasure-code: add directory to plugin init functions

The prototype of the init functions of erasure coded plugins is changed
from

   int __erasure_code_init(char *plugin_name)

to

   int __erasure_code_init(char *plugin_name, char *directory)

The jerasure plugin will find optimized variants in this directory and
load them. The load() and preload() functions of
ErasureCodePluginRegistry only use a directory instead of a more generic
parameters map. The parameters map was only used for the directory entry
anyway.

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoerasure-code: preload the isa plugin by default
Loic Dachary [Thu, 21 Aug 2014 13:19:22 +0000 (15:19 +0200)]
erasure-code: preload the isa plugin by default

But only do so when it has been compiled because a recent enough yasm
has been found.

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agodoc: Update docs about OSD benchmark syntax
Wido den Hollander [Thu, 28 Aug 2014 06:18:16 +0000 (08:18 +0200)]
doc: Update docs about OSD benchmark syntax

10 years agoRevert "doc: Update docs about OSD benchmark syntax"
Wido den Hollander [Thu, 28 Aug 2014 06:16:03 +0000 (08:16 +0200)]
Revert "doc: Update docs about OSD benchmark syntax"

This reverts commit 36f15c3026debd808920a04bc3a60c96b119405b.

Commit included submodule change which was not supposed to happen.

10 years agodoc: Update docs about OSD benchmark syntax
Wido den Hollander [Thu, 28 Aug 2014 06:12:30 +0000 (08:12 +0200)]
doc: Update docs about OSD benchmark syntax

10 years agoMerge pull request #2339 from leseb/sample-ceph-conf-addition
Sage Weil [Wed, 27 Aug 2014 21:43:33 +0000 (14:43 -0700)]
Merge pull request #2339 from leseb/sample-ceph-conf-addition

sample.ceph.conf: some updates

10 years agomon: flush paxos write on shutdown
Sage Weil [Mon, 25 Aug 2014 04:10:27 +0000 (21:10 -0700)]
mon: flush paxos write on shutdown

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/Paxos: WRITING != WRITING_PREVIOUS
Sage Weil [Mon, 25 Aug 2014 04:01:07 +0000 (21:01 -0700)]
mon/Paxos: WRITING != WRITING_PREVIOUS

This distinction is important: the update-previous state should not be
writeable, as reflected by PaxosService::is_writeable().

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon: _reset() before updating state
Sage Weil [Thu, 21 Aug 2014 23:18:01 +0000 (16:18 -0700)]
mon: _reset() before updating state

In _reset() we call Paxos::restart(), which waits for commit completion,
and assumes the state hasn't been twiddled yet.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon: flush before scrub
Sage Weil [Thu, 21 Aug 2014 19:19:18 +0000 (12:19 -0700)]
mon: flush before scrub

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/Paxos: flush io on reset()
Sage Weil [Thu, 21 Aug 2014 03:57:56 +0000 (20:57 -0700)]
mon/Paxos: flush io on reset()

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/Paxos: make backend write async
Sage Weil [Tue, 19 Aug 2014 23:48:34 +0000 (16:48 -0700)]
mon/Paxos: make backend write async

Move into the WRITING state and do the write to leveldb (or whatever the
backend is) asynchronously.

A few tricks here:
 - we can't do the is_updating() state check because we will always be in
   REFRESH.  Instead, make commit_proposal() tolerate the case where it is
   called but the top proposal isn't the one we just did (or the list is
   empty).  This makes the callers simpler.
 - do_refresh() may call bootstrap.  If we do bootstrap while in REFRESH,
   don't do a sync/flush on the backend store because *we* are async
   completion thread and we'll deadlock.  All other callers need to wait
   for this, though!

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/Paxos[Service]: allow reads during WRITING state
Sage Weil [Tue, 19 Aug 2014 23:45:46 +0000 (16:45 -0700)]
mon/Paxos[Service]: allow reads during WRITING state

The REFRESH state is not readable; that's when we are re-reading our state
out of leveldb, and we hold the mon_lock during the period.  So, strictly
speaking, it doesn't matter whether we include it here since none of these
call sites would be visited while in that state.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/Paxos: add writing and refresh states
Sage Weil [Tue, 19 Aug 2014 23:44:06 +0000 (16:44 -0700)]
mon/Paxos: add writing and refresh states

The new transition will be

 (updating or updating-previous) -> writing -> refresh -> active

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/Paxos: move post-commit finish work into commit_finish()
Sage Weil [Sun, 17 Aug 2014 05:29:04 +0000 (22:29 -0700)]
mon/Paxos: move post-commit finish work into commit_finish()

The main change here is that we are merging the singleton and clustered
finish code together.  This is mostly a code shuffle, except for one
semantic change: we now trigger the commit waiters before finish_round()
in the singleton case, whereas before we did not.  I don't think there
was a specific reason why it differed from the clustered case.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/Paxos: break commit() into two pieces
Sage Weil [Sun, 17 Aug 2014 05:22:01 +0000 (22:22 -0700)]
mon/Paxos: break commit() into two pieces

One part happens before the txn starts, the other after.  Move all of the
internal state update to the bottom half.  Eventually this will matter.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/MonitorDBStore: assert closed in destructor
Sage Weil [Wed, 20 Aug 2014 04:23:36 +0000 (21:23 -0700)]
mon/MonitorDBStore: assert closed in destructor

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/MonitorDBStore: drop useless ctor
Sage Weil [Sun, 17 Aug 2014 05:11:59 +0000 (22:11 -0700)]
mon/MonitorDBStore: drop useless ctor

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/MonitorDBStore: add async queue_transaction()
Sage Weil [Sun, 10 Aug 2014 22:19:06 +0000 (15:19 -0700)]
mon/MonitorDBStore: add async queue_transaction()

Do the transaction async, and then trigger a callback.

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/MonitorDBStore: add close() method
Sage Weil [Sun, 10 Aug 2014 22:17:45 +0000 (15:17 -0700)]
mon/MonitorDBStore: add close() method

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon: interact with MonitorDBStore::Transactions by shared_ptr Ref
Sage Weil [Sun, 10 Aug 2014 22:08:33 +0000 (15:08 -0700)]
mon: interact with MonitorDBStore::Transactions by shared_ptr Ref

TransactionRef everywhere!

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agocommon/Finisher: fix perfcounter
Sage Weil [Wed, 20 Aug 2014 04:29:41 +0000 (21:29 -0700)]
common/Finisher: fix perfcounter

Make sure we add in the nubmer of elements when we queue them
from a list or deque or vector.

Fix the type to be a counter.

Backport: firefly, dumpling
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agomon/OSDMonitor: fix double-free on old MOSDBoot
Sage Weil [Tue, 19 Aug 2014 23:43:02 +0000 (16:43 -0700)]
mon/OSDMonitor: fix double-free on old MOSDBoot

send_latest() does an m->put().

Backport: firefly, dumpling
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge remote-tracking branch 'gh/wip-rewrite-PR2189'
Sage Weil [Wed, 27 Aug 2014 21:24:54 +0000 (14:24 -0700)]
Merge remote-tracking branch 'gh/wip-rewrite-PR2189'

10 years agoMove fedora patch file (used by ceph.spec.in) to rpm/ subdir
Dan Mick [Wed, 27 Aug 2014 19:56:43 +0000 (12:56 -0700)]
Move fedora patch file (used by ceph.spec.in) to rpm/ subdir

Signed-off-by: Dan Mick <dan.mick@inktank.com>
10 years agoceph.spec.in: tests for rhel or centos need to not include _version
Dan Mick [Tue, 12 Aug 2014 23:31:22 +0000 (16:31 -0700)]
ceph.spec.in: tests for rhel or centos need to not include _version

rhel_version and centos_version are apparently the OpenSUSE Build
names; the native macros are just "rhel" and "centos" (and contain
a version number, should it be necessary).

Signed-off-by: Dan Mick <dan.mick@inktank.com>
10 years agoceph.spec.in: Add a small comment on the empty %files section
Dan Mick [Tue, 12 Aug 2014 21:46:52 +0000 (14:46 -0700)]
ceph.spec.in: Add a small comment on the empty %files section

as suggested by Dan Mick.

Signed-off-by: Erik Logtenberg <erik@logtenberg.eu>
10 years agoceph.spec.in: Obsolete all older versions.
Dan Mick [Tue, 12 Aug 2014 21:39:18 +0000 (14:39 -0700)]
ceph.spec.in: Obsolete all older versions.

Now this changeset can be used on all current ceph releases that already
have the package split.

Signed-off-by: Erik Logtenberg <erik@logtenberg.eu>
10 years agoceph.spec.in: No version on ceph-libs Obsoletes.
Dan Mick [Tue, 12 Aug 2014 21:09:43 +0000 (14:09 -0700)]
ceph.spec.in: No version on ceph-libs Obsoletes.

If we are installing with the new package structure we don't ever want the
new package to co-exist with the old one; this includes the mistakenly-
released v0.81 on Fedora, which should be removed in favor of this
version.

Signed-off-by: Sandon Van Ness <sandon@inktank.com>
Reviewed-by: Dan Mick <dan.mick@inktank.com>
10 years agoceph.spec.in: Obselete ceph-libcephfs (not libcephfs)
Sandon Van Ness [Sat, 9 Aug 2014 01:01:30 +0000 (18:01 -0700)]
ceph.spec.in: Obselete ceph-libcephfs (not libcephfs)

I am guessing that because it was a sub-package libcephfs was mistakenly
used instead of ceph-libcephfs.

Signed-off-by: Sandon Van Ness <sandon@inktank.com>
10 years agoceph.spec.in: We need those nice recent changes for rhel7 in Fedora too.
Erik Logtenberg [Fri, 1 Aug 2014 12:20:18 +0000 (14:20 +0200)]
ceph.spec.in: We need those nice recent changes for rhel7 in Fedora too.

Signed-off-by: Erik Logtenberg <erik@logtenberg.eu>
10 years agoceph.spec.in, init-ceph.in: Don't autostart ceph service on Fedora.
Erik Logtenberg [Thu, 31 Jul 2014 22:13:50 +0000 (00:13 +0200)]
ceph.spec.in, init-ceph.in: Don't autostart ceph service on Fedora.

This patch is taken from the current Fedora package and makes the upstream
ceph.spec compliant with Fedora policy. The goal is to be fully compliant
upstream so that we can replace current Fedora package with upstream
package to fix many bugs in Fedora.

Addition from Dan Mick <dan.mick@inktank.com>:
Do this for RHEL and Centos as well, since they surely will benefit
from the same policy.   Note: this requires changes to
autobuild-ceph and ceph-build scripts, which currently copy
only the dist tarball to the rpmbuild/SOURCES dir.

Signed-off-by: Erik Logtenberg <erik@logtenberg.eu>
Signed-off-by: Dan Mick <dan.mick@inktank.com>:
10 years agoceph.spec.in: Add obsoletes for libcephfs
Erik Logtenberg [Thu, 31 Jul 2014 21:54:03 +0000 (23:54 +0200)]
ceph.spec.in: Add obsoletes for libcephfs

This fixes a bug for Fedora:
https://bugzilla.redhat.com/show_bug.cgi?id=1116614

Signed-off-by: Erik Logtenberg <erik@logtenberg.eu>
10 years agoceph.spec.in: add ceph-libs-compat
Erik Logtenberg [Thu, 31 Jul 2014 21:49:56 +0000 (23:49 +0200)]
ceph.spec.in: add ceph-libs-compat

Added a ceph-libs-compat package in accordance with Fedora packaging
guidelines [1], to handle the recent package split more gracefully.
In Fedora this is necessary because there are already other packages
depending on ceph-libs, that need to be adjusted to depend on the new
split packages instead. In the mean time, ceph-libs-compat prevents
breakage.

[1] http://fedoraproject.org/wiki/Upgrade_paths_%E2%80%94_renaming_or_splitting_packages

Signed-off-by: Erik Logtenberg <erik@logtenberg.eu>
10 years agosystemd: ceph-mds and ceph-mon need networking too
Sage Weil [Wed, 27 Aug 2014 16:22:59 +0000 (09:22 -0700)]
systemd: ceph-mds and ceph-mon need networking too

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #2306 from mgarces/patch-1
Sage Weil [Wed, 27 Aug 2014 16:22:18 +0000 (09:22 -0700)]
Merge pull request #2306 from mgarces/patch-1

needs network or it will not start if enabled

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #2313 from dachary/wip-buffer
Sage Weil [Wed, 27 Aug 2014 16:17:51 +0000 (09:17 -0700)]
Merge pull request #2313 from dachary/wip-buffer

common: remove spurious uint32_t in buffer.c

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agosample.ceph.conf: some updates 2339/head
Sébastien Han [Wed, 27 Aug 2014 13:58:44 +0000 (15:58 +0200)]
sample.ceph.conf: some updates

This commit adds:
- a section for radosgw
- fix the replica count value (default is 3 since firefly)
- more OSDs options for performance and CRUSH

Signed-off-by: Sébastien Han <sebastien.han@enovance.com>
10 years agoMerge pull request #1950 from xylv/wip-8583
Yehuda Sadeh [Wed, 27 Aug 2014 15:56:25 +0000 (08:56 -0700)]
Merge pull request #1950 from xylv/wip-8583

rgw: admin ops create user API can not determine existing user

Reviewed-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agoosd/PG: fix crash from second backfill reservation rejection 2344/head
Sage Weil [Wed, 27 Aug 2014 13:19:12 +0000 (06:19 -0700)]
osd/PG: fix crash from second backfill reservation rejection

If we get more than one reservation rejection we should ignore them; when
we got the first we already sent out cancellations.  More importantly, we
should not crash.

Fixes: #8863
Backport: firefly, dumpling
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agotest/mon/mkfs.sh: fix test
Sage Weil [Wed, 27 Aug 2014 04:18:17 +0000 (21:18 -0700)]
test/mon/mkfs.sh: fix test

Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #2197 from ceph/wip-mon-empty-store
Sage Weil [Wed, 27 Aug 2014 01:05:30 +0000 (18:05 -0700)]
Merge pull request #2197 from ceph/wip-mon-empty-store

ceph_mon: check for existing mon store before opening db

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Pavan Rallabhandi <pavanrallabhandis@gmail.com>
10 years agoMerge pull request #2312 from ceph/wip-config-diff
Sage Weil [Wed, 27 Aug 2014 01:03:21 +0000 (18:03 -0700)]
Merge pull request #2312 from ceph/wip-config-diff

config diff: obtain diff between current config and default config

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge remote-tracking branch 'gh/next'
Sage Weil [Wed, 27 Aug 2014 00:33:59 +0000 (17:33 -0700)]
Merge remote-tracking branch 'gh/next'

Conflicts:
src/os/CollectionIndex.h

10 years agocommon: ceph_context: add admin socket command 'config diff' 2312/head
Joao Eduardo Luis [Tue, 26 Aug 2014 22:31:06 +0000 (23:31 +0100)]
common: ceph_context: add admin socket command 'config diff'

Outputs a diff between the current config and what the daemon believes
to be its default config.

Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
10 years agocommon: config: let us obtain a diff between current and default config
Joao Eduardo Luis [Sun, 24 Aug 2014 16:20:53 +0000 (17:20 +0100)]
common: config: let us obtain a diff between current and default config

It's mildly annoying when trying to figure out what has been changed on
a running system's config options and having to rely on whatever is set
on ceph.conf and the admin's memory of what has been injected.

With this we can simply ask the daemon for the diff between what would be
its default and what is its current config.

Current form will output extraneous information that was not directly
supplied by the user though, such as 'host' 'fsid' and 'daemonize', as
well as defaults we may rewrite ourselves (leveldb tunables on the monitor
for instance).  Nonetheless, it's way better than the alternative and
considering it should be used solely for debug purposes I think we can
get away with it.

Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
10 years agoMerge pull request #2334 from dachary/wip-9235-uninitialized-variables
Sage Weil [Tue, 26 Aug 2014 21:43:51 +0000 (14:43 -0700)]
Merge pull request #2334 from dachary/wip-9235-uninitialized-variables

tests: histogram prevent re-use of local variables

10 years agotests: histogram prevent re-use of local variables 2334/head
Loic Dachary [Tue, 26 Aug 2014 19:59:39 +0000 (21:59 +0200)]
tests: histogram prevent re-use of local variables

By moving the tests to separate functions.

http://tracker.ceph.com/issues/9235 Fixes: #9235

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoMerge pull request #2333 from dachary/wip-9235-uninitialized-variables
Sage Weil [Tue, 26 Aug 2014 21:15:35 +0000 (14:15 -0700)]
Merge pull request #2333 from dachary/wip-9235-uninitialized-variables

tests: histogram prevent re-use of local variables

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agotests: histogram prevent re-use of local variables 2333/head
Loic Dachary [Tue, 26 Aug 2014 19:59:39 +0000 (21:59 +0200)]
tests: histogram prevent re-use of local variables

By moving the test to a separate function.

http://tracker.ceph.com/issues/9235 Fixes: #9235

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoMerge pull request #2330 from ceph/wip-9211
Samuel Just [Tue, 26 Aug 2014 19:24:05 +0000 (12:24 -0700)]
Merge pull request #2330 from ceph/wip-9211

osd/OSDMap: encode blacklist in deterministic order

Reviewed-by: Samuel Just <sam.just@inktank.com>
10 years agoMerge pull request #2331 from ceph/wip-9238
Sage Weil [Tue, 26 Aug 2014 18:08:44 +0000 (11:08 -0700)]
Merge pull request #2331 from ceph/wip-9238

mds: fix FP error in ROUND_UP_TO

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agomds: fix FP error in ROUND_UP_TO 2331/head
John Spray [Tue, 26 Aug 2014 16:36:16 +0000 (17:36 +0100)]
mds: fix FP error in ROUND_UP_TO

Explicitly handle case where denominator is 0, instead of
passing into ROUND_UP_TO.

Regression from 9449520b121fc6ce0c64948386d4ff77f46f4f5f

Signed-off-by: John Spray <john.spray@redhat.com>
10 years agoMerge pull request #2321 from ceph/wip-9226
Sage Weil [Tue, 26 Aug 2014 16:18:23 +0000 (09:18 -0700)]
Merge pull request #2321 from ceph/wip-9226

rgw: fix test to identify whether object has tail

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #2314 from ceph/wip-mds-pc
John Spray [Tue, 26 Aug 2014 15:37:39 +0000 (16:37 +0100)]
Merge pull request #2314 from ceph/wip-mds-pc

mds: clean up perfcounter names

Reviewed-by: John Spray <john.spray@redhat.com>
10 years agoosd/OSDMap: encode blacklist in deterministic order 2330/head
Sage Weil [Tue, 26 Aug 2014 15:16:29 +0000 (08:16 -0700)]
osd/OSDMap: encode blacklist in deterministic order

When we use an unordered_map the encoding order is non-deterministic,
which is problematic for OSDMap.  Construct an ordered map<> on encode
and use that.  This lets us keep the hash table for lookups in the general
case.

Fixes: #9211
Backport: firefly
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #2325 from xinxinsh/wip-9217
Sage Weil [Tue, 26 Aug 2014 14:53:06 +0000 (07:53 -0700)]
Merge pull request #2325 from xinxinsh/wip-9217

fix wrong value of op_w_latency perf counter

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #2327 from theanalyst/fix/vstart_rgw_port
Sage Weil [Tue, 26 Aug 2014 13:23:38 +0000 (06:23 -0700)]
Merge pull request #2327 from theanalyst/fix/vstart_rgw_port

vstart: start rgw on port specified by env var

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agovstart: start rgw on port specified by env var 2327/head
Abhishek Lekshmanan [Tue, 26 Aug 2014 10:16:55 +0000 (15:46 +0530)]
vstart: start rgw on port specified by env var

This ensures that user specified option according to $CEPH_RGW_PORT is
considered before starting radosgw

Signed-off-by: Abhishek Lekshmanan <abhishek.lekshmanan@ril.com>
10 years agodon't update op_rw_rlatency/op_w_rlatency when rlatency is zero 2325/head
xinxin shu [Tue, 26 Aug 2014 00:16:04 +0000 (08:16 +0800)]
don't update op_rw_rlatency/op_w_rlatency when rlatency is zero

Signed-off-by: xinxin shu <xinxin.shu@intel.com>
10 years agofix wrong value of op_w_latency perf counter
xinxin shu [Tue, 26 Aug 2014 05:37:14 +0000 (13:37 +0800)]
fix wrong value of op_w_latency perf counter

Fixes: #9217
Signed-off-by: xinxin shu <xinxin.shu@intel.com>
10 years agoMerge pull request #2320 from ceph/wip-9221
Samuel Just [Tue, 26 Aug 2014 00:29:12 +0000 (17:29 -0700)]
Merge pull request #2320 from ceph/wip-9221

ceph_test_rados_api_tier: make PromoteOn2ndRead test tolerate retries

Reviewed-by: Samuel Just <sam.just@inktank.com>
10 years agoMerge branch 'wip-objecter'
John Spray [Tue, 26 Aug 2014 00:04:27 +0000 (01:04 +0100)]
Merge branch 'wip-objecter'

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #2319 from dachary/wip-9209-round-up-to
Sage Weil [Mon, 25 Aug 2014 21:47:33 +0000 (14:47 -0700)]
Merge pull request #2319 from dachary/wip-9209-round-up-to

common: ROUND_UP_TO accepts any rounding factor

Reviewed-by: Sage Weil <sage@redhat.com>
10 years agocommon: ROUND_UP_TO accepts any rounding factor 2319/head
Loic Dachary [Mon, 25 Aug 2014 15:05:04 +0000 (17:05 +0200)]
common: ROUND_UP_TO accepts any rounding factor

The ROUND_UP_TO function was limited to rounding factors that are powers
of two. This saves a modulo but it is not used where it would make a
difference. The implementation is changed so it is generic.

http://tracker.ceph.com/issues/9209 Fixes: #9209

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoMerge pull request #2323 from lpabon/fix-quick-guide
Yehuda Sadeh [Mon, 25 Aug 2014 18:53:59 +0000 (11:53 -0700)]
Merge pull request #2323 from lpabon/fix-quick-guide

Fix syntax error in rst documentation

Reviewed-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agoFix syntax error in rst documentation 2323/head
Luis Pabón [Mon, 25 Aug 2014 18:43:53 +0000 (14:43 -0400)]
Fix syntax error in rst documentation

Signed-off-by: Luis Pabón <lpabon@redhat.com>
10 years agorgw: fix test to identify whether object has tail 2321/head
Yehuda Sadeh [Mon, 25 Aug 2014 17:38:42 +0000 (10:38 -0700)]
rgw: fix test to identify whether object has tail

Fixes: #9226
Reported-by: Sylvain Munaut <s.munaut@whatever-company.com>
Backport: firefly

We need to identify whether an object is just composed of a head, or
also has a tail. Test for pre-firefly objects ("explicit objs") was
broken as it was just looking at the number of explicit objs in the
manifest. However, this is insufficient, as we might have empty head,
and in this case it wouldn't appear, so we need to check whether the
sole object is actually pointing at the head.

Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
10 years agoceph_test_rados_api_tier: make PromoteOn2ndRead test tolerate retries 2320/head
Sage Weil [Mon, 25 Aug 2014 17:18:43 +0000 (10:18 -0700)]
ceph_test_rados_api_tier: make PromoteOn2ndRead test tolerate retries

If there is an ill-timed connection reset our read could get sent twice.
Weaken our assertion if the read was slow to tolerate this case.

Fixes: #9221
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoMerge pull request #2311 from onlyjob/master
Gregory Farnum [Mon, 25 Aug 2014 17:17:59 +0000 (10:17 -0700)]
Merge pull request #2311 from onlyjob/master

Fix FTBFS on alpha due to incorrect check on BLKGETSIZE

Reviewed-by: Greg Farnum <greg@inktank.com>
10 years agoMerge pull request #2318 from dachary/wip-osd-config
Sage Weil [Mon, 25 Aug 2014 15:32:29 +0000 (08:32 -0700)]
Merge pull request #2318 from dachary/wip-osd-config

documentation: update recovery config options defaults

10 years agodocumentation: update recovery config options defaults 2318/head
Loic Dachary [Mon, 25 Aug 2014 13:52:29 +0000 (15:52 +0200)]
documentation: update recovery config options defaults

So they match the values from config_opts.h

Signed-off-by: Loic Dachary <loic-201408@dachary.org>
10 years agoCollectionIndex: Collection name is added to the access_lock name
Somnath Roy [Mon, 18 Aug 2014 23:59:36 +0000 (16:59 -0700)]
CollectionIndex: Collection name is added to the access_lock name

The CollectionIndex constructor is changed to accept the coll_t
so that the collection name can be used to form access_lock(RWLock)
name.This is needed otherwise lockdep will report a recursive lock error
and assert. lockdep needs unique lock names for each Index object.

Fixes: #9145
Signed-off-by: Somnath Roy <somnath.roy@sandisk.com>
(cherry picked from commit 615d2d904024526cc58557ee5250c2536a3cd5c8)

10 years agoMerge pull request #2275 from ceph/wip-9079
Sage Weil [Mon, 25 Aug 2014 13:25:07 +0000 (06:25 -0700)]
Merge pull request #2275 from ceph/wip-9079

msg/Accepter: do not unlearn_addr on bind()

Reviewed-by: Greg Farnum <greg@inktank.com>
10 years agorgw: admin ops create user API can not determine existing user 1950/head
Ray Lv [Wed, 11 Jun 2014 14:13:23 +0000 (22:13 +0800)]
rgw: admin ops create user API can not determine existing user

Fixes: #8583
Signed-off-by: Ray Lv <raylv@yahoo-inc.com>
10 years agoMerge pull request #2317 from ashishchandra1/patch-1
Loic Dachary [Mon, 25 Aug 2014 12:10:49 +0000 (14:10 +0200)]
Merge pull request #2317 from ashishchandra1/patch-1

Update python.rst

Reviewed-by: Loic Dachary <loic-201408@dachary.org>
10 years agoUpdate python.rst 2317/head
Ashish Chandra [Mon, 25 Aug 2014 12:06:29 +0000 (17:36 +0530)]
Update python.rst

Signed-off-by:ashish.a.chandra@ril.com

10 years agoMerge pull request #2316 from dachary/wip-warning
John Spray [Mon, 25 Aug 2014 10:06:42 +0000 (11:06 +0100)]
Merge pull request #2316 from dachary/wip-warning

rbd: fix signess warning

Reviewed-by: John Spray <john.spray@redhat.com>
10 years agomsg/Accepter: do not unlearn_addr on bind() 2275/head
Sage Weil [Mon, 25 Aug 2014 04:18:00 +0000 (21:18 -0700)]
msg/Accepter: do not unlearn_addr on bind()

It is dangerous to set need_addr = true as it means someone may set the
addr to something else (specifically the port) in a racing thread.

However, it is not necessary: the only reason we added it way back in
5d5045d31a9e10d21b44eb1bd137db9ae53128ff was so that
local_connection->peer_addr would get updated, and bind() now calls that
unconditionally.

Fixes: #9079
Backport: firefly
Signed-off-by: Sage Weil <sage@redhat.com>
10 years agoosd: update handle_osd_map call
John Spray [Mon, 25 Aug 2014 00:45:22 +0000 (01:45 +0100)]
osd: update handle_osd_map call

I had changed the implementation in Objecter
to avoid a spurious get/put cycle in "osdc/Objecter: fix resource
management", but this guy was still going a get() before
calling handle_osd_map.

Signed-off-by: John Spray <john.spray@redhat.com>
10 years agocommon/Timer: fix deadlock in RWTimer::shutdown
John Spray [Mon, 25 Aug 2014 00:29:02 +0000 (01:29 +0100)]
common/Timer: fix deadlock in RWTimer::shutdown

Fixes: #9213
Signed-off-by: John Spray <john.spray@redhat.com>
10 years agoosdc/Objecter: fix op_cancel on homeless session
John Spray [Mon, 25 Aug 2014 00:16:39 +0000 (01:16 +0100)]
osdc/Objecter: fix op_cancel on homeless session

Wrote this block without realizing that op_cancel
takes write lock on session lock, and that operation
is undefined when you already hold the read lock.

Fixes: #9214
Signed-off-by: John Spray <john.spray@redhat.com>