]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
14 years agoMerge remote branch 'origin/stable'
Sage Weil [Sat, 11 Jun 2011 00:37:29 +0000 (17:37 -0700)]
Merge remote branch 'origin/stable'

Conflicts:
src/dumpjournal.cc

14 years agoMerge remote branch 'origin/deb-pybind'
Sage Weil [Sat, 11 Jun 2011 00:35:05 +0000 (17:35 -0700)]
Merge remote branch 'origin/deb-pybind'

14 years agodebian: Move python-ceph into section python.
Tommi Virtanen [Sat, 11 Jun 2011 00:10:32 +0000 (17:10 -0700)]
debian: Move python-ceph into section python.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Strip and do -dbg magic for librgw too.
Tommi Virtanen [Sat, 11 Jun 2011 00:10:12 +0000 (17:10 -0700)]
debian: Strip and do -dbg magic for librgw too.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Fix copy-pasto in librgw1 control paragraph.
Tommi Virtanen [Sat, 11 Jun 2011 00:09:51 +0000 (17:09 -0700)]
debian: Fix copy-pasto in librgw1 control paragraph.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Depend on python-ceph in obsync.
Tommi Virtanen [Fri, 10 Jun 2011 23:58:36 +0000 (16:58 -0700)]
debian: Depend on python-ceph in obsync.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Depend on librgw1 in python-ceph.
Tommi Virtanen [Fri, 10 Jun 2011 23:58:15 +0000 (16:58 -0700)]
debian: Depend on librgw1 in python-ceph.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Package librgw.
Tommi Virtanen [Fri, 10 Jun 2011 23:43:55 +0000 (16:43 -0700)]
debian: Package librgw.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agopybind: Open shared libs by their major version.
Tommi Virtanen [Fri, 10 Jun 2011 23:14:13 +0000 (16:14 -0700)]
pybind: Open shared libs by their major version.

The *.so files are only in the -dev packages, and normal
operation should not require those. The major version
numbers represent incompatible API/ABI changes anyway.
The debian dependencies were already correctly including
the major version.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Make git ignore obsync, gceph* package dirs.
Tommi Virtanen [Fri, 10 Jun 2011 23:12:25 +0000 (16:12 -0700)]
debian: Make git ignore obsync, gceph* package dirs.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Prevent git ignore from recursing on *.substvars etc.
Tommi Virtanen [Fri, 10 Jun 2011 23:11:52 +0000 (16:11 -0700)]
debian: Prevent git ignore from recursing on *.substvars etc.

Should never have triggered but this is faster simpler
and correcter.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Make git ignore all of the *.debhelper files.
Tommi Virtanen [Fri, 10 Jun 2011 23:11:08 +0000 (16:11 -0700)]
debian: Make git ignore all of the *.debhelper files.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Dev packages no longer have soname in their names.
Tommi Virtanen [Fri, 10 Jun 2011 23:10:28 +0000 (16:10 -0700)]
debian: Dev packages no longer have soname in their names.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: Properly package the python bindings.
Tommi Virtanen [Fri, 10 Jun 2011 22:51:33 +0000 (15:51 -0700)]
debian: Properly package the python bindings.

Build-depend on python-support. Add binary package
python-ceph, making it contain all the ceph python
packages, regardless of their name; the modules are
too small to deserve their own debs.

Make python-ceph depend only on librados2 for now.
librgw is not packaged yet.

Dropping unnecessary build-dep on python-dev, that's
only needed for compiling C extensions, and we're using
ctypes.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agorgw: list bucket display the correct objects owners
Yehuda Sadeh [Fri, 10 Jun 2011 22:01:04 +0000 (15:01 -0700)]
rgw: list bucket display the correct objects owners

14 years agoboto_tool: add put_bucket_acl
Colin Patrick McCabe [Fri, 10 Jun 2011 21:55:35 +0000 (14:55 -0700)]
boto_tool: add put_bucket_acl

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agorgw: don't allow handing out object ownership
Yehuda Sadeh [Fri, 10 Jun 2011 20:24:29 +0000 (13:24 -0700)]
rgw: don't allow handing out object ownership

14 years agolibrados: remove useless reference holding
Yehuda Sadeh [Fri, 3 Jun 2011 21:31:20 +0000 (14:31 -0700)]
librados: remove useless reference holding

14 years agolibrados: get reference to the io context for the pending async ops
Yehuda Sadeh [Fri, 3 Jun 2011 21:09:34 +0000 (14:09 -0700)]
librados: get reference to the io context for the pending async ops

14 years agoheap_profiler: if log_dir is empty, don't try and log to root dir!
Greg Farnum [Fri, 10 Jun 2011 19:25:52 +0000 (12:25 -0700)]
heap_profiler: if log_dir is empty, don't try and log to root dir!

If log_dir was empty then the prefix would be of the form /mon.a
That isn't good, so fill it in so it writes to the current dir.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agocoverage.sh: use .lcov instead of .info to avoid confusion
Josh Durgin [Fri, 10 Jun 2011 18:31:08 +0000 (11:31 -0700)]
coverage.sh: use .lcov instead of .info to avoid confusion

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agoMerge remote branch 'origin/wip_coverage'
Josh Durgin [Fri, 10 Jun 2011 18:28:09 +0000 (11:28 -0700)]
Merge remote branch 'origin/wip_coverage'

Conflicts:
src/mon/Monitor.cc

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agorgw: remove required indexes when modifying user info
Yehuda Sadeh [Fri, 10 Jun 2011 17:07:55 +0000 (10:07 -0700)]
rgw: remove required indexes when modifying user info

Conflicts:

src/rgw/rgw_admin.cc

14 years agomon: Follow the Message rules when forwarding tells
Greg Farnum [Fri, 10 Jun 2011 00:41:39 +0000 (17:41 -0700)]
mon: Follow the Message rules when forwarding tells

My initial commit was naughty, fix that up here by
creating a new message for each mon and just copying
the command.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoThread: remove globals. Thread create must succeed
Colin Patrick McCabe [Fri, 10 Jun 2011 01:26:58 +0000 (18:26 -0700)]
Thread: remove globals. Thread create must succeed

Remove the references to global variables from Thread.h. They are really
unecessary. In every case, the printout is followed by an assert which
will deliver the exact same information.

Assert that thread creation succeeds. Nobody was checking the return
value of Thread::create() previously. Added a new function,
Thread::try_create(), which programmers can use if they do want to check
the value of Thread::create() and handle it appropriately.

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agoLogClient: pass in CephContext explicitly
Colin Patrick McCabe [Fri, 10 Jun 2011 01:04:39 +0000 (18:04 -0700)]
LogClient: pass in CephContext explicitly

Again, the Messenger passed to LogClient may be NULL, so pass in the
CephContext explicitly.

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agoMonitor: pass in CephContext explicitly
Colin Patrick McCabe [Fri, 10 Jun 2011 00:56:41 +0000 (17:56 -0700)]
Monitor: pass in CephContext explicitly

Sometimes we create a Monitor without a Messenger. So we can't pull the
CephContext out of the Messenger, because it may be NULL. Just specify
it explicitly in the Monitor constructor.

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agomds, mon, osd: with coverage enabled, exit(0) when SIGTERM is received
Josh Durgin [Fri, 10 Jun 2011 00:33:25 +0000 (17:33 -0700)]
mds, mon, osd: with coverage enabled, exit(0) when SIGTERM is received

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agoRevert "mon: add all_exit and exit commands"
Josh Durgin [Thu, 9 Jun 2011 23:57:52 +0000 (16:57 -0700)]
Revert "mon: add all_exit and exit commands"

This reverts commit 69092735c4b25c88ded58b17b1c198fafcf5931b.

14 years agoRevert "mds: allow mds to 'exit immediately'"
Josh Durgin [Thu, 9 Jun 2011 23:57:41 +0000 (16:57 -0700)]
Revert "mds: allow mds to 'exit immediately'"

This reverts commit c01961ff4b712a12e25e437adceae264273d7428.

14 years agoRevert "osd: add command to exit cleanly"
Josh Durgin [Thu, 9 Jun 2011 23:57:28 +0000 (16:57 -0700)]
Revert "osd: add command to exit cleanly"

This reverts commit 1cc78b6a864d36cbe1eda45890d7f361adb8201d.

14 years agomds: fix up MDCache::path_is_mine to remove a totally bogus assert.
Greg Farnum [Thu, 9 Jun 2011 23:53:22 +0000 (16:53 -0700)]
mds: fix up MDCache::path_is_mine to remove a totally bogus assert.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agomon: add new "tell" infrastructure.
Greg Farnum [Fri, 10 Jun 2011 00:21:33 +0000 (17:21 -0700)]
mon: add new "tell" infrastructure.

This lets you issue commands
like "ceph mon tell 0 heap start_profiler". Hurray!

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoCephContext: initialize module_type in ctor
Colin Patrick McCabe [Thu, 9 Jun 2011 23:21:23 +0000 (16:21 -0700)]
CephContext: initialize module_type in ctor

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agoCephContext: remove silly debug code
Colin Patrick McCabe [Thu, 9 Jun 2011 23:09:38 +0000 (16:09 -0700)]
CephContext: remove silly debug code

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agoDispatcher should take a CephContext argument
Colin Patrick McCabe [Thu, 9 Jun 2011 23:08:14 +0000 (16:08 -0700)]
Dispatcher should take a CephContext argument

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agomds: fix tcmalloc check.
Greg Farnum [Thu, 9 Jun 2011 22:26:13 +0000 (15:26 -0700)]
mds: fix tcmalloc check.

We can run commands to do things like start the profiler even if
it's not already running!

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agomds: xlock_finish should only do_issue in certain cases.
Greg Farnum [Mon, 6 Jun 2011 20:43:37 +0000 (13:43 -0700)]
mds: xlock_finish should only do_issue in certain cases.

We accidentally (we think) initialized this variable to true when
we want it to be false: we should only do_issue if there aren't
any remaining locks, not in all cases.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoMDiscoverReply: encode/decode wanted_ino.
Greg Farnum [Thu, 9 Jun 2011 20:25:25 +0000 (13:25 -0700)]
MDiscoverReply: encode/decode wanted_ino.

This wasn't encoded previously so it was always zero on the
receiver's end, which led to nasty hangs. :(

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agomdcache: correct error message.
Greg Farnum [Thu, 9 Jun 2011 00:24:22 +0000 (17:24 -0700)]
mdcache: correct error message.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agomds: replay: save the right dir!
Greg Farnum [Wed, 8 Jun 2011 23:52:57 +0000 (16:52 -0700)]
mds: replay: save the right dir!

We were using the wrong one and breaking replay.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agodebian: move gceph into a separate package
Sage Weil [Thu, 9 Jun 2011 17:25:21 +0000 (10:25 -0700)]
debian: move gceph into a separate package

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agotools/common: fix C_ObserverRefresh constructor
Colin Patrick McCabe [Thu, 9 Jun 2011 21:02:27 +0000 (14:02 -0700)]
tools/common: fix C_ObserverRefresh constructor

Fixes #1159

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agoReplicatedPG: make_writeable, use correct size for clone_size entry
Samuel Just [Thu, 9 Jun 2011 17:51:49 +0000 (10:51 -0700)]
ReplicatedPG: make_writeable, use correct size for clone_size entry

Previously, we used obs.oi.size for the clone size, but obs refers to
new_obs.  The clone's size should be the old size,
ctx->obc->obs.oi.size.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
14 years agogtest: add -lpthread to AM_LDFLAGS
Colin Patrick McCabe [Thu, 9 Jun 2011 18:22:20 +0000 (11:22 -0700)]
gtest: add -lpthread to AM_LDFLAGS

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agoman: update cosd man page to include info on flush-journal option.
Greg Farnum [Thu, 9 Jun 2011 18:10:57 +0000 (11:10 -0700)]
man: update cosd man page to include info on flush-journal option.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoMakefile.am: Add -lpthread to UNITTEST_LDADD
Colin Patrick McCabe [Thu, 9 Jun 2011 17:36:11 +0000 (10:36 -0700)]
Makefile.am: Add -lpthread to UNITTEST_LDADD

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agomkcephfs: fix ceph.conf reference
Sage Weil [Thu, 9 Jun 2011 16:02:32 +0000 (09:02 -0700)]
mkcephfs: fix ceph.conf reference

It's $conf (which is $dir/conf).

Reported-by: biyan chen <riby.chen@gmail.com>
Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoMakefile: remove ancient comment
Sage Weil [Wed, 8 Jun 2011 23:35:49 +0000 (16:35 -0700)]
Makefile: remove ancient comment

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoceph tools: de-globalize CephToolContext
Colin Patrick McCabe [Wed, 8 Jun 2011 22:42:46 +0000 (15:42 -0700)]
ceph tools: de-globalize CephToolContext

De-globalize CephToolContext. It's important to do this now because the
constructor for CephToolContext references the configuration (via
CephContext.)

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agomds: drop workaround for embedded null decoding
Sage Weil [Wed, 8 Jun 2011 22:57:46 +0000 (15:57 -0700)]
mds: drop workaround for embedded null decoding

We removed the embedded null check recently, 9b37f4f, so this workaround
isn't needed.

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agomon: weaken pool creation caps check
Sage Weil [Wed, 8 Jun 2011 21:55:00 +0000 (14:55 -0700)]
mon: weaken pool creation caps check

Allow a pool creation if we specify an auid but are allowed to create
buckets as anybody.

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agorgw_admin: user info dumps auid
Yehuda Sadeh [Wed, 8 Jun 2011 21:54:14 +0000 (14:54 -0700)]
rgw_admin: user info dumps auid

14 years agomoncaps: whitespace
Sage Weil [Wed, 8 Jun 2011 21:53:22 +0000 (14:53 -0700)]
moncaps: whitespace

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agorgw_admin: can reset auid
Yehuda Sadeh [Wed, 8 Jun 2011 21:13:37 +0000 (14:13 -0700)]
rgw_admin: can reset auid

14 years agoMerge remote branch 'origin/mds_rename'
Sage Weil [Wed, 8 Jun 2011 21:00:10 +0000 (14:00 -0700)]
Merge remote branch 'origin/mds_rename'

14 years agomds: rename: remove illicit assert.
Greg Farnum [Wed, 8 Jun 2011 21:13:28 +0000 (14:13 -0700)]
mds: rename: remove illicit assert.

We actually do want witnesses who aren't auth for anything
to do journaling in some cases, so kill the assert.
That also negates the need for the not_journaling check.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agomds: try_trim_non_auth_subtree if we rename a dir away from a non-auth subtree
Sage Weil [Wed, 8 Jun 2011 20:29:21 +0000 (13:29 -0700)]
mds: try_trim_non_auth_subtree if we rename a dir away from a non-auth subtree

It's possible we have non-auth metadata only because we have a subtree
nested beneath. If we rename a directory out of a non-auth subtree, we
should try to trim any non-auth content from that subtree that may now
be possible due to the child subtrees being linked elsewhere.

Fixes: #1146
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: use CDIR_AUTH_UNDEF where possible
Sage Weil [Wed, 8 Jun 2011 20:27:34 +0000 (13:27 -0700)]
mds: use CDIR_AUTH_UNDEF where possible

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: remove unlinked metadata from cache on replay
Sage Weil [Wed, 8 Jun 2011 20:18:07 +0000 (13:18 -0700)]
mds: remove unlinked metadata from cache on replay

If we replay a metablob that unlinks something, throw it out immediately.
Recursively.  This comes up when:
 - we rename a file from one mds to another, and we replay the event on
   the source mds.  the inode gets thrown out.
 - we rename a directory from one mds to another, and when journaled, the
   source mds had no nested metadata.  same thing: we throw it out.  we
   may have something in our cache nested beneath that, though, that was
   since committed and such, but the fact that we didn't journal it being
   reattached elsewhere implies that it was clean and gone when our event
   was journaled, and we can throw it all out.  recursively.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoFix build errors in unit tests
Colin Patrick McCabe [Wed, 8 Jun 2011 19:28:23 +0000 (12:28 -0700)]
Fix build errors in unit tests

libcommon uses symbols from the crypto libraries, so they must appear on
the link line whenever libcommon appears.  Later, we may want to revisit
this dependency; however, right now, having unit tests that build
consistently is pretty important.

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agomonitorstore: return error codes for consistency
Colin Patrick McCabe [Fri, 27 May 2011 22:41:17 +0000 (15:41 -0700)]
monitorstore: return error codes for consistency

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agoFix typo in usage output for --num-osds
Sam Lang [Wed, 8 Jun 2011 17:59:12 +0000 (12:59 -0500)]
Fix typo in usage output for --num-osds

This patch fixes the typo in the usage description to match the actual argument string.

Signed-off-by: Sam Lang <samlang@gmail.com>
Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoFix segfault caused by invalid argument string.
Sam Lang [Wed, 8 Jun 2011 17:59:11 +0000 (12:59 -0500)]
Fix segfault caused by invalid argument string.

This patchset includes minor fixes to the crushtool utility.  If an invalid bucket type is speicifed on the command line, the code was iterating through bucket_types for the length of the static array, but the last entry in that array has null (0) values, which was causing a segfault.  This patch just checks that bucket_types[i].name is non-null instead.  Also, if the wrong bucket type or algorithm is specified, prints the usage string on exit.

Signed-off-by: Sam Lang <samlang@gmail.com>
Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoqa: test witness subtree adjustment
Sage Weil [Wed, 8 Jun 2011 18:22:26 +0000 (11:22 -0700)]
qa: test witness subtree adjustment

This exercises the mds at least; we don't have a way to verify mds
behavior currently.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoqa: test_sync_io
Sage Weil [Wed, 8 Jun 2011 05:09:24 +0000 (22:09 -0700)]
qa: test_sync_io

Currently only tests the read path for O_DIRECT and sync (if the ioctl is
in place).  Also currently crashes the kclient with

 read_direct buf_align 0 offset 4190720 len 4096

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoqa: add dir rename tests
Sage Weil [Wed, 8 Jun 2011 03:49:45 +0000 (20:49 -0700)]
qa: add dir rename tests

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: open renamed import child frags during journal replay
Sage Weil [Wed, 8 Jun 2011 03:48:52 +0000 (20:48 -0700)]
mds: open renamed import child frags during journal replay

Open up any child frags of the imported renamed inode that are noted in
the journal event.  (Note we blindly open up that list here; it's up to the
journaler to only populate it when appropriate.)  If the listed frags are
not already open, open them up and set the dir_auth to unknown; presumably
they belong to the rename source/exporter.  If we already had them open,
then the adjust_subtree_after_rename call above will have caught them and
already done the necessary subtree adjustment.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: journal open srci frags on srci import (master)
Sage Weil [Wed, 8 Jun 2011 03:46:42 +0000 (20:46 -0700)]
mds: journal open srci frags on srci import (master)

If we are importing the renamed inode, and it is a directory, journal a
list of all open dirfrags (currently, this is actually all frags) so that
we can open them up during journal replay.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: journal renames on witnesses if we have nested subtrees
Sage Weil [Wed, 8 Jun 2011 03:43:29 +0000 (20:43 -0700)]
mds: journal renames on witnesses if we have nested subtrees

If a rename witness has any subtrees that are nested beneath the renamed
directory, we need to journal the rename event so that our cache is
properly updated on journal replay.

Further, if we are exporting srci, we also need to journal the dest
(even if we aren't auth for destdn) if we have any open dirfrags because
those will turn into nested subtrees shortly.

We still need to ensure that the cache is properly trimmed during replay.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: CDir::contains() should use projected hierarchy
Sage Weil [Wed, 8 Jun 2011 03:40:39 +0000 (20:40 -0700)]
mds: CDir::contains() should use projected hierarchy

The only current callers are in resolve stage, when nothing is projected.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agore-fix ignore return value change
Colin Patrick McCabe [Tue, 7 Jun 2011 23:14:26 +0000 (16:14 -0700)]
re-fix ignore return value change

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agomds: fix check for no-op rename of two links to the same inode
Sage Weil [Tue, 7 Jun 2011 22:13:04 +0000 (15:13 -0700)]
mds: fix check for no-op rename of two links to the same inode

touch a
ln a b
mv a b

is a no-op, according to posix.  Move the check earlier.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agocfuse: really ignore write() return value
Colin Patrick McCabe [Tue, 7 Jun 2011 21:26:58 +0000 (14:26 -0700)]
cfuse: really ignore write() return value

Hopefully this will make gcc stop complaining. The void cast no longer
seems to silence unchecked return code errors, on gitbuilder at least.

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agoMerge remote branch 'origin/wip_gcov'
Josh Durgin [Tue, 7 Jun 2011 20:57:28 +0000 (13:57 -0700)]
Merge remote branch 'origin/wip_gcov'

14 years agoqa: add rename dir checks
Sage Weil [Tue, 7 Jun 2011 20:34:57 +0000 (13:34 -0700)]
qa: add rename dir checks

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agocoverage: add ceph-coverage to run something with the right GCOV_PREFIX_STRIP
Josh Durgin [Tue, 7 Jun 2011 17:06:58 +0000 (10:06 -0700)]
coverage: add ceph-coverage to run something with the right GCOV_PREFIX_STRIP

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agoMakefile.am: add check-coverage to get coverage of 'make check'
Josh Durgin [Mon, 6 Jun 2011 18:14:17 +0000 (11:14 -0700)]
Makefile.am: add check-coverage to get coverage of 'make check'

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agoMakefile.am: install gcno files
Josh Durgin [Fri, 3 Jun 2011 20:33:13 +0000 (13:33 -0700)]
Makefile.am: install gcno files

This is needed so that coverage data can be generated from the
gitbuilder tarballs.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agoMakefile.am: clean gcno and gcda files in "make clean"
Josh Durgin [Fri, 3 Jun 2011 01:51:02 +0000 (18:51 -0700)]
Makefile.am: clean gcno and gcda files in "make clean"

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agoqa: rename tests
Sage Weil [Tue, 7 Jun 2011 20:27:31 +0000 (13:27 -0700)]
qa: rename tests

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: rename: add missing pop_and_dirty_projected_inode calls
Sage Weil [Tue, 7 Jun 2011 20:21:46 +0000 (13:21 -0700)]
mds: rename: add missing pop_and_dirty_projected_inode calls

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: rename: use temp *in in _rename_apply
Sage Weil [Tue, 7 Jun 2011 20:24:35 +0000 (13:24 -0700)]
mds: rename: use temp *in in _rename_apply

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: rename: move unlink out of every possible branch
Sage Weil [Tue, 7 Jun 2011 20:24:11 +0000 (13:24 -0700)]
mds: rename: move unlink out of every possible branch

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agotest/bufferlist: add copy_all test
Colin Patrick McCabe [Tue, 7 Jun 2011 19:05:50 +0000 (12:05 -0700)]
test/bufferlist: add copy_all test

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agocoverage: add helper script to get coverage for a local test
Josh Durgin [Mon, 6 Jun 2011 20:52:35 +0000 (13:52 -0700)]
coverage: add helper script to get coverage for a local test

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agomon: add all_exit and exit commands
Josh Durgin [Tue, 31 May 2011 22:51:41 +0000 (15:51 -0700)]
mon: add all_exit and exit commands

all_exit makes each daemon exit(0), for gcov data collection.
exit causes cmon to do this.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agomds: allow mds to 'exit immediately'
Josh Durgin [Tue, 31 May 2011 22:48:21 +0000 (15:48 -0700)]
mds: allow mds to 'exit immediately'

This is temporary until shutting down cleans up well.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agomon: ceph tell mds * is a valid command
Josh Durgin [Tue, 31 May 2011 21:15:01 +0000 (14:15 -0700)]
mon: ceph tell mds * is a valid command

Previously this fell through and returned -EINVAL to the user.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agoosd: add command to exit cleanly
Josh Durgin [Sat, 28 May 2011 00:40:28 +0000 (17:40 -0700)]
osd: add command to exit cleanly

This is required for gcov to work on daemons since the coverage data
is written atexit, and the function that writes the data is not
exported.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agoconfigure: add option for building with gcov coverage support
Josh Durgin [Sat, 28 May 2011 00:37:43 +0000 (17:37 -0700)]
configure: add option for building with gcov coverage support

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agotest/bufferlist.cc: retab for consistency
Colin Patrick McCabe [Tue, 7 Jun 2011 18:58:06 +0000 (11:58 -0700)]
test/bufferlist.cc: retab for consistency

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agocfuse.cc: fix warning
Colin Patrick McCabe [Tue, 7 Jun 2011 18:56:05 +0000 (11:56 -0700)]
cfuse.cc: fix warning

We genuinely don't care about the return code we get back from this call
to write(2). So cast the result to void to tell gcc that we don't care.

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agobufferlist::iterator: add copy_all, use in KeyRing
Colin Patrick McCabe [Tue, 7 Jun 2011 18:40:48 +0000 (11:40 -0700)]
bufferlist::iterator: add copy_all, use in KeyRing

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agomds: rename: fix oldin pop
Sage Weil [Tue, 7 Jun 2011 18:25:39 +0000 (11:25 -0700)]
mds: rename: fix oldin pop

- make the pop match position with the project in prepare
- don't pop on linkmerge, since we don't project in that case

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: rename: some cleanup
Sage Weil [Tue, 7 Jun 2011 18:24:50 +0000 (11:24 -0700)]
mds: rename: some cleanup

- add oldin temp
- make if conditions match between _prepare and _apply

no functional changes.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoclient: fix rename request target selection
Sage Weil [Tue, 7 Jun 2011 18:23:54 +0000 (11:23 -0700)]
client: fix rename request target selection

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoclient: fix mds selection for unlink
Sage Weil [Tue, 7 Jun 2011 18:11:07 +0000 (11:11 -0700)]
client: fix mds selection for unlink

It was broken when a remote link target was on another mds.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoclient: make debug prints for choose_target_mds more helpful
Sage Weil [Tue, 7 Jun 2011 18:08:02 +0000 (11:08 -0700)]
client: make debug prints for choose_target_mds more helpful

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoclient: allow caps to be dropped on another inode for requests
Sage Weil [Tue, 7 Jun 2011 18:07:44 +0000 (11:07 -0700)]
client: allow caps to be dropped on another inode for requests

We need the ability to drop caps on another inode that isn't req->inode
or req->old_inode in the request struct.

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