]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
13 years agoMerge remote branch 'upstream/master' into wip-backfill
Samuel Just [Fri, 23 Dec 2011 01:41:40 +0000 (17:41 -0800)]
Merge remote branch 'upstream/master' into wip-backfill

Conflicts:
src/include/object.h

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: objects currently begin backfilled are degraded
Samuel Just [Fri, 23 Dec 2011 01:38:39 +0000 (17:38 -0800)]
ReplicatedPG: objects currently begin backfilled are degraded

pending_stat_updates has also been renamed to pending_backfill_updates.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: fill in backfill_peer in on_activate
Samuel Just [Fri, 23 Dec 2011 01:24:13 +0000 (17:24 -0800)]
ReplicatedPG: fill in backfill_peer in on_activate

Previously, there was a race between issue_repop/do_op and
start_recovery_ops.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: only pull in one backfill peer at a time
Samuel Just [Fri, 23 Dec 2011 01:17:40 +0000 (17:17 -0800)]
ReplicatedPG: only pull in one backfill peer at a time

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agofilestore: fix config observer
Sage Weil [Thu, 22 Dec 2011 23:25:00 +0000 (15:25 -0800)]
filestore: fix config observer

Actually, I don't think this was fully implemented to begin with, so it's
not a 'fix' per se.  This will let you use injectargs to adjust the
filestore config options during runtime.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoMOSDPGRepScrub: Fix typo in MOSDPGRepScrub
Samuel Just [Thu, 22 Dec 2011 23:17:22 +0000 (15:17 -0800)]
MOSDPGRepScrub: Fix typo in MOSDPGRepScrub

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoPG: update stats from master only if not backfilling
Samuel Just [Thu, 22 Dec 2011 22:32:15 +0000 (14:32 -0800)]
PG: update stats from master only if not backfilling

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoPG: backfill info should be cleared on recovery reset
Samuel Just [Thu, 22 Dec 2011 20:44:38 +0000 (12:44 -0800)]
PG: backfill info should be cleared on recovery reset

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: init backfill infos to last_backfill
Samuel Just [Thu, 22 Dec 2011 17:44:33 +0000 (09:44 -0800)]
ReplicatedPG: init backfill infos to last_backfill

We can scan starting from last_backfill to avoid rescanning portions
of the collection recovered by normal recovery.  collection_list_partial
now includes begin if present.  next will be <= the next object in the
collection.  This way we can scan starting at last_backfill without
skipping last_backfill.

Signed-off-by: Samuel Just <rexludorum@gmail.com>
13 years agoReplicatedPG: update last_backfill when pushes complete
Samuel Just [Thu, 22 Dec 2011 02:10:44 +0000 (18:10 -0800)]
ReplicatedPG: update last_backfill when pushes complete

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: simplify recover_backfill
Samuel Just [Thu, 22 Dec 2011 00:45:11 +0000 (16:45 -0800)]
ReplicatedPG: simplify recover_backfill

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoMerge branch 'wip-signal'
Sage Weil [Thu, 22 Dec 2011 22:00:23 +0000 (14:00 -0800)]
Merge branch 'wip-signal'

13 years agoMOSDRepScrub: use header.version for payload version
Samuel Just [Thu, 22 Dec 2011 20:33:48 +0000 (12:33 -0800)]
MOSDRepScrub: use header.version for payload version

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoMerge branch 'stable'
Sage Weil [Thu, 22 Dec 2011 20:16:06 +0000 (12:16 -0800)]
Merge branch 'stable'

13 years agomonmap: iterate over addr_name when printing summary
Henry C Chang [Thu, 22 Dec 2011 10:48:29 +0000 (18:48 +0800)]
monmap: iterate over addr_name when printing summary

The rank is now ordered by IP address. We should iterate over
addr_name.

Signed-off-by: Henry C Chang <henry.cy.chang@gmail.com>
13 years agomonmap: clear addr_name map on calculating ranks
Henry C Chang [Thu, 22 Dec 2011 10:49:04 +0000 (18:49 +0800)]
monmap: clear addr_name map on calculating ranks

We should clear addr_name before filling it. Otherwise, the removed
mon will stay there and cause incorrect rank assignment.

Signed-off-by: Henry C Chang <henry.cy.chang@gmail.com>
13 years agointerval_set: fix truncation of _size
Henry C Chang [Thu, 22 Dec 2011 10:47:25 +0000 (18:47 +0800)]
interval_set: fix truncation of _size

_size is type of int64_t. Use int to store the value of _size
will cause value truncation.

Signed-off-by: Henry C Chang <henry.cy.chang@gmail.com>
13 years agoosd: remove SIGTERM cruft
Sage Weil [Wed, 21 Dec 2011 22:21:37 +0000 (14:21 -0800)]
osd: remove SIGTERM cruft

The default handler will exit(0).  The got_sigterm stuff was dead code.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: drop special SIGTERM handler
Sage Weil [Wed, 21 Dec 2011 22:17:42 +0000 (14:17 -0800)]
mon: drop special SIGTERM handler

Default does exit(0).

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomds: drop special SIGTERM handler
Sage Weil [Wed, 21 Dec 2011 22:17:19 +0000 (14:17 -0800)]
mds: drop special SIGTERM handler

Default does exit(0).

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoexit(0) on SIGTERM by default
Sage Weil [Wed, 21 Dec 2011 22:17:00 +0000 (14:17 -0800)]
exit(0) on SIGTERM by default

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoReplicatedPG: Initialize blocked_by in ObjectContext constructor
Samuel Just [Wed, 21 Dec 2011 19:19:22 +0000 (11:19 -0800)]
ReplicatedPG: Initialize blocked_by in ObjectContext constructor

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoMerge pull request #7 from kylemarsh/wip-obsync-swift-metadata
Sage Weil [Wed, 21 Dec 2011 04:11:51 +0000 (20:11 -0800)]
Merge pull request #7 from kylemarsh/wip-obsync-swift-metadata

obsync: pull object metadata from swift store

13 years agoReplicatedPG: take references for blocked_by and blocking
Samuel Just [Wed, 21 Dec 2011 01:35:55 +0000 (17:35 -0800)]
ReplicatedPG: take references for blocked_by and blocking

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoobsync: pull object metadata from swift store 7/head
Kyle Marsh [Wed, 21 Dec 2011 01:08:21 +0000 (17:08 -0800)]
obsync: pull object metadata from swift store

Obsync wasn't pulling object metadata from swift stores and thus wasn't
syncing metadata when reading from a swift store.  This commit fixes that.

13 years agoMerge remote branch 'upstream/wip-backfill-ordering' into wip-backfill
Samuel Just [Wed, 21 Dec 2011 01:05:29 +0000 (17:05 -0800)]
Merge remote branch 'upstream/wip-backfill-ordering' into wip-backfill

13 years agoPG: add some documentation
Samuel Just [Wed, 21 Dec 2011 00:52:38 +0000 (16:52 -0800)]
PG: add some documentation

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: delay op while snapdir is missing/degraded
Samuel Just [Wed, 21 Dec 2011 00:50:35 +0000 (16:50 -0800)]
ReplicatedPG: delay op while snapdir is missing/degraded

We cannot get/update a snapcontext if snapdir is missing/degraded.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: don't manage waiting_on_backfill in start/finish_recovery_op
Samuel Just [Tue, 20 Dec 2011 23:28:11 +0000 (15:28 -0800)]
ReplicatedPG: don't manage waiting_on_backfill in start/finish_recovery_op

Set waiting_on_backfill in recover_backfill and clear in do_scan.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agorgw: fix subuser key name when purging subuser keys
Yehuda Sadeh [Tue, 20 Dec 2011 19:39:32 +0000 (11:39 -0800)]
rgw: fix subuser key name when purging subuser keys

13 years agoradosgw-admin: add --purge-keys option
Yehuda Sadeh [Tue, 20 Dec 2011 19:00:39 +0000 (11:00 -0800)]
radosgw-admin: add --purge-keys option

13 years agoReplicatedPG: apply_repop: apply local_t before op_t
Samuel Just [Tue, 20 Dec 2011 18:53:36 +0000 (10:53 -0800)]
ReplicatedPG: apply_repop: apply local_t before op_t

We create snap_collections in local_t and clone into them in op_t.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoPG: Do not update_snap_collections for log entries > last_backfill
Samuel Just [Tue, 20 Dec 2011 00:26:56 +0000 (16:26 -0800)]
PG: Do not update_snap_collections for log entries > last_backfill

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoPG: Fix stat debug output
Samuel Just [Tue, 20 Dec 2011 00:26:31 +0000 (16:26 -0800)]
PG: Fix stat debug output

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agocalc_acting: Prefer up[0] as primary if possible
Samuel Just [Sat, 17 Dec 2011 02:04:32 +0000 (18:04 -0800)]
calc_acting: Prefer up[0] as primary if possible

Previously, we could get into a state where although up[0] has been
fully backfilled, acting[0] could be selected as a primary if it is able
to pull another peer into the acting set.  This also collects the logic
of choosing the best info into a helper function.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agorgw: add timeout to init path
Yehuda Sadeh [Tue, 20 Dec 2011 00:00:27 +0000 (16:00 -0800)]
rgw: add timeout to init path

13 years agoMOSDRepScrub,ReplicatedPG: Add scrub_to to MOSDRepScrub
Samuel Just [Mon, 19 Dec 2011 22:50:17 +0000 (14:50 -0800)]
MOSDRepScrub,ReplicatedPG: Add scrub_to to MOSDRepScrub

When scrub_from is set, also set scrub_to to the primary's
last_update_applied (which will also be the official last_update before
finalizing scrub began).  The replica instead of waiting for
last_update_applied to catch up to last_update will wait for
last_update_applied to catch up to active_rep_scrub->scrub_to.  This
avoids a race where the replica scrub is requeued before all of the
currently queued sub-ops have been processed.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agomon: update man page to document --mkfs stuff
Sage Weil [Mon, 19 Dec 2011 21:47:43 +0000 (13:47 -0800)]
mon: update man page to document --mkfs stuff

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomds: misc assertions about truncation
Sage Weil [Wed, 30 Nov 2011 01:21:42 +0000 (17:21 -0800)]
mds: misc assertions about truncation

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoosd: EINVAL on truncate to huge object size
Sage Weil [Wed, 30 Nov 2011 01:17:25 +0000 (17:17 -0800)]
osd: EINVAL on truncate to huge object size

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoMerge pull request #6 from kylemarsh/wip-obsync-swift
Sage Weil [Mon, 19 Dec 2011 22:00:59 +0000 (14:00 -0800)]
Merge pull request #6 from kylemarsh/wip-obsync-swift

Wip obsync swift

13 years agorgw: remove temp context in prepare_get_obj
Yehuda Sadeh [Mon, 19 Dec 2011 21:54:04 +0000 (13:54 -0800)]
rgw: remove temp context in prepare_get_obj

13 years agorgw: fix xml parser internal structure leak
Yehuda Sadeh [Mon, 19 Dec 2011 21:38:58 +0000 (13:38 -0800)]
rgw: fix xml parser internal structure leak

13 years agorgw: fix a leak of acl structure (in req_state)
Yehuda Sadeh [Mon, 19 Dec 2011 21:38:40 +0000 (13:38 -0800)]
rgw: fix a leak of acl structure (in req_state)

13 years agorgw: remove temp context in prepare_get_obj
Yehuda Sadeh [Mon, 19 Dec 2011 21:54:04 +0000 (13:54 -0800)]
rgw: remove temp context in prepare_get_obj

13 years agorgw: fix xml parser internal structure leak
Yehuda Sadeh [Mon, 19 Dec 2011 21:38:58 +0000 (13:38 -0800)]
rgw: fix xml parser internal structure leak

13 years agorgw: fix a leak of acl structure (in req_state)
Yehuda Sadeh [Mon, 19 Dec 2011 21:38:40 +0000 (13:38 -0800)]
rgw: fix a leak of acl structure (in req_state)

13 years agoMerge branch 'wip-osd-maybe-created'
Greg Farnum [Mon, 19 Dec 2011 21:25:27 +0000 (13:25 -0800)]
Merge branch 'wip-osd-maybe-created'

13 years agoMerge branch 'wip-osd-fsid'
Sage Weil [Mon, 19 Dec 2011 21:24:46 +0000 (13:24 -0800)]
Merge branch 'wip-osd-fsid'

13 years agodoc: fix typo
Sage Weil [Mon, 19 Dec 2011 21:24:31 +0000 (13:24 -0800)]
doc: fix typo

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoosd: --get-journal-fsid
Sage Weil [Wed, 30 Nov 2011 22:13:47 +0000 (14:13 -0800)]
osd: --get-journal-fsid

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agofilejournal: uuid for fsid
Sage Weil [Wed, 30 Nov 2011 22:13:14 +0000 (14:13 -0800)]
filejournal: uuid for fsid

Decode old header struct, but encode new class using more normal encoding
style.  Embed in a bufferlist for later extensibility.  Use the first
64 bits of the uuid for the per-entry magic, as before.

When we load an old fsid, we mirror the 64-bits.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agofilestore: make fsid uuid_d instead of uint64_t
Sage Weil [Wed, 30 Nov 2011 05:49:49 +0000 (21:49 -0800)]
filestore: make fsid uuid_d instead of uint64_t

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: --get-osd-fsid and --get-cluster-fsid
Sage Weil [Wed, 30 Nov 2011 05:06:29 +0000 (21:06 -0800)]
osd: --get-osd-fsid and --get-cluster-fsid

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: store osd_fsid as text in osd_data dir
Sage Weil [Wed, 30 Nov 2011 05:06:10 +0000 (21:06 -0800)]
osd: store osd_fsid as text in osd_data dir

along with ceph_fsid (the cluster fsid) and a few other things.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: include osd_fsid in OSDSuperblock
Sage Weil [Wed, 30 Nov 2011 05:05:20 +0000 (21:05 -0800)]
osd: include osd_fsid in OSDSuperblock

Generated during mkfs.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: rename OSDSuperblock::fsid -> cluster_fsid
Sage Weil [Wed, 30 Nov 2011 04:46:42 +0000 (20:46 -0800)]
osd: rename OSDSuperblock::fsid -> cluster_fsid

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agodoc: fix mon cluster expansion docs
Sage Weil [Mon, 19 Dec 2011 16:04:53 +0000 (08:04 -0800)]
doc: fix mon cluster expansion docs

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: pull addr from ceph.conf, mon_host as needed when joining mon cluster
Sage Weil [Mon, 19 Dec 2011 16:03:59 +0000 (08:03 -0800)]
mon: pull addr from ceph.conf, mon_host as needed when joining mon cluster

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agomon: fix setting of mon addr when joining a cluster
Sage Weil [Mon, 19 Dec 2011 15:57:45 +0000 (07:57 -0800)]
mon: fix setting of mon addr when joining a cluster

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agorgw: fix updating of object metadata
Yehuda Sadeh [Sat, 17 Dec 2011 06:04:43 +0000 (22:04 -0800)]
rgw: fix updating of object metadata

being used in swift POST. We were updating wrong object
size and etag

13 years agorgw: bucket cannot be recreated if already exists
Yehuda Sadeh [Sat, 17 Dec 2011 01:13:53 +0000 (17:13 -0800)]
rgw: bucket cannot be recreated if already exists

13 years agoman: Update the configuration example for radosgw
Wido den Hollander [Fri, 16 Dec 2011 21:01:05 +0000 (22:01 +0100)]
man: Update the configuration example for radosgw

Signed-off-by: Wido den Hollander <wido@widodh.nl>
13 years agoman: It is capital -C instead of -c when for creating a new keyring
Wido den Hollander [Fri, 16 Dec 2011 21:00:46 +0000 (22:00 +0100)]
man: It is capital -C instead of -c when for creating a new keyring

Signed-off-by: Wido den Hollander <wido@widodh.nl>
13 years agorgw: fix updating of object metadata
Yehuda Sadeh [Sat, 17 Dec 2011 06:04:43 +0000 (22:04 -0800)]
rgw: fix updating of object metadata

being used in swift POST. We were updating wrong object
size and etag

13 years agorgw: bucket cannot be recreated if already exists
Yehuda Sadeh [Sat, 17 Dec 2011 01:13:53 +0000 (17:13 -0800)]
rgw: bucket cannot be recreated if already exists

13 years agoobsync: add authurl to CLI 6/head
Kyle Marsh [Sat, 17 Dec 2011 00:05:46 +0000 (16:05 -0800)]
obsync: add authurl to CLI

s3 connections require the hostname and swift connections require the
authurl.  obsync treats these as equivalent internally, but breaks them
apart on the command line interface for clarity for the users.

13 years agoobject.h: initialize max in hobject_t(sobject_t) constructor
Samuel Just [Fri, 16 Dec 2011 22:42:36 +0000 (14:42 -0800)]
object.h: initialize max in hobject_t(sobject_t) constructor

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: fix handle_watch_timeout ctx->at_version
Samuel Just [Fri, 16 Dec 2011 19:30:46 +0000 (11:30 -0800)]
ReplicatedPG: fix handle_watch_timeout ctx->at_version

ctx->at_version should match the head of the new log entries
during issue_repop.  This could cause the scrub hang bug as
last_update would be less than last_update_applied.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: add asserts to catch scrub error
Samuel Just [Fri, 16 Dec 2011 19:22:58 +0000 (11:22 -0800)]
ReplicatedPG: add asserts to catch scrub error

If last_update_applied skipped over last_update, we would see
scrub hang.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agodoc: fix filename in mon addition process
Sage Weil [Fri, 16 Dec 2011 18:39:33 +0000 (10:39 -0800)]
doc: fix filename in mon addition process

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agofilejournal: preallocate journal bytes on create
Sage Weil [Fri, 16 Dec 2011 17:19:59 +0000 (09:19 -0800)]
filejournal: preallocate journal bytes on create

This should reduce fragmentation for large journals that are written
slowly the first time around.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoMerge pull request #5 from homac/master
Sage Weil [Fri, 16 Dec 2011 17:08:17 +0000 (09:08 -0800)]
Merge pull request #5 from homac/master

Minor fix for init files and cleaned up spec file. Please pull

13 years agoman: clarify mount.ceph auth options
Josh Durgin [Thu, 15 Dec 2011 22:03:00 +0000 (14:03 -0800)]
man: clarify mount.ceph auth options

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
13 years agoman: update rule definition for ceph-rbdnamer
Josh Durgin [Thu, 15 Dec 2011 21:49:10 +0000 (13:49 -0800)]
man: update rule definition for ceph-rbdnamer

This is the rule we install since 891025e539a92b5d75011e2e75c475fc0c272042.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
13 years agoauthx -> cephx everywhere it's used
Josh Durgin [Thu, 15 Dec 2011 21:41:56 +0000 (13:41 -0800)]
authx -> cephx everywhere it's used

The term authx was in the mount.ceph man page, and got accidentally
copied into rbd help.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
13 years agoReplicatedPG: fix backfill mismatch error output
Samuel Just [Thu, 15 Dec 2011 19:17:51 +0000 (11:17 -0800)]
ReplicatedPG: fix backfill mismatch error output

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: calc_clone_subsets fix other clone_overlap case
Samuel Just [Thu, 15 Dec 2011 19:17:25 +0000 (11:17 -0800)]
ReplicatedPG: calc_clone_subsets fix other clone_overlap case

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoOSD: use disk_tp.pause() without osd_lock
Samuel Just [Thu, 15 Dec 2011 19:16:26 +0000 (11:16 -0800)]
OSD: use disk_tp.pause() without osd_lock

Previously, we called disk_tp.pause_new().  This can cause a race
where snap_trimmer queues more transactions after we flush the
store.  Calling disk_tp.pause() under the osd_lock causes a
deadlock with pg removal.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoceph.spec: Clean up and fix spec file and build for a couple of distributions 5/head
Holger Macht [Thu, 15 Dec 2011 16:51:04 +0000 (17:51 +0100)]
ceph.spec: Clean up and fix spec file and build for a couple of distributions

Clean up and fix the spec file. This includes cleaning up of build and
installed system dependencies, LSB compliance fixes, splitting up into
several sub-packages (lib*) and so on. It now builds fine for the
following distributions in the Open Build Service and should be
considered as a starting point for further fixes:

 - CentOS 6
 - Fedora 15
 - RedHat Enterprise Linux 6
 - openSUSE 11.4
 - openSUSE 12.1
 - openSUSE Factory
 - SUSE Linux Enterprise 11 (SP1 and SP2)

Signed-off-by: Holger Macht <hmacht@suse.de>
13 years agoinit-ceph/init-radosgw: Don't use unspecified runlevel 4
Holger Macht [Thu, 15 Dec 2011 16:49:15 +0000 (17:49 +0100)]
init-ceph/init-radosgw: Don't use unspecified runlevel 4

Don't use runlevel 4 in init scripts. AFAIK, no distribution is using it
and at least the Open Build Service complains about it.

Signed-off-by: Holger Macht <hmacht@suse.de>
13 years agoosd: wait for src_oid if it on other side of last_backfill from oid
Sage Weil [Thu, 15 Dec 2011 02:54:45 +0000 (18:54 -0800)]
osd: wait for src_oid if it on other side of last_backfill from oid

If the target object is before last_backfill, then the backfill_target
will be asked to apply the operation.  If one of the src objects is past
last_backfill, that will fail, so we need to wait for the src object to
be not degraded.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoosd: EINVAL on mismatched locator without waiting for degraded
Sage Weil [Thu, 15 Dec 2011 02:42:45 +0000 (18:42 -0800)]
osd: EINVAL on mismatched locator without waiting for degraded

No reason to recover before returning an error.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoosd: preserve write order when waiting on src_oids
Sage Weil [Thu, 15 Dec 2011 02:41:10 +0000 (18:41 -0800)]
osd: preserve write order when waiting on src_oids

We need to preserve the order of write operations on each object.  If we
have a write on X that needs to read from Y, and Y is degraded, then we
need to wait for Y to repair.  Doing so blindly will allow other writes
to X to proceed while our clone op is still waiting, violating the
ordering.

Fix this by adding blocked_by and blocking vars to the ObjectContext.  If
we wait on a src_oid, the oid is "blocked" by that object, and any
subsequent writes should also wait on the same queue.

Use a helper to do the cleanup when we complete recovery, or when the
pg resets.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoclient: fix logger deregistration
Sage Weil [Thu, 15 Dec 2011 01:43:18 +0000 (17:43 -0800)]
client: fix logger deregistration

Only unregister logger if it is non-NULL (and thus registered) to avoid
running afoul of the cct assertions.

Signed-off-by: Sage Weil <sage@newdream.net>
13 years agoReplicatedPG: add_object_context_to_pg_stat, obc->ssc may be null
Samuel Just [Wed, 14 Dec 2011 23:51:17 +0000 (15:51 -0800)]
ReplicatedPG: add_object_context_to_pg_stat, obc->ssc may be null

obc->ssc is not necessarily filled in by get_object_context.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoobsync: add vvprint back in
Kyle Marsh [Wed, 14 Dec 2011 23:37:47 +0000 (15:37 -0800)]
obsync: add vvprint back in

Commit ebe5fc60d20f92a0037c53c1e7bd7ae512be3da4 removed the definition of
vvprint without removint all the places that used it.

13 years agoPG: clear waiting_on_backfill during clear_recovery_state
Samuel Just [Wed, 14 Dec 2011 23:19:15 +0000 (15:19 -0800)]
PG: clear waiting_on_backfill during clear_recovery_state

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: list snapid 0 on collection_list_partial for backfill
Samuel Just [Wed, 14 Dec 2011 23:17:44 +0000 (15:17 -0800)]
ReplicatedPG: list snapid 0 on collection_list_partial for backfill

0 will list all objects, CEPH_NO_SNAP will list only head objects.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoMerge remote branch 'upstream/master' into wip_backfill_merged
Samuel Just [Wed, 14 Dec 2011 19:40:15 +0000 (11:40 -0800)]
Merge remote branch 'upstream/master' into wip_backfill_merged

13 years agoReplicatedPG: collection_list_partial also takes a snapid
Samuel Just [Wed, 14 Dec 2011 19:39:21 +0000 (11:39 -0800)]
ReplicatedPG: collection_list_partial also takes a snapid

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agodoc: Make overview.rst valid reStructuredText, so I can stop seeing warnings.
Tommi Virtanen [Wed, 14 Dec 2011 19:38:08 +0000 (11:38 -0800)]
doc: Make overview.rst valid reStructuredText, so I can stop seeing warnings.

It's still wrong, but now it won't clutter the output.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
13 years agopybind: Add a description to docstring.
Tommi Virtanen [Wed, 14 Dec 2011 19:32:34 +0000 (11:32 -0800)]
pybind: Add a description to docstring.

This avoids a Sphinx warning like this:

.../src/pybind/rbd.py:docstring of rbd.RBD.version:2: WARNING: Field list ends without a blank line; unexpected unindent.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
13 years agodoc: reStructuredText syntax fix.
Tommi Virtanen [Wed, 14 Dec 2011 19:25:40 +0000 (11:25 -0800)]
doc: reStructuredText syntax fix.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
13 years agoPG: Ask for digest at most once at a time
Samuel Just [Wed, 14 Dec 2011 18:55:31 +0000 (10:55 -0800)]
PG: Ask for digest at most once at a time

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoosd: track backfill target pg stats
Sage Weil [Wed, 14 Dec 2011 01:43:34 +0000 (17:43 -0800)]
osd: track backfill target pg stats

Maintain backfill target pg stats to be the summation over objects to
the left of last_backfill.  Reflect this in the degraded stats we report
to the monitor.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoosd: object_stat_sum_t::clear()
Sage Weil [Tue, 13 Dec 2011 20:51:37 +0000 (12:51 -0800)]
osd: object_stat_sum_t::clear()

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
13 years agoPG: activate, backfill replica can have last_complete < log_tail
Samuel Just [Tue, 13 Dec 2011 22:22:42 +0000 (14:22 -0800)]
PG: activate, backfill replica can have last_complete < log_tail

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoReplicatedPG: calc_*_subsets must consider last_backfill
Samuel Just [Tue, 13 Dec 2011 21:02:57 +0000 (13:02 -0800)]
ReplicatedPG: calc_*_subsets must consider last_backfill

Objects yet to be backfilled do not show up in the missing set.  Thus,
we cannot use an object past last_backfill to clone into the object we
are pushing/pulling.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
13 years agoPG: A backfill osd can have last_complete < log_tail
Samuel Just [Tue, 13 Dec 2011 18:11:37 +0000 (10:11 -0800)]
PG: A backfill osd can have last_complete < log_tail

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>