]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
12 years agodoc: Added indexing and did a bit of cleanup.
John Wilkins [Fri, 7 Jun 2013 16:50:03 +0000 (09:50 -0700)]
doc: Added indexing and did a bit of cleanup.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agodoc: Updated with glossary terms.
John Wilkins [Fri, 7 Jun 2013 00:35:02 +0000 (17:35 -0700)]
doc: Updated with glossary terms.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agodoc: Updated with glossary terms.
John Wilkins [Fri, 7 Jun 2013 00:29:02 +0000 (17:29 -0700)]
doc: Updated with glossary terms.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agodoc: Correction and index tags.
John Wilkins [Fri, 7 Jun 2013 00:27:34 +0000 (17:27 -0700)]
doc: Correction and index tags.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agodoc: Updates for glossary terms.
John Wilkins [Fri, 7 Jun 2013 00:26:51 +0000 (17:26 -0700)]
doc: Updates for glossary terms.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agoMerge pull request #347 from dalgaaf/wip-da-scripts
Sage Weil [Thu, 6 Jun 2013 22:14:25 +0000 (15:14 -0700)]
Merge pull request #347 from dalgaaf/wip-da-scripts

Some smaller fixes for init-radosgw files

12 years agodoc/release-notes: v0.61.3
Sage Weil [Thu, 6 Jun 2013 18:58:41 +0000 (11:58 -0700)]
doc/release-notes: v0.61.3

Signed-off-by: Sage Weil <sage@inktank.com>
12 years agodoc: Added upstart syntax.
John Wilkins [Thu, 6 Jun 2013 17:59:42 +0000 (10:59 -0700)]
doc: Added upstart syntax.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agodoc: Added link to Upstart syntax.
John Wilkins [Thu, 6 Jun 2013 17:58:47 +0000 (10:58 -0700)]
doc: Added link to Upstart syntax.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agoMerge branch 'wip_5154'
Samuel Just [Thu, 6 Jun 2013 16:21:46 +0000 (09:21 -0700)]
Merge branch 'wip_5154'

Fixes: #5154
Reviewed-by: Sage Weil <sage@inktank.com>
12 years agoinit-radosgw*: add all sections to usage output 347/head
Danny Al-Gaaf [Thu, 6 Jun 2013 13:34:54 +0000 (15:34 +0200)]
init-radosgw*: add all sections to usage output

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agoinit-radosgw*: add status
Danny Al-Gaaf [Thu, 6 Jun 2013 13:33:23 +0000 (15:33 +0200)]
init-radosgw*: add status

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agofix init-radosgw* to use the same indentation
Danny Al-Gaaf [Thu, 6 Jun 2013 13:21:30 +0000 (15:21 +0200)]
fix init-radosgw* to use the same indentation

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agoMerge branch 'wip-3527'
David Zafman [Thu, 6 Jun 2013 07:38:50 +0000 (00:38 -0700)]
Merge branch 'wip-3527'

Reviewed-by: Samuel Just <sam.just@inktank.com>
12 years agotest: Add blacklisting to test_stress_watch
David Zafman [Thu, 6 Jun 2013 02:14:33 +0000 (19:14 -0700)]
test: Add blacklisting to test_stress_watch

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agoAdd test_blacklist_self() librados function for test cases
David Zafman [Thu, 6 Jun 2013 06:22:17 +0000 (23:22 -0700)]
Add test_blacklist_self() librados function for test cases

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agoosd: Add dump_watchers to osd admin socket to examine all watchers
David Zafman [Fri, 31 May 2013 00:18:24 +0000 (17:18 -0700)]
osd: Add dump_watchers to osd admin socket to examine all watchers

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agorados: Output client address in rados listwatchers request
David Zafman [Thu, 30 May 2013 20:21:09 +0000 (13:21 -0700)]
rados: Output client address in rados listwatchers request

Add client entity_addr_t string to list of watchers rados interface

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agoosd: Add dump_blacklist to admin socket
David Zafman [Wed, 29 May 2013 20:17:01 +0000 (13:17 -0700)]
osd: Add dump_blacklist to admin socket

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agoosd: Drop watchers from blacklisted clients
David Zafman [Thu, 23 May 2013 17:12:26 +0000 (10:12 -0700)]
osd: Drop watchers from blacklisted clients

On blackist addition or populate ObjectContext
   check watcher address against blacklist
Add dout() of the watcher's ip address

fixes: #3527

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agoosd: Add entity_addr_t to watch_info_t and Watch
David Zafman [Fri, 24 May 2013 00:52:46 +0000 (17:52 -0700)]
osd: Add entity_addr_t to watch_info_t and Watch

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agoOSD: resurrect a parent if it splits into the pg we want to create
Samuel Just [Thu, 30 May 2013 22:11:58 +0000 (15:11 -0700)]
OSD: resurrect a parent if it splits into the pg we want to create

When attempting to create a new pg object in response to a
peering message, there are 3 cases:
1) That pg is currently being deleted.  In this case, we
cancel the deletion and resurrect the pg at the epoch at
which it had been deleted.
2) A pg is being deleted which would have split into the
pg we want to create had it not been deleted.  In that case,
we resurrect that pg at the map at which it had been deleted
and let the request wait on the impending split.
3) Neither that pg nor a parent can be resurrected.  In this
case, we create a new pg at the map epoch of the peering
request.

Fixes: #5154
Signed-off-by: Samuel Just <sam.just@inktank.com>
12 years agoqa: stop running xfstests 192 in qemu
Josh Durgin [Wed, 5 Jun 2013 19:54:30 +0000 (12:54 -0700)]
qa: stop running xfstests 192 in qemu

This test is unreliable in a vm since it relies on command timing for
checking access time.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
12 years agoMakefile.am: add -ldl to unittest_pglog
Josh Durgin [Wed, 5 Jun 2013 19:22:34 +0000 (12:22 -0700)]
Makefile.am: add -ldl to unittest_pglog

b70868e007ffa56e0eabf22b4ca836327c5f82d4 broke non-package builds on
ubuntu and debian. This fixes the problem, and is required for anything
compiling class_api.cc.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
12 years agoceph-test: add ceph_test_rados_api_lock to packaging and qa
Josh Durgin [Wed, 5 Jun 2013 01:01:59 +0000 (18:01 -0700)]
ceph-test: add ceph_test_rados_api_lock to packaging and qa

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
12 years agoAdd RADOS API lock tests
Filippos Giannakos [Tue, 4 Jun 2013 09:52:08 +0000 (12:52 +0300)]
Add RADOS API lock tests

Add tests for the advisory locking API calls.

Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
Signed-off-by: Filippos Giannakos <philipgian@grnet.gr>
12 years agoAdd RADOS lock mechanism to the librados C/C++ API.
Filippos Giannakos [Tue, 4 Jun 2013 09:52:07 +0000 (12:52 +0300)]
Add RADOS lock mechanism to the librados C/C++ API.

Add functions to the librados C/C++ API, to take advantage and utilize the
advisory locking system offered by RADOS.

Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
Signed-off-by: Filippos Giannakos <philipgian@grnet.gr>
12 years agoMerge branch 'master' of https://github.com/ceph/ceph
John Wilkins [Wed, 5 Jun 2013 18:45:43 +0000 (11:45 -0700)]
Merge branch 'master' of https://github.com/ceph/ceph

12 years agodoc: Added key and ceph repository to ceph-deploy install.
John Wilkins [Wed, 5 Jun 2013 18:44:58 +0000 (11:44 -0700)]
doc: Added key and ceph repository to ceph-deploy install.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agocls,msg: Fix use of set_in4_quad() to set a entity_addr_t
David Zafman [Fri, 24 May 2013 18:20:49 +0000 (11:20 -0700)]
cls,msg: Fix use of set_in4_quad() to set a entity_addr_t

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agoosd: Fix usage of commands supported by TestOpsSocketHook::test_ops()
David Zafman [Wed, 29 May 2013 20:18:17 +0000 (13:18 -0700)]
osd: Fix usage of commands supported by TestOpsSocketHook::test_ops()

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agoosd: Style corrections
David Zafman [Wed, 15 May 2013 00:12:10 +0000 (17:12 -0700)]
osd: Style corrections

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agodev/rbd-diff: make formats into bullet lists (solves linebreak probs)
Dan Mick [Wed, 5 Jun 2013 00:23:52 +0000 (17:23 -0700)]
dev/rbd-diff: make formats into bullet lists (solves linebreak probs)

Signed-off-by: Dan Mick <dan.mick@inktank.com>
12 years agoMerge pull request #346 from ceph/wip-5233
Sage Weil [Tue, 4 Jun 2013 23:39:41 +0000 (16:39 -0700)]
Merge pull request #346 from ceph/wip-5233

rados.py: correct some C types

12 years agodoc: Removed ceph-deploy git, and added ceph-deploy packages.
John Wilkins [Tue, 4 Jun 2013 22:35:56 +0000 (15:35 -0700)]
doc: Removed ceph-deploy git, and added ceph-deploy packages.

fixes: #5253

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agodoc: Modified pre-flight checklist for ceph-deploy packages.
John Wilkins [Tue, 4 Jun 2013 22:35:14 +0000 (15:35 -0700)]
doc: Modified pre-flight checklist for ceph-deploy packages.

fixes: #5253

12 years agodoc: Added title. Suppresses no title warning messages.
John Wilkins [Tue, 4 Jun 2013 22:33:42 +0000 (15:33 -0700)]
doc: Added title. Suppresses no title warning messages.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agorados.py: correct some C types 346/head
Josh Durgin [Tue, 4 Jun 2013 20:23:36 +0000 (13:23 -0700)]
rados.py: correct some C types

trunc was getting size_t instead of uint64_t, leading to bad results
in 32-bit environments. Explicitly cast to the desired type
everywhere, so it's clear the correct type is being used.

Fixes: #5233
Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
12 years agoRevert "mds: initialize rejoins_pending"
Sage Weil [Tue, 4 Jun 2013 20:08:37 +0000 (13:08 -0700)]
Revert "mds: initialize rejoins_pending"

This reverts commit 05a57bdd1289a63dcf2d4ca2f0dd3d73aff684ac.

Supplanted by d7fb9b173a163eb2318af5832456f0f236f716fd.

12 years agomds: allow purging "dirty parent" stray inode
Yan, Zheng [Tue, 4 Jun 2013 03:19:26 +0000 (11:19 +0800)]
mds: allow purging "dirty parent" stray inode

Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
12 years agomds: initialize some member variables of MDCache
Yan, Zheng [Tue, 4 Jun 2013 03:19:25 +0000 (11:19 +0800)]
mds: initialize some member variables of MDCache

I added some member variables to class MDCache, but forget to
initialize them.

Fixes: #5236
Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
12 years agoMerge remote-tracking branch 'gh/next'
Sage Weil [Tue, 4 Jun 2013 20:08:07 +0000 (13:08 -0700)]
Merge remote-tracking branch 'gh/next'

12 years agoMerge pull request #340 from dachary/wip-5213
athanatos [Tue, 4 Jun 2013 19:39:29 +0000 (12:39 -0700)]
Merge pull request #340 from dachary/wip-5213

PGLog::merge_old_entry unit tests

Reviewed-by: Sam Just <sam.just@inktank.com>
12 years agoMerge pull request #327 from dachary/wip-pg_missing_t-tests
athanatos [Tue, 4 Jun 2013 19:38:10 +0000 (12:38 -0700)]
Merge pull request #327 from dachary/wip-pg_missing_t-tests

unit tests for pg_missing_t

Reviewed-by: Sam Just <sam.just@inktank.com>
12 years agoOSD: add pgid and res_map to DeletingState
Samuel Just [Thu, 30 May 2013 22:11:34 +0000 (15:11 -0700)]
OSD: add pgid and res_map to DeletingState

Signed-off-by: Samuel Just <sam.just@inktank.com>
12 years agoOSD: make get_or_create_pg handle_pg_peering_evt
Samuel Just [Wed, 29 May 2013 22:37:38 +0000 (15:37 -0700)]
OSD: make get_or_create_pg handle_pg_peering_evt

handle_pg_peering_evt() includes checking for splitting
and unlocking the pg.

Signed-off-by: Samuel Just <sam.just@inktank.com>
12 years agoOSD: remove created argument from get_or_create_pg()
Samuel Just [Wed, 29 May 2013 22:18:04 +0000 (15:18 -0700)]
OSD: remove created argument from get_or_create_pg()

Signed-off-by: Samuel Just <sam.just@inktank.com>
12 years agoRevert "mds: allow purging "dirty parent" stray inode"
Sage Weil [Tue, 4 Jun 2013 18:07:58 +0000 (11:07 -0700)]
Revert "mds: allow purging "dirty parent" stray inode"

This reverts commit b8f1cb978944a616b69150fdbb3a6b978d75b1dc.

12 years agomds: initialize rejoins_pending
Sage Weil [Tue, 4 Jun 2013 18:07:33 +0000 (11:07 -0700)]
mds: initialize rejoins_pending

Signed-off-by: Sage Weil <sage@inktank.com>
12 years agoRevert "mds: initialize some member variables of MDCache"
Sage Weil [Tue, 4 Jun 2013 18:05:52 +0000 (11:05 -0700)]
Revert "mds: initialize some member variables of MDCache"

This reverts commit 2d655bde8de9ad255d63718768558399cacd7068.

12 years agoos/LevelDBStore: only remove logger if non-null
Sage Weil [Tue, 4 Jun 2013 17:42:13 +0000 (10:42 -0700)]
os/LevelDBStore: only remove logger if non-null

Signed-off-by: Sage Weil <sage@inktank.com>
12 years agotest_filestore_idempotent: make newly created objects globally unique
Samuel Just [Tue, 4 Jun 2013 16:49:06 +0000 (09:49 -0700)]
test_filestore_idempotent: make newly created objects globally unique

The filestore requires hobjects to be globally unique.

Fixes: #5240
Signed-off-by: Samuel Just <sam.just@inktank.com>
Reviewed-by: Sage Weil <sage@inktank.com>
12 years agotest_librbd: use correct type for varargs snap test
Josh Durgin [Mon, 3 Jun 2013 22:57:23 +0000 (15:57 -0700)]
test_librbd: use correct type for varargs snap test

uint64_t is passed in, but int was extracted. This fails on 32-bit builds.

Fixes: #5220
Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
(cherry picked from commit 17029b270dee386e12e5f42c2494a5feffd49b08)

12 years agoMerge pull request #344 from ceph/wip-5220
Sage Weil [Tue, 4 Jun 2013 16:38:23 +0000 (09:38 -0700)]
Merge pull request #344 from ceph/wip-5220

Reviewed-by: Sage Weil <sage@inktank.com>
12 years agounit tests for PGLog::merge_old_entry 340/head
Loic Dachary [Sun, 2 Jun 2013 10:53:48 +0000 (12:53 +0200)]
unit tests for PGLog::merge_old_entry

The tests covers 100% of the LOC of merge_old_entry. It is broken down
in 13 cases to enumerate all the situations it must address. Each case
is isolated in a independant code block where the conditions are
reproduced. For  instance:

    info.last_backfill = hobject_t();
    info.last_backfill.hash = 1;
    oe.soid.hash = 2;

creates the conditions where merge_log_entry is expected to silently
ignore entries containing an object that is greater than
last_backfill.

PGLogTest is derived from PGLog to get access to the protected members.

Signed-off-by: Loic Dachary <loic@dachary.org>
12 years agomds: allow purging "dirty parent" stray inode
Yan, Zheng [Tue, 4 Jun 2013 03:19:26 +0000 (11:19 +0800)]
mds: allow purging "dirty parent" stray inode

Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
12 years agomds: initialize some member variables of MDCache
Yan, Zheng [Tue, 4 Jun 2013 03:19:25 +0000 (11:19 +0800)]
mds: initialize some member variables of MDCache

I added some member variables to class MDCache, but forget to
initialize them.

Fixes: #5236
Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
12 years agotest_librbd: use correct type for varargs snap test 344/head
Josh Durgin [Mon, 3 Jun 2013 22:57:23 +0000 (15:57 -0700)]
test_librbd: use correct type for varargs snap test

uint64_t is passed in, but int was extracted. This fails on 32-bit builds.

Fixes: #5220
Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
12 years agomessages/MClientCapRelease: fix string output
Sage Weil [Fri, 31 May 2013 16:20:50 +0000 (09:20 -0700)]
messages/MClientCapRelease: fix string output

Use the vector size, not what is in the header, which is not yet filled in
for outgoing messages.

Signed-off-by: Sage Weil <sage@inktank.com>
12 years agoceph: Add missing usage "ceph osd blacklist ls"
David Zafman [Fri, 31 May 2013 23:30:11 +0000 (16:30 -0700)]
ceph: Add missing usage "ceph osd blacklist ls"

Signed-off-by: David Zafman <david.zafman@inktank.com>
12 years agoceph-fuse: create finisher threads after fork()
Sage Weil [Mon, 3 Jun 2013 04:21:51 +0000 (21:21 -0700)]
ceph-fuse: create finisher threads after fork()

The ObjectCacher and MonClient classes both instantiate Finisher
threads.  We need to make sure they are created *after* the fork(2)
or else the process will fail to join() them on shutdown, and the
threads will not exist while fuse is doing useful work.

Put CephFuse on the heap and move all this initalization into the child
block, and make sure errors are passed back to the parent.

Fix-proposed-by: Alexandre Marangone <alexandre.maragone@inktank.com>
Signed-off-by: Sage Weil <sage@inktank.com>
12 years agovstart.sh: make client logs unique
Sage Weil [Mon, 3 Jun 2013 03:59:03 +0000 (20:59 -0700)]
vstart.sh: make client logs unique

Signed-off-by: Sage Weil <sage@inktank.com>
12 years agoos/LevelDBStore: fix merge loop
Sage Weil [Mon, 3 Jun 2013 01:07:34 +0000 (18:07 -0700)]
os/LevelDBStore: fix merge loop

We were double-incrementing p, both in the for statement and in the
body.  While we are here, drop the unnecessary else's.

Signed-off-by: Sage Weil <sage@inktank.com>
12 years agoMerge pull request #337 from dalgaaf/wip-da-CID-medium.v2
Sage Weil [Sun, 2 Jun 2013 22:52:23 +0000 (15:52 -0700)]
Merge pull request #337 from dalgaaf/wip-da-CID-medium.v2

Fix several medium impact CID issues V2

Reviewed-by: Sage Weil <sage@inktank.com>
12 years agoMerge remote-tracking branch 'gh/next'
Sage Weil [Sun, 2 Jun 2013 21:48:04 +0000 (14:48 -0700)]
Merge remote-tracking branch 'gh/next'

12 years agomerge_old_entry arguments info and oe are changed to const because 339/head
Loic Dachary [Sun, 2 Jun 2013 10:50:13 +0000 (12:50 +0200)]
merge_old_entry arguments info and oe are changed to const because
there is no side effect.

The PGLog::clear function is added to reset all data members to the
same state they have after the object is constructed.

Signed-off-by: Loic Dachary <loic@dachary.org>
12 years agomon: fix uninitialized fields in MMonHealth
Sage Weil [Sat, 1 Jun 2013 04:16:54 +0000 (21:16 -0700)]
mon: fix uninitialized fields in MMonHealth

Backport: cuttlefish
Signed-off-by: Sage Weil <sage@inktank.com>
12 years agomon: start lease timer from peon_init()
Sage Weil [Sat, 1 Jun 2013 00:09:19 +0000 (17:09 -0700)]
mon: start lease timer from peon_init()

In the scenario:

 - leader wins, peons lose
 - leader sees it is too far behind on paxos and bootstraps
 - leader tries to sync with someone, waits for a quorum of the others
 - peons sit around forever waiting

The problem is that they never time out because paxos never issues a lease,
which is the normal timeout that lets them detect a leader failure.

Avoid this by starting the lease timeout as soon as we lose the election.
The timeout callback just does a bootstrap and does not rely on any other
state.

I see one possible danger here: there may be some "normal" cases where the
leader takes a long time to issue its first lease that we currently
tolerate, but won't with this new check in place.  I hope that raising
the lease interval/timeout or reducing the allowed paxos drift will make
that a non-issue.  If it is problematic, we will need a separate explicit
"i am alive" from the leader while it is getting ready to issue the lease
to prevent a live-lock.

Backport: cuttlefish, bobtail
Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Greg Farnum <greg@inktank.com>
12 years agomon: discard messages from disconnected clients
Sage Weil [Fri, 31 May 2013 05:52:21 +0000 (22:52 -0700)]
mon: discard messages from disconnected clients

If the client is not connected, discard the message.  They will
reconnect and resend anyway, so there is no point in processing it
twice (now and later).

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Greg Farnum <greg@inktank.com>
12 years agomon/Paxos: adjust trimming defaults up; rename options
Sage Weil [Thu, 30 May 2013 22:59:49 +0000 (15:59 -0700)]
mon/Paxos: adjust trimming defaults up; rename options

- trim more at a time (by an order of magnitude)
- rename fields to paxos_trim_{min,max}; only trim when there are min items
  that are trimmable, and trim at most max items at a time.
- adjust the paxos_service_trim_{min,max} values up by a factor of 2.

Since we are compacting every time we trim, adjusting these up mean less
frequent compactions and less overall work for the monitor.

Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Greg Farnum <greg@inktank.com>
12 years agoOSD: *inodes_hard_limit must be less than the fd limit
Samuel Just [Fri, 31 May 2013 22:11:02 +0000 (15:11 -0700)]
OSD: *inodes_hard_limit must be less than the fd limit

Also add a comment explaining that.

Fixes: #5224
Signed-off-by: Samuel Just <sam.just@inktank.com>
Reviewed-by: Greg Farnum <greg@inktank.com>
12 years agoOSD: tell them they died if they don't exist as well
Samuel Just [Fri, 31 May 2013 21:59:27 +0000 (14:59 -0700)]
OSD: tell them they died if they don't exist as well

OSDMap::get_down_at() asserts that the osd exists.

Fixes: #5223
Signed-off-by: Samuel Just <sam.just@inktank.com>
Reviewed-by: Sage Weil <sage@inktank.com>
12 years agoMerge branch 'wip-osd-leaks' into next
Sage Weil [Fri, 31 May 2013 21:48:51 +0000 (14:48 -0700)]
Merge branch 'wip-osd-leaks' into next

Reviewed-by: David Zafman <david.zafman@inktank.com>
12 years agoosd: fix msg leak on shutdown in ms_dispatch
Sage Weil [Fri, 31 May 2013 21:46:54 +0000 (14:46 -0700)]
osd: fix msg leak on shutdown in ms_dispatch

Reported-by: David Zafman <david.zafman@inktank.com>
Signed-off-by: Sage Weil <sage@inktank.com>
12 years agoosd: reset heartbeat peers during shutdown
Sage Weil [Fri, 31 May 2013 05:12:04 +0000 (22:12 -0700)]
osd: reset heartbeat peers during shutdown

This fixes a leak of the Connection's and related structures.

Signed-off-by: Sage Weil <sage@inktank.com>
12 years agomon/MonClient: fix leak of MMonGetVersionReply
Sage Weil [Fri, 31 May 2013 05:04:48 +0000 (22:04 -0700)]
mon/MonClient: fix leak of MMonGetVersionReply

Signed-off-by: Sage Weil <sage@inktank.com>
12 years agoosd: fix leak of MOSDMarkMeDown
Sage Weil [Fri, 31 May 2013 05:02:07 +0000 (22:02 -0700)]
osd: fix leak of MOSDMarkMeDown

Signed-off-by: Sage Weil <sage@inktank.com>
12 years agoMerge pull request #338 from alram/next
Sage Weil [Fri, 31 May 2013 19:47:24 +0000 (12:47 -0700)]
Merge pull request #338 from alram/next

Reviewed-by: Sage Weil <sage@inktank.com>
12 years agoupstart: handle upper case in cluster name and id 338/head
Alexandre Marangone [Fri, 31 May 2013 19:33:11 +0000 (12:33 -0700)]
upstart: handle upper case in cluster name and id

Signed-off-by: Alexandre Marangone <alexandre.marangone@inktank.com>
12 years agodoc: Added Java example for setting protocol to HTTP.
John Wilkins [Fri, 31 May 2013 18:15:20 +0000 (11:15 -0700)]
doc: Added Java example for setting protocol to HTTP.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agodoc: Text of diagram for osd_throttles.
John Wilkins [Fri, 31 May 2013 18:14:29 +0000 (11:14 -0700)]
doc: Text of diagram for osd_throttles.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agodoc: Omitted text diagram, and used literal include to text file.
John Wilkins [Fri, 31 May 2013 18:14:04 +0000 (11:14 -0700)]
doc: Omitted text diagram, and used literal include to text file.

Signed-off-by: John Wilkins <john.wilkins@inktank.com>
12 years agoPGLog: only add entry to caller_ops in add() if reqid_is_indexed()
Samuel Just [Fri, 31 May 2013 18:08:47 +0000 (11:08 -0700)]
PGLog: only add entry to caller_ops in add() if reqid_is_indexed()

Fixes: #5216
Signed-off-by: Samuel Just <sam.just@inktank.com>
Reviewed-by: Sage Weil <sage@inktank.com>
12 years agounit tests for pg_missing_t 327/head
Loic Dachary [Tue, 28 May 2013 21:34:59 +0000 (23:34 +0200)]
unit tests for pg_missing_t

All lines of code are tested. The conditions under which some methods
could corrupt the content of a pg_missing_t object have not been
investigated. Since the data members are public, the caller is
ultimately responsible for the consistency of the object and the
methods have no way to enforce it.

The semantics of is_missing have been discussed in
http://thread.gmane.org/gmane.comp.file-systems.ceph.devel/15280

Signed-off-by: Loic Dachary <loic@dachary.org>
12 years agoPG: don't write out pg map epoch every handle_activate_map
Samuel Just [Mon, 15 Apr 2013 23:33:48 +0000 (16:33 -0700)]
PG: don't write out pg map epoch every handle_activate_map

We don't actually need to write out the pg map epoch on every
activate_map as long as:
a) the osd does not trim past the oldest pg map persisted
b) the pg does update the persisted map epoch from time
to time.

To that end, we now keep a reference to the last map persisted.
The OSD already does not trim past the oldest live OSDMapRef.
Second, handle_activate_map will trim if the difference between
the current map and the last_persisted_map is large enough.

Fixes: #4731
Signed-off-by: Samuel Just <sam.just@inktank.com>
Reviewed-by: Greg Farnum <greg@inktank.com>
(cherry picked from commit 2c5a9f0e178843e7ed514708bab137def840ab89)

Conflicts:

src/common/config_opts.h
src/osd/PG.cc
- last_persisted_osdmap_ref gets set in the non-static
  PG::write_info

Conflicts:

src/osd/PG.cc

12 years ago.gitignore: add directory from coverity tools 337/head
Danny Al-Gaaf [Wed, 29 May 2013 14:25:50 +0000 (16:25 +0200)]
.gitignore: add directory from coverity tools

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/Server.cc: fix dereference after null check
Danny Al-Gaaf [Fri, 31 May 2013 17:07:45 +0000 (19:07 +0200)]
mds/Server.cc: fix dereference after null check

CID 716927 (#1 of 1): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing null pointer "diri->snaprealm" to function
  "SnapRealm::resolve_snapname(std::string const &

Make sure not to dereference diri->snaprealm.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/Server.cc: fix dereference after null check
Danny Al-Gaaf [Wed, 29 May 2013 14:13:47 +0000 (16:13 +0200)]
mds/Server.cc: fix dereference after null check

CID 716926 (#1 of 1): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing "mdr" to function
  "Server::apply_allocated_inos(MDRequest *)", which dereferences
  null "mdr->session".

Add assert for 'mdr' and assert for session in apply_allocated_inos().

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/Server.cc: fix dereference after null check
Danny Al-Gaaf [Wed, 29 May 2013 13:51:48 +0000 (15:51 +0200)]
mds/Server.cc: fix dereference after null check

Add assert to fix:

CID 716925 (#1 of 1): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing null pointer "straydn" to function
  "CDentry::get_dir() const", which dereferences it.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/Migrator.cc: fix dereference after null check
Danny Al-Gaaf [Wed, 29 May 2013 13:46:53 +0000 (15:46 +0200)]
mds/Migrator.cc: fix dereference after null check

Add asserts to check for 'dir' to fix:

CID 716924 (#1-5 of 5): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing null pointer "dir" to function "operator
  <<(std::ostream &, CDir &)", which dereferences it.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/Migrator.cc: fix dereference after null check
Danny Al-Gaaf [Wed, 29 May 2013 13:37:31 +0000 (15:37 +0200)]
mds/Migrator.cc: fix dereference after null check

Add assert for 'le' to fix:

CID 716923 (#1 of 1): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing null pointer "le" to function
  "LogEvent::get_start_off() const", which dereferences it.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/MDCache.cc: fix dereference null return value
Danny Al-Gaaf [Wed, 29 May 2013 13:24:39 +0000 (15:24 +0200)]
mds/MDCache.cc: fix dereference null return value

Add assert to fix:

CID 716994 (#1 of 1): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "dir" when
  calling "CDir::mark_dirty(version_t, LogSegment *)".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/MDCache.cc: fix dereference null return value
Danny Al-Gaaf [Wed, 29 May 2013 13:14:28 +0000 (15:14 +0200)]
mds/MDCache.cc: fix dereference null return value

CID 716993 (#1 of 2): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "in" when
  calling "operator <<(std::ostream &, CInode &)".

Add assert for 'in'.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/MDCache.cc: fix dereference after null check
Danny Al-Gaaf [Wed, 29 May 2013 13:04:13 +0000 (15:04 +0200)]
mds/MDCache.cc: fix dereference after null check

Add assert for 'parent' before call assert on parent->is_auth().

CID 716922 (#1 of 1): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing null pointer "parent" to function
  "MDSCacheObject::is_auth() const", which dereferences it.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/MDCache.cc: fix dereference after null check
Danny Al-Gaaf [Fri, 31 May 2013 16:56:21 +0000 (18:56 +0200)]
mds/MDCache.cc: fix dereference after null check

CID 716921 (#1 of 1): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing null pointer "dir" to function
  "operator <<(std::ostream &, CDir &)", which dereferences it.

CID 716992 (#1 of 1): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "dir"
  when calling "MDSCacheObject::is_auth() const".

Add assert for 'dir' before use it.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/Locker.cc: fix dereference after null check
Danny Al-Gaaf [Fri, 31 May 2013 16:49:30 +0000 (18:49 +0200)]
mds/Locker.cc: fix dereference after null check

CID 716919 (#1 of 1): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing null pointer "cap" to function
  "Capability::inc_suppress()", which dereferences it.

Check for 'cap' before use it as in other places of the function.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/Locker.cc: fix dereference after null check
Danny Al-Gaaf [Fri, 31 May 2013 16:42:20 +0000 (18:42 +0200)]
mds/Locker.cc: fix dereference after null check

CID 716918 (#1 of 1): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing null pointer "in" to function
  "MDSCacheObject::state_test(unsigned int) const", which
  dereferences it.

Add assert for 'in == NULL' before use it.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agomds/Locker.cc: fix dereference after null check
Danny Al-Gaaf [Fri, 31 May 2013 16:39:43 +0000 (18:39 +0200)]
mds/Locker.cc: fix dereference after null check

CID 716917 (#1 of 1): Dereference after null check (FORWARD_NULL)
  var_deref_model: Passing null pointer "in" to function
  "MDSCacheObject::state_test(unsigned int) const", which
  dereferences it.

Add assert for in == NULL before using it.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agobench/dumb_backend.cc: check return value of lseek()
Danny Al-Gaaf [Tue, 28 May 2013 12:41:30 +0000 (14:41 +0200)]
bench/dumb_backend.cc: check return value of lseek()

CID 743395 (#1 of 1): Unchecked return value from library (CHECKED_RETURN)
  check_return: Calling function "lseek(fd, offset, 0)" without checking
   return value. This library function may fail and return an error code.
  unchecked_value: No check of the return value of "lseek(fd, offset, 0)".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
12 years agobench/dumb_backend.cc: check return value of posix_fadvise()
Danny Al-Gaaf [Tue, 28 May 2013 12:26:29 +0000 (14:26 +0200)]
bench/dumb_backend.cc: check return value of posix_fadvise()

CID 743396 (#1 of 1): Unchecked return value from library (CHECKED_RETURN)
  check_return: Calling function "posix_fadvise(fd, offset, bl->length(), 4)"
   without checking return value. This library function may fail and return
   an error code.
  unchecked_value: No check of the return value of
   "posix_fadvise(fd, offset, bl->length(), 4)".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>