]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
13 years agoReplicatedPG: clean up push/pull
Samuel Just [Tue, 14 Feb 2012 20:55:43 +0000 (12:55 -0800)]
ReplicatedPG: clean up push/pull

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoosd_types.h: Add constructors for ObjectRecovery*
Samuel Just [Tue, 14 Feb 2012 20:52:59 +0000 (12:52 -0800)]
osd_types.h: Add constructors for ObjectRecovery*

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: refactor push and pull
Samuel Just [Mon, 13 Feb 2012 19:49:42 +0000 (11:49 -0800)]
ReplicatedPG: refactor push and pull

Now, push progress is represented by ObjectRecoveryProgress.  In
particular, rather than tracking data_subset_*ing, we track the furthest
offset before which the data will be consistent once cloning is complete.
sub_op_push now separates the pull response implementation from the
replica push implementation.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoMOSDSubOp: Add new object recovery state
Samuel Just [Wed, 8 Feb 2012 00:35:04 +0000 (16:35 -0800)]
MOSDSubOp: Add new object recovery state

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: consider backfill_pos to be degraded
Samuel Just [Sun, 12 Feb 2012 01:50:49 +0000 (17:50 -0800)]
ReplicatedPG: consider backfill_pos to be degraded

A write may trigger via make_writeable the creation of a clone which
sorts before the object being written.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: add debugging for in flight backfill ops
Samuel Just [Sun, 12 Feb 2012 01:52:13 +0000 (17:52 -0800)]
ReplicatedPG: add debugging for in flight backfill ops

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: is_degraded may return true for backfill
Samuel Just [Sun, 12 Feb 2012 01:53:47 +0000 (17:53 -0800)]
ReplicatedPG: is_degraded may return true for backfill

If is_degraded returns true for backfill, the object may not be
in any replica's missing set.  Only call start_recovery_op if
we actually started an op.  This bug could cause a stuck
in backfill error.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoMerge remote-tracking branch 'gh/wip-mon-lag'
Sage Weil [Mon, 13 Feb 2012 18:01:32 +0000 (10:01 -0800)]
Merge remote-tracking branch 'gh/wip-mon-lag'

Reviewed-by: Sage Weil <sage@newdream.net>
13 years agoosd: new osd_peer_stat_t shell type
Sage Weil [Mon, 13 Feb 2012 17:42:37 +0000 (09:42 -0800)]
osd: new osd_peer_stat_t shell type

We weren't using this, and it had broken (raw) encoding.  The constructor
also didn't initialize fields properly.

Clear out the struct and use the new encoding scheme, so we can cleanly
add fields moving forward.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoqa/btrfs/.gitignore: ignore targets
Sage Weil [Mon, 13 Feb 2012 17:35:17 +0000 (09:35 -0800)]
qa/btrfs/.gitignore: ignore targets

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agorgw: don't use SCRIPT_NAME and QUERY_STRING vars
Yehuda Sadeh [Sun, 12 Feb 2012 06:43:35 +0000 (22:43 -0800)]
rgw: don't use SCRIPT_NAME and QUERY_STRING vars

REQUEST_URI holds everything we need, and it's encoded correctly.

Signed-off-by: Yehuda Sadeh <yehuda@hq.newdream.net>
13 years agoRevert "rgw: don't treat plus as a space in url decode"
Yehuda Sadeh [Sun, 12 Feb 2012 05:16:50 +0000 (21:16 -0800)]
Revert "rgw: don't treat plus as a space in url decode"

This reverts commit a6d7629c177fbab722a7a0c7f861caf91ff92deb.

13 years agoosd: filter trimming|purged snaps out of op SnapContext
Sage Weil [Sat, 11 Feb 2012 22:55:06 +0000 (14:55 -0800)]
osd: filter trimming|purged snaps out of op SnapContext

We can receive an op with an old SnapContext that includes snaps that we've
already trimmed or are in the process of trimming.  Filter them out!
Otherwise we will recreate and add links into collections we've already
marked as removed, and we'll get things like ENOTEMPTY when we try to
remove them.  Or just leave them laying around.

Fixes: #1949
Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: add {mon,quorum}_status admin socket commands
Sage Weil [Sat, 11 Feb 2012 22:32:46 +0000 (14:32 -0800)]
mon: add {mon,quorum}_status admin socket commands

These dump some json with the current monitor/quorum status.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agomon: move quorum_status into helper
Sage Weil [Sat, 11 Feb 2012 22:29:52 +0000 (14:29 -0800)]
mon: move quorum_status into helper

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agomon: move mon_status into a helper
Sage Weil [Sat, 11 Feb 2012 22:10:53 +0000 (14:10 -0800)]
mon: move mon_status into a helper

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoinit-ceph, mkcephfs: try 'btrfs device scan' before 'btrfsctl -a'
Sage Weil [Sat, 11 Feb 2012 21:43:23 +0000 (13:43 -0800)]
init-ceph, mkcephfs: try 'btrfs device scan' before 'btrfsctl -a'

Fixes: #2023
Reported-by: Wido den Hollander <wido@widodh.nl>
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: fix MOSDPGCreate version setting
Sage Weil [Sat, 11 Feb 2012 19:56:51 +0000 (11:56 -0800)]
osd: fix MOSDPGCreate version setting

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoMerge remote branch 'gh/wip-osd-encoding'
Sage Weil [Sat, 11 Feb 2012 19:48:29 +0000 (11:48 -0800)]
Merge remote branch 'gh/wip-osd-encoding'

13 years agoosd: queue pg removal under pg's epoch
Sage Weil [Sat, 11 Feb 2012 17:28:14 +0000 (09:28 -0800)]
osd: queue pg removal under pg's epoch

The PG may be doing work relative to a different epoch than what the osd
has.  Make sure the PG removal message is queued under that epoch to avoid
confusing/crashing the recipient like so:

2012-02-10 23:26:35.691793 7f387281f700 osd.3 514 queue_pg_for_deletion: 0.0
osd/OSD.cc: In function 'void OSD::handle_pg_remove(OpRequest*)' thread 7f387281f700 time 2012-02-10 23:26:35.691820
osd/OSD.cc: 4860: FAILED assert(pg->get_primary() == m->get_source().num())

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoosd: check for valid snapc _before_ doing op work
Sage Weil [Sat, 11 Feb 2012 00:47:33 +0000 (16:47 -0800)]
osd: check for valid snapc _before_ doing op work

Check this early to avoid wasting effort, or causing side-effects from
do_osd_op_effects().

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoosd: some cleanup
Sage Weil [Sat, 11 Feb 2012 00:46:33 +0000 (16:46 -0800)]
osd: some cleanup

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: validate osmdap input
Sage Weil [Sat, 11 Feb 2012 17:49:42 +0000 (09:49 -0800)]
mon: validate osmdap input

And clean up some error return paths while we're here.

Fixes: #1493
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agorgw: objects can contain '%'
Yehuda Sadeh [Sat, 11 Feb 2012 00:47:54 +0000 (16:47 -0800)]
rgw: objects can contain '%'

Signed-off-by: Yehuda Sadeh <yehuda@hq.newdream.net>
13 years agomon: fix MMonElection encoding version
Sage Weil [Fri, 10 Feb 2012 23:17:23 +0000 (15:17 -0800)]
mon: fix MMonElection encoding version

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: remove the last_consumed setting in Paxos
Greg Farnum [Fri, 10 Feb 2012 23:07:10 +0000 (15:07 -0800)]
mon: remove the last_consumed setting in Paxos

This was only ever used while initializing the Paxos machine, and it
doesn't need to be. Its existence is just an invitation to have races
between updating the stashed data and the stashed version.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
13 years agoobjecter: LingerOp is refcounted
Yehuda Sadeh [Fri, 10 Feb 2012 22:45:27 +0000 (14:45 -0800)]
objecter: LingerOp is refcounted

this should fix Bug #2050, where a linger op was used after being freed.

Signed-off-by: Yehuda Sadeh <yehuda@hq.newdream.net>
13 years agomon: handle inconsistent disk states on startup.
Greg Farnum [Fri, 10 Feb 2012 23:02:03 +0000 (15:02 -0800)]
mon: handle inconsistent disk states on startup.

This lets us recover from an interrupted slurp while still noticing
other corruption issues. Rather than running init() and then
update_from_paxos() on each instance, we run init() and check
consistency. If it is consistent, we update_from_paxos as before. If
it is not, we do nothing and detect the slurping state
in handle_probe_reply(). (This assumes the disk was in a slurping state. If not, the
daemon crashes because something else went horribly wrong.)

While we're at it, remove unnecessary sets of first_committed. These
are done in the call to pax->trim_to().

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
13 years agoMerge branch 'wip-encoding'
Sage Weil [Fri, 10 Feb 2012 22:39:44 +0000 (14:39 -0800)]
Merge branch 'wip-encoding'

Reviewed-by: Greg Farnum <gregory.farnum@dreamhost.com>
13 years agoqa/btrfs/create_async_snap
Sage Weil [Fri, 10 Feb 2012 22:03:44 +0000 (14:03 -0800)]
qa/btrfs/create_async_snap

Stupid tool to call the async snap ioctl.  Until the btrfs tool does it.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomessages: populate header.version in constructor
Sage Weil [Fri, 10 Feb 2012 22:38:13 +0000 (14:38 -0800)]
messages: populate header.version in constructor

Define a HEAD_VERSION and COMPAT_VERSION for any versioned message.  Pass
to Message constructor so that it is always initialized, even from the
the default constructor.  That's needed because we use that to check
decoding compatibility when receiving/decoding messages.

If we are conditionally encoding an old version, explicitly set
header.version in encode_payload().

We also set compat_version to demonstrate what will happen for future
revisions.  In this case, it's moot, because no old code understands
compat_version yet: nobody with old decode code will see these values
anyway.  But use this opportunity to demonstrate how it would be used in
the future.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agomon: add a slurping flag to the Paxos state
Greg Farnum [Fri, 10 Feb 2012 18:42:24 +0000 (10:42 -0800)]
mon: add a slurping flag to the Paxos state

Set it before we start slurping, and clear it when we end slurping.
This allows us to differentiate between deliberately inconsistent
disk states, and broken disk states. Run simple checks in a new
is_consistent() call.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
13 years agoReplicatedPG: don't put the op on -EAGAIN
Samuel Just [Fri, 10 Feb 2012 17:55:44 +0000 (09:55 -0800)]
ReplicatedPG: don't put the op on -EAGAIN

EAGAIN indicates that the op is
waiting_for_missing or waiting_for_degraded

Reviewed-by: Greg Farnum <greg.farnum@dreamhost.com>
Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agomon: initialize paxos state in constructor
Greg Farnum [Fri, 10 Feb 2012 17:16:58 +0000 (09:16 -0800)]
mon: initialize paxos state in constructor

These should all be initialized in init() anyway
(except accepted_pn_from, which is set in collect and handle_collect),
but initializing them to safe defaults in the constructor provides
a safety net.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
13 years agomsg: check compat_version before decoding
Sage Weil [Thu, 2 Feb 2012 23:02:41 +0000 (15:02 -0800)]
msg: check compat_version before decoding

If the newly constructed message's version is older than the
compat_version, don't even try to decode; just fail.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agomsg: populate compat_version for encoded messages
Sage Weil [Thu, 2 Feb 2012 22:30:30 +0000 (14:30 -0800)]
msg: populate compat_version for encoded messages

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agomsg: include compat_version in version header
Sage Weil [Thu, 2 Feb 2012 22:29:59 +0000 (14:29 -0800)]
msg: include compat_version in version header

header.version is the version we encoded.
header.compat_version is the oldest version of code that can decode it.

If the value is 0, we don't know anything about backward compatibility.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agonew encoding for Log{Entry,Summary}
Sage Weil [Fri, 10 Feb 2012 06:01:27 +0000 (22:01 -0800)]
new encoding for Log{Entry,Summary}

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoos: new encoding for hobject_t
Sage Weil [Fri, 10 Feb 2012 05:56:18 +0000 (21:56 -0800)]
os: new encoding for hobject_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pg_create_t
Sage Weil [Fri, 10 Feb 2012 05:54:34 +0000 (21:54 -0800)]
osd: new encoding for pg_create_t

There was no version encoding previously, so this is an incompatible
change.  Fortunately this type is only used in one place, MOSDPGCreate,
so we'll rev that encoding and compensate there.  All is well!

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for osd_stat_t
Sage Weil [Fri, 10 Feb 2012 05:53:45 +0000 (21:53 -0800)]
osd: new encoding for osd_stat_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for object_locator_t
Sage Weil [Fri, 10 Feb 2012 05:53:35 +0000 (21:53 -0800)]
osd: new encoding for object_locator_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for osd_reqid_t
Sage Weil [Fri, 10 Feb 2012 05:53:22 +0000 (21:53 -0800)]
osd: new encoding for osd_reqid_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new ScrubMap::object encoding
Sage Weil [Tue, 7 Feb 2012 04:19:33 +0000 (20:19 -0800)]
osd: new ScrubMap::object encoding

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: set last_changed when creating new pgs
Sage Weil [Fri, 3 Feb 2012 18:05:41 +0000 (10:05 -0800)]
mon: set last_changed when creating new pgs

This will help us identify PGs that are stuck in creating state.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agomon: set last_unstale when marking PGs stale
Sage Weil [Fri, 3 Feb 2012 18:07:46 +0000 (10:07 -0800)]
mon: set last_unstale when marking PGs stale

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: include state timestamps, mapping_epoch in pg_stat_t
Sage Weil [Fri, 3 Feb 2012 18:07:30 +0000 (10:07 -0800)]
osd: include state timestamps, mapping_epoch in pg_stat_t

Track the time when the pg state last changed (or was refreshed) in
interesting ways.

Also track the epoch when the mapping last changed (same_interval_since).

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoosd: new encoding for PG::Interval
Sage Weil [Thu, 2 Feb 2012 21:15:55 +0000 (13:15 -0800)]
osd: new encoding for PG::Interval

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for PG::OndiskLog
Sage Weil [Thu, 2 Feb 2012 21:15:29 +0000 (13:15 -0800)]
osd: new encoding for PG::OndiskLog

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoobjectstore: new encoding for Transaction
Sage Weil [Thu, 2 Feb 2012 21:15:14 +0000 (13:15 -0800)]
objectstore: new encoding for Transaction

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for ScrubMap
Sage Weil [Thu, 2 Feb 2012 20:44:13 +0000 (12:44 -0800)]
osd: new encoding for ScrubMap

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for object_info_t
Sage Weil [Thu, 2 Feb 2012 20:44:04 +0000 (12:44 -0800)]
osd: new encoding for object_info_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for watch_info_t
Sage Weil [Thu, 2 Feb 2012 20:43:38 +0000 (12:43 -0800)]
osd: new encoding for watch_info_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for SnapSet
Sage Weil [Thu, 2 Feb 2012 20:43:26 +0000 (12:43 -0800)]
osd: new encoding for SnapSet

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pg_missing_t
Sage Weil [Thu, 2 Feb 2012 20:42:59 +0000 (12:42 -0800)]
osd: new encoding for pg_missing_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pg_log_t
Sage Weil [Thu, 2 Feb 2012 20:42:47 +0000 (12:42 -0800)]
osd: new encoding for pg_log_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pg_log_entry_t
Sage Weil [Thu, 2 Feb 2012 20:42:30 +0000 (12:42 -0800)]
osd: new encoding for pg_log_entry_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pg_history_t
Sage Weil [Thu, 2 Feb 2012 20:42:07 +0000 (12:42 -0800)]
osd: new encoding for pg_history_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pg_history_t
Sage Weil [Thu, 2 Feb 2012 20:41:41 +0000 (12:41 -0800)]
osd: new encoding for pg_history_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pool_stat_t
Sage Weil [Thu, 2 Feb 2012 20:40:56 +0000 (12:40 -0800)]
osd: new encoding for pool_stat_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pg_stat_t
Sage Weil [Thu, 2 Feb 2012 20:40:23 +0000 (12:40 -0800)]
osd: new encoding for pg_stat_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for object_stat_collection_t
Sage Weil [Thu, 2 Feb 2012 20:39:55 +0000 (12:39 -0800)]
osd: new encoding for object_stat_collection_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for object_stat_sum_t
Sage Weil [Thu, 2 Feb 2012 19:39:37 +0000 (11:39 -0800)]
osd: new encoding for object_stat_sum_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pg_pool_t
Sage Weil [Thu, 2 Feb 2012 19:36:43 +0000 (11:36 -0800)]
osd: new encoding for pg_pool_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for pool_snap_info_t
Sage Weil [Thu, 2 Feb 2012 19:35:31 +0000 (11:35 -0800)]
osd: new encoding for pool_snap_info_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: new encoding for OSDSuperblock
Sage Weil [Thu, 2 Feb 2012 19:34:20 +0000 (11:34 -0800)]
osd: new encoding for OSDSuperblock

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: move object_locator_t to osd_types.{h,cc}
Sage Weil [Fri, 10 Feb 2012 05:45:00 +0000 (21:45 -0800)]
osd: move object_locator_t to osd_types.{h,cc}

That's a better home.  Also add to ceph-dencoder.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoceph-dencoder: add osd_reqid_t
Sage Weil [Fri, 10 Feb 2012 05:35:39 +0000 (21:35 -0800)]
ceph-dencoder: add osd_reqid_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoceph-dencoder: add hobject_t
Sage Weil [Fri, 10 Feb 2012 05:30:16 +0000 (21:30 -0800)]
ceph-dencoder: add hobject_t

Move to a separate file in os/, since this is an ObjectStore related
object.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agomon: add/use pg_create_t ctor
Sage Weil [Fri, 10 Feb 2012 05:17:55 +0000 (21:17 -0800)]
mon: add/use pg_create_t ctor

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoceph-dencoder: add pg_create_t (formerly MOSDPGCreate::create_rec)
Sage Weil [Fri, 10 Feb 2012 05:15:53 +0000 (21:15 -0800)]
ceph-dencoder: add pg_create_t (formerly MOSDPGCreate::create_rec)

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agotest/encoding/readable.sh: no \t
Sage Weil [Fri, 10 Feb 2012 01:20:18 +0000 (17:20 -0800)]
test/encoding/readable.sh: no \t

Not sure why this sometimes works and sometimes doesn't.  Maybe it's a
bashism?

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoMerge branch 'wip-corpus'
Sage Weil [Fri, 10 Feb 2012 00:47:15 +0000 (16:47 -0800)]
Merge branch 'wip-corpus'

13 years agoceph-dencoder: add Log{Entry,EntryKey,Summary}
Sage Weil [Fri, 10 Feb 2012 00:44:39 +0000 (16:44 -0800)]
ceph-dencoder: add Log{Entry,EntryKey,Summary}

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agofilestore: wait to start op if other ops are in line
Sage Weil [Fri, 10 Feb 2012 00:20:31 +0000 (16:20 -0800)]
filestore: wait to start op if other ops are in line

We can have a sequence like:

- commit_start, blocked=true
- op_start thread A gets in line
- op_start thread B gets in line
- commit finished, blocked=false
- thread A goes
- op_start thread C sees blocked=false and continues
-> order broken

If there are people in line from a previous block, we need to get in line,
even if blocked == false.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agofilestore: fix op queue quiesce during commit
Sage Weil [Thu, 9 Feb 2012 19:23:10 +0000 (11:23 -0800)]
filestore: fix op queue quiesce during commit

When I added the ordering constraint fix back in 259c509a I got the
check backwards.  We want to wait if we are blocked OR we are not in the
front of the line (i.e., proceed if we are not blocked AND first in line).

Fixes: #2046
Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoMerge remote branch 'gh/wip-types'
Sage Weil [Thu, 9 Feb 2012 05:05:39 +0000 (21:05 -0800)]
Merge remote branch 'gh/wip-types'

13 years agoMerge remote branch 'gh/wip-stuck-in-backfill'
Sage Weil [Thu, 9 Feb 2012 04:43:53 +0000 (20:43 -0800)]
Merge remote branch 'gh/wip-stuck-in-backfill'

Reviewed-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoReplicatedPG: don't count deletions as ops
Josh Durgin [Thu, 9 Feb 2012 01:38:52 +0000 (17:38 -0800)]
ReplicatedPG: don't count deletions as ops

Counting them as ops but not requeueing the pg for recovery causes
backfill to stall when only deletions are sent in
recover_backfill(). Deletions are cheap and don't need to be acked, so
we can simply stop counting them as ops.

Fixes: #2044
Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
13 years agoosd: don't remove pg from recovery queue if not enough recovery ops started
Josh Durgin [Wed, 8 Feb 2012 23:38:20 +0000 (15:38 -0800)]
osd: don't remove pg from recovery queue if not enough recovery ops started

The pg has already been dequeued at the beginning of do_recovery(),
and it requeues itself only if it starts a new recovery op.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
13 years agorgw: don't treat plus as a space in url decode
Yehuda Sadeh [Thu, 9 Feb 2012 01:08:39 +0000 (17:08 -0800)]
rgw: don't treat plus as a space in url decode

Any special character encoding should be done through %hex. The
plus sign is a valid character in object names, and in user id
(when used in signed urls).

Signed-off-by: Yehuda Sadeh <yehuda@hq.newdream.net>
13 years agoosd: discard waiting ops when pg mapping changes
Sage Weil [Thu, 9 Feb 2012 00:19:30 +0000 (16:19 -0800)]
osd: discard waiting ops when pg mapping changes

If the pg mapping changes away from us, we can safely discard messages we
have waiting for the PG to be created.

Fixes: #2013
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
Reviewed-by: Josh Durgin <josh.durgin@dreamhost.com>
13 years agoosd: flush on activate
Sage Weil [Wed, 8 Feb 2012 19:20:47 +0000 (11:20 -0800)]
osd: flush on activate

PG::activate() can make lots of changes, most notably clean_up_local()
which deletes lots of local objects.  Those changes need to be flushed
to the fs before we start servicing requests or else we risk processing a
client read on those objects.

Fixes: #1974
Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoMakefile: check readability of object corpus on 'make check'
Sage Weil [Fri, 3 Feb 2012 18:02:06 +0000 (10:02 -0800)]
Makefile: check readability of object corpus on 'make check'

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoadd ceph-object-corpus.git submodule
Sage Weil [Fri, 3 Feb 2012 17:59:53 +0000 (09:59 -0800)]
add ceph-object-corpus.git submodule

13 years agomon: fix [near]full_ratio conf update
Sage Weil [Wed, 8 Feb 2012 04:16:43 +0000 (20:16 -0800)]
mon: fix [near]full_ratio conf update

Already a value in [0,1].  Interpret as a percentage if > 1.0.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agomon: better MonCaps test cases
Sage Weil [Tue, 7 Feb 2012 23:43:44 +0000 (15:43 -0800)]
mon: better MonCaps test cases

Move MonCaps to libcommon.la.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoceph-dencoder: MonCap[s]
Sage Weil [Tue, 7 Feb 2012 19:44:40 +0000 (11:44 -0800)]
ceph-dencoder: MonCap[s]

Need some better test instances for MonCaps...

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: fix PGMap::generate_test_instances()
Sage Weil [Tue, 7 Feb 2012 17:16:54 +0000 (09:16 -0800)]
mon: fix PGMap::generate_test_instances()

Apply an incremental instead of futzing directly with members.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: refactor calc_stats()
Sage Weil [Tue, 7 Feb 2012 17:16:30 +0000 (09:16 -0800)]
mon: refactor calc_stats()

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoosd: is_zero() method for stat structs
Sage Weil [Tue, 7 Feb 2012 17:30:02 +0000 (09:30 -0800)]
osd: is_zero() method for stat structs

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoosd: fix ScrubMap::object ctor
Sage Weil [Tue, 7 Feb 2012 17:33:54 +0000 (09:33 -0800)]
osd: fix ScrubMap::object ctor

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: make [near]full_ratio config options floats
Sage Weil [Tue, 7 Feb 2012 17:04:37 +0000 (09:04 -0800)]
mon: make [near]full_ratio config options floats

ratio implies a real number, not a percentage.  Correct, though, if it is
> 1.0.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: initialize [near]full_ratio during create_initial(), not ctor
Sage Weil [Tue, 7 Feb 2012 17:02:51 +0000 (09:02 -0800)]
mon: initialize [near]full_ratio during create_initial(), not ctor

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoceph-dencoder: MonMap
Sage Weil [Mon, 6 Feb 2012 23:50:50 +0000 (15:50 -0800)]
ceph-dencoder: MonMap

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: uninline Monmap encode/decode
Sage Weil [Mon, 6 Feb 2012 23:13:26 +0000 (15:13 -0800)]
mon: uninline Monmap encode/decode

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoceph-dencoder: PGMap[::Incremental]
Sage Weil [Mon, 6 Feb 2012 23:10:21 +0000 (15:10 -0800)]
ceph-dencoder: PGMap[::Incremental]

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: waitlist new sessions trying to connect while we're out of quorum
Greg Farnum [Wed, 8 Feb 2012 19:08:51 +0000 (11:08 -0800)]
mon: waitlist new sessions trying to connect while we're out of quorum

If we're stuck out of the quorum, we don't want clients connecting to
to us. Instead, waitlist their requests; process them when we get into
a quorum and look at them every tick so we can toss them out
(if we take too long to get into a quorum).

This change is smaller than it looks - most requests would
previously have been blocked anyway while waiting for Paxos to be
readable, and the ones that weren't (eg, one-time map subscribes)
should have been!

This also means we can tear out the cleanup code for new Sessions, so
tick() looks better.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
13 years agoupdate amazonaws xmlns to correct url
michael rodriguez [Wed, 8 Feb 2012 04:07:21 +0000 (20:07 -0800)]
update amazonaws xmlns to correct url

Signed-off-by: michael rodriguez <michael@newdream.net>
13 years agomds: remove IntervalTree code
Sage Weil [Wed, 8 Feb 2012 06:07:46 +0000 (22:07 -0800)]
mds: remove IntervalTree code

Not used, not tested.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>