]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
14 years agoinit-ceph: don't umount btrfs by default
Sage Weil [Sat, 24 Sep 2011 21:08:07 +0000 (14:08 -0700)]
init-ceph: don't umount btrfs by default

As an admin I find this very annoying, even though it isn't strictly
symmetrical with the mount behavior.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agorgw: only require content-length to be set on non-acl puts
Greg Farnum [Fri, 23 Sep 2011 22:43:09 +0000 (15:43 -0700)]
rgw: only require content-length to be set on non-acl puts

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoRevert "rgw: tolerate missing content-length header on canned ACL puts"
Greg Farnum [Fri, 23 Sep 2011 22:41:56 +0000 (15:41 -0700)]
Revert "rgw: tolerate missing content-length header on canned ACL puts"

This reverts commit 05b06e807ef20c7fe1bd7c7abbeecd656d2280c0.

Don't be stupid when an empty content-length can only be on ACL puts!

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoMerge remote branch 'gh/stable'
Sage Weil [Fri, 23 Sep 2011 23:00:24 +0000 (16:00 -0700)]
Merge remote branch 'gh/stable'

14 years agoman: c* -> ceph-* rename: Regenerate manpages.
Tommi Virtanen [Fri, 23 Sep 2011 22:54:46 +0000 (15:54 -0700)]
man: c* -> ceph-* rename: Regenerate manpages.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Fix reStructuredText formatting warnings.
Tommi Virtanen [Fri, 23 Sep 2011 22:52:49 +0000 (15:52 -0700)]
doc: Fix reStructuredText formatting warnings.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agoMakefile: c* -> ceph-* rename: missed cdebugpack in CLEANFILES.
Tommi Virtanen [Fri, 23 Sep 2011 22:46:29 +0000 (15:46 -0700)]
Makefile: c* -> ceph-* rename: missed cdebugpack in CLEANFILES.

make distcheck said:

  ERROR: files left in build directory after distclean:
  ./src/ceph-debugpack
  make[1]: *** [distcleancheck] Error 1

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agoMakefile: Add missing header test/unit.h
Tommi Virtanen [Fri, 23 Sep 2011 22:36:26 +0000 (15:36 -0700)]
Makefile: Add missing header test/unit.h

Used to fail "make distcheck".

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years ago.gitignore: distcheck temporary directory.
Tommi Virtanen [Fri, 23 Sep 2011 22:35:30 +0000 (15:35 -0700)]
.gitignore: distcheck temporary directory.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agoMakefile: include run-cli-tests-maybe-unset-ccache in dist tarball.
Tommi Virtanen [Fri, 23 Sep 2011 22:15:13 +0000 (15:15 -0700)]
Makefile: include run-cli-tests-maybe-unset-ccache in dist tarball.

Apparently "make distcheck" has been broken for 3 months;
I find that hard to believe, but that's what it looks like.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agoceph-run: c* -> ceph-* rename: Use ceph-run as stderr prefix.
Tommi Virtanen [Fri, 23 Sep 2011 22:06:58 +0000 (15:06 -0700)]
ceph-run: c* -> ceph-* rename: Use ceph-run as stderr prefix.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agoceph-debugpack: c* -> ceph-* rename: use "ceph-debugpack" as temp dir name too.
Tommi Virtanen [Fri, 23 Sep 2011 22:06:40 +0000 (15:06 -0700)]
ceph-debugpack: c* -> ceph-* rename: use "ceph-debugpack" as temp dir name too.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agoudev: c* -> ceph-* rename: missed crbdnamer.
Tommi Virtanen [Fri, 23 Sep 2011 22:05:44 +0000 (15:05 -0700)]
udev: c* -> ceph-* rename: missed crbdnamer.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodebian: c* -> ceph-* rename: missed csyn, crbdnamer.
Tommi Virtanen [Fri, 23 Sep 2011 22:05:25 +0000 (15:05 -0700)]
debian: c* -> ceph-* rename: missed csyn, crbdnamer.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agorpm: c* -> ceph-* rename: missed crbdnamer, cdebugpack.
Tommi Virtanen [Fri, 23 Sep 2011 21:55:20 +0000 (14:55 -0700)]
rpm: c* -> ceph-* rename: missed crbdnamer, cdebugpack.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agoMakefile: c* -> ceph-* rename: missed crun.
Tommi Virtanen [Fri, 23 Sep 2011 21:54:16 +0000 (14:54 -0700)]
Makefile: c* -> ceph-* rename: missed crun.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: v0.35 is out, remove rpm build workaround.
Tommi Virtanen [Thu, 22 Sep 2011 18:29:12 +0000 (11:29 -0700)]
doc: v0.35 is out, remove rpm build workaround.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Add index into the sidebar.
Tommi Virtanen [Thu, 22 Sep 2011 18:24:28 +0000 (11:24 -0700)]
doc: Add index into the sidebar.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Search page is always in sidebar, no need to have it on page.
Tommi Virtanen [Thu, 22 Sep 2011 18:01:30 +0000 (11:01 -0700)]
doc: Search page is always in sidebar, no need to have it on page.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Add a space after sudoers "NOPASSWD:", as that seems more common.
Tommi Virtanen [Thu, 22 Sep 2011 17:54:08 +0000 (10:54 -0700)]
doc: Add a space after sudoers "NOPASSWD:", as that seems more common.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Add index entries, remove glossary as it's practically replaced by the index.
Tommi Virtanen [Thu, 22 Sep 2011 17:53:34 +0000 (10:53 -0700)]
doc: Add index entries, remove glossary as it's practically replaced by the index.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Leftovers of the c* -> ceph-* rename.
Tommi Virtanen [Fri, 23 Sep 2011 20:39:05 +0000 (13:39 -0700)]
doc: Leftovers of the c* -> ceph-* rename.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agorgw: tolerate missing content-length header on canned ACL puts
Greg Farnum [Fri, 23 Sep 2011 21:47:10 +0000 (14:47 -0700)]
rgw: tolerate missing content-length header on canned ACL puts

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agomon: remember source client address in routed requests
Henry C Chang [Thu, 11 Nov 2010 03:40:39 +0000 (11:40 +0800)]
mon: remember source client address in routed requests

when we resend_routed_requests, the source client address is lost.
This may cause problems. For example, if we resend an mds beacon
(boot) to a new monitor leader, the new mdsmap will contain a new
mds entry without IP address.

To reproduce this bug:
1. deploy a cluster with 3 mons.
2. let active mds send beacon to mon0; standby mds send becaon to mon2
3. gdb attach to mon2 to make it unresponsive and make standby mds laggy.
4. gdb attach to mon0 to make it unresponsive and make active mds laggy.
5. detach mon2, then the standby mds will become active.
6. ceph mds dump -o - shows the active mds address is :/0

Signed-off-by: Henry C Chang <henry_c_chang@tcloudcomputing.com>
Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoosd: fix race between handle_osd_ping and handle_osd_map
Sage Weil [Fri, 23 Sep 2011 19:53:39 +0000 (12:53 -0700)]
osd: fix race between handle_osd_ping and handle_osd_map

If handle_osd_map is in progress and handle_osd_ping doesn't have the
map lock, we can't call osdmap->get_inst() in send_still_alive().  Keep
the entity_inst_t in the failure_pending map so that we don't need to.

osd/OSDMap.h: In function 'entity_inst_t OSDMap::get_inst(int)', in thread '0x7fda6a46b710'
osd/OSDMap.h: 477: FAILED assert(is_up(osd))
 ceph version 0.24.1 (commit:e06fb657842379259826f3d9215101fc14575fbd)
 1: (OSD::send_still_alive(int)+0x1b9) [0x4dd1b9]
 2: (OSD::handle_osd_ping(MOSDPing*)+0x716) [0x4f6446]
 3: (OSD::heartbeat_dispatch(Message*)+0x36) [0x4f6666]
 4: (SimpleMessenger::dispatch_entry()+0x882) [0x46f002]
 5: (SimpleMessenger::DispatchThread::entry()+0x1c) [0x465fac]
 6: (()+0x6a3a) [0x7fda7835aa3a]
 7: (clone()+0x6d) [0x7fda76f7777d]

Reported-by: Henry C Chang <henry_c_chang@tcloudcomputing.com>
Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoMakefile: drop useless all_sources thing
Sage Weil [Fri, 23 Sep 2011 16:58:19 +0000 (09:58 -0700)]
Makefile: drop useless all_sources thing

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agorename source files c* -> ceph-*
Sage Weil [Fri, 23 Sep 2011 16:57:45 +0000 (09:57 -0700)]
rename source files c* -> ceph-*

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomisc: use strncpy to prevent buffer overflow
Henry C Chang [Thu, 24 Feb 2011 02:35:51 +0000 (10:35 +0800)]
misc: use strncpy to prevent buffer overflow

14 years agoceph-elaster: add parentheses around macros
Henry C Chang [Thu, 14 Oct 2010 10:23:44 +0000 (18:23 +0800)]
ceph-elaster: add parentheses around macros

14 years agotest_store: parse args, don't link librados
Sage Weil [Fri, 23 Sep 2011 16:40:19 +0000 (09:40 -0700)]
test_store: parse args, don't link librados

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agocrushtool: add unit test for adding items to map
Sage Weil [Fri, 23 Sep 2011 04:11:34 +0000 (21:11 -0700)]
crushtool: add unit test for adding items to map

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agocrushtool: fix argument parsing
Sage Weil [Fri, 23 Sep 2011 04:01:22 +0000 (21:01 -0700)]
crushtool: fix argument parsing

Reported by: Henry C Chang <henry.cy.chang@gmail.com>
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agocrushtool: crush_finalize on any map modification
Sage Weil [Fri, 23 Sep 2011 04:00:52 +0000 (21:00 -0700)]
crushtool: crush_finalize on any map modification

This recalculates max_devices and the parent maps.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoRevert "crush: refuse to add item >= max_devices"
Sage Weil [Fri, 23 Sep 2011 03:56:32 +0000 (20:56 -0700)]
Revert "crush: refuse to add item >= max_devices"

This reverts commit 58f98e7afc364d28a385adc7ef0fee2291d70c17.

max_devices only affects the size of the parent arrays, which aren't allocated
until crush_finalize().  No problems here.

14 years agoMerge branch 'stable'
Sage Weil [Thu, 22 Sep 2011 23:20:02 +0000 (16:20 -0700)]
Merge branch 'stable'

14 years agoMerge branch 'wip-names'
Sage Weil [Thu, 22 Sep 2011 23:19:50 +0000 (16:19 -0700)]
Merge branch 'wip-names'

14 years agoman: rebuild manpages
Sage Weil [Thu, 22 Sep 2011 23:18:19 +0000 (16:18 -0700)]
man: rebuild manpages

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agodoc: more c* -> ceph-* renames
Sage Weil [Thu, 22 Sep 2011 22:16:56 +0000 (15:16 -0700)]
doc: more c* -> ceph-* renames

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agorbd: set default pool when none is specified
Josh Durgin [Thu, 22 Sep 2011 22:39:58 +0000 (15:39 -0700)]
rbd: set default pool when none is specified

096e3b6353e5035362cffdcbd2e4a4f5572aa2ba broke this by only using
set_pool_image_name for commands that accept the snapshot
parameter. This whole undocumented format parsing should be reworked
or removed at some point.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
14 years agolibceph -> libcephfs
Sage Weil [Thu, 22 Sep 2011 22:07:19 +0000 (15:07 -0700)]
libceph -> libcephfs

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoc* -> ceph-*
Sage Weil [Wed, 21 Sep 2011 23:28:43 +0000 (16:28 -0700)]
c* -> ceph-*

Hopefully I didn't miss too much...

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agomount.ceph: use ":/" instead of just ":" as ip/path delimiter
Sage Weil [Thu, 22 Sep 2011 21:46:56 +0000 (14:46 -0700)]
mount.ceph: use ":/" instead of just ":" as ip/path delimiter

This is tolerant of colons in the mount subdir.

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoaddr_parsing: null terminate safe_cat result
Sage Weil [Thu, 22 Sep 2011 21:45:44 +0000 (14:45 -0700)]
addr_parsing: null terminate safe_cat result

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agomount.ceph: fix use-after-free
Sage Weil [Thu, 22 Sep 2011 21:44:38 +0000 (14:44 -0700)]
mount.ceph: fix use-after-free

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agotest/rados-api/test.cc: Add ability to set client id
Samuel Just [Tue, 20 Sep 2011 00:50:10 +0000 (17:50 -0700)]
test/rados-api/test.cc: Add ability to set client id

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
14 years agotest/test_stress_watch.cc: added simple watch stress test
Samuel Just [Mon, 19 Sep 2011 23:27:03 +0000 (16:27 -0700)]
test/test_stress_watch.cc: added simple watch stress test

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
14 years agoPG: set log.backlog to false on corrupt log
Samuel Just [Thu, 22 Sep 2011 16:46:12 +0000 (09:46 -0700)]
PG: set log.backlog to false on corrupt log

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
14 years agoPG: set log.backlog to false on corrupt log
Samuel Just [Thu, 22 Sep 2011 16:46:12 +0000 (09:46 -0700)]
PG: set log.backlog to false on corrupt log

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
14 years agovstart: debug filestore = 20
Sage Weil [Wed, 21 Sep 2011 23:26:57 +0000 (16:26 -0700)]
vstart: debug filestore = 20

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoosd: fix PG::copy_after vs backlog
Sage Weil [Wed, 21 Sep 2011 22:46:37 +0000 (15:46 -0700)]
osd: fix PG::copy_after vs backlog

If you call copy_after(..., 0) on a log with a backlog, you get all the
backlog entries, but no backlog flag.  That's invalid.  You either need
the _complete_ backlog + the flag, or no backlog entries; getting only
some of them is useless information.

Make copy_after stop when it hits the tail.  Callers who need the backlog
are already checking for that and copying the whole log as appropriate.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomds: fix traverse snap vs forward check
Sage Weil [Wed, 21 Sep 2011 18:39:03 +0000 (11:39 -0700)]
mds: fix traverse snap vs forward check

This should compare against the forward attempt, not retry attempt.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agorbd: fix progress redraw
Sage Weil [Wed, 21 Sep 2011 18:23:21 +0000 (11:23 -0700)]
rbd: fix progress redraw

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agodoc: Content for Getting Started with cephfs and rbd.
Tommi Virtanen [Wed, 21 Sep 2011 21:55:11 +0000 (14:55 -0700)]
doc: Content for Getting Started with cephfs and rbd.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Content for Getting Started with RADOS.
Tommi Virtanen [Wed, 21 Sep 2011 20:43:32 +0000 (13:43 -0700)]
doc: Content for Getting Started with RADOS.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Structure for Getting Started.
Tommi Virtanen [Wed, 21 Sep 2011 18:55:37 +0000 (11:55 -0700)]
doc: Structure for Getting Started.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Separate key management from mounting.
Tommi Virtanen [Wed, 21 Sep 2011 00:02:15 +0000 (17:02 -0700)]
doc: Separate key management from mounting.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Move config reference to top-level.
Tommi Virtanen [Tue, 20 Sep 2011 23:57:36 +0000 (16:57 -0700)]
doc: Move config reference to top-level.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Split data placement into concrete operations and recommendations.
Tommi Virtanen [Tue, 20 Sep 2011 23:39:54 +0000 (16:39 -0700)]
doc: Split data placement into concrete operations and recommendations.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Reorganize ops/manage/
Tommi Virtanen [Tue, 20 Sep 2011 23:33:20 +0000 (16:33 -0700)]
doc: Reorganize ops/manage/

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Move recommendations under /rec.
Tommi Virtanen [Tue, 20 Sep 2011 22:59:07 +0000 (15:59 -0700)]
doc: Move recommendations under /rec.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Move ops/grow under ops/manage.
Tommi Virtanen [Tue, 20 Sep 2011 22:51:16 +0000 (15:51 -0700)]
doc: Move ops/grow under ops/manage.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Split manage into multiple pages.
Tommi Virtanen [Tue, 20 Sep 2011 22:47:44 +0000 (15:47 -0700)]
doc: Split manage into multiple pages.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Split install into multiple pages.
Tommi Virtanen [Tue, 20 Sep 2011 22:45:08 +0000 (15:45 -0700)]
doc: Split install into multiple pages.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agodoc: Clean reStructuredText syntax.
Tommi Virtanen [Tue, 20 Sep 2011 22:22:01 +0000 (15:22 -0700)]
doc: Clean reStructuredText syntax.

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agoMerge branch 'stable'
Sage Weil [Wed, 21 Sep 2011 20:37:45 +0000 (13:37 -0700)]
Merge branch 'stable'

14 years agoclient: tear down dir when setting I_COMPLETE on empty
Sage Weil [Wed, 21 Sep 2011 17:10:54 +0000 (10:10 -0700)]
client: tear down dir when setting I_COMPLETE on empty

If the dir is supposed to be empty and we are setting I_COMPLETE, empty
it out and close it.  This ensures we don't return bad results on a
subsequent readdir().

_Maybe_ related to #1509.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agorados: accept '-b' as an argument.
Greg Farnum [Wed, 21 Sep 2011 16:50:29 +0000 (09:50 -0700)]
rados: accept '-b' as an argument.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agov0.35 v0.35
Sage Weil [Wed, 21 Sep 2011 16:36:14 +0000 (09:36 -0700)]
v0.35

14 years agoMakefile: include config_opts.h
Sage Weil [Wed, 21 Sep 2011 16:46:32 +0000 (09:46 -0700)]
Makefile: include config_opts.h

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoMerge branch 'master' of github.com:NewDreamNetwork/ceph
Greg Farnum [Wed, 21 Sep 2011 16:42:41 +0000 (09:42 -0700)]
Merge branch 'master' of github.com:NewDreamNetwork/ceph

14 years agoosd: set reply version for dup requests
Sage Weil [Mon, 19 Sep 2011 23:50:48 +0000 (16:50 -0700)]
osd: set reply version for dup requests

If we get a dup request, set the version in the reply.  That means the
client knows the client was successful and committed, and they know the
version.  They don't get anything else (e.g., data payload resulting from
mutations).

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoauth: keyring: whitespace
Sage Weil [Wed, 21 Sep 2011 16:28:48 +0000 (09:28 -0700)]
auth: keyring: whitespace

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agomon: make fsync vs sync threshold configurable
Sage Weil [Wed, 21 Sep 2011 16:28:38 +0000 (09:28 -0700)]
mon: make fsync vs sync threshold configurable

If mon+osd+client are on the same machine, sync() can deadlock.  Setting it
to 0 disables the big sync.  And the cutoff is now tunable.

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agomon: remove unused MonitorStore::sync()
Sage Weil [Wed, 21 Sep 2011 16:26:37 +0000 (09:26 -0700)]
mon: remove unused MonitorStore::sync()

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agomkcephfs: create /var/run/ceph (or wherever pid_file and admin_socket live)
Sage Weil [Wed, 21 Sep 2011 00:02:04 +0000 (17:02 -0700)]
mkcephfs: create /var/run/ceph (or wherever pid_file and admin_socket live)

Fixes: #1546
Signed-off-by: Sage Weil <sage@newdream.net>
14 years agocconf: do not common_init_finish
Sage Weil [Wed, 21 Sep 2011 00:01:38 +0000 (17:01 -0700)]
cconf: do not common_init_finish

All that common_init_finish() does is indicate that we're done initializing
and we're allowed to start up extra threads and do the wonky things that
daemons like to do (like set up the admin socket).  Since cconf is just
examining the config, we don't want to do any of that.

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agorbd: error out gracefully when snapname specified for command that doesn't use it
Sage Weil [Tue, 20 Sep 2011 23:24:18 +0000 (16:24 -0700)]
rbd: error out gracefully when snapname specified for command that doesn't use it

Fixes: #1545
Signed-off-by: Sage Weil <sage@newdream.net>
14 years agomon: 'osd set pool <foo> crush_ruleset <num>'
Sage Weil [Tue, 20 Sep 2011 23:17:51 +0000 (16:17 -0700)]
mon: 'osd set pool <foo> crush_ruleset <num>'

You can set the crush rule on pool creation.  Let people change existing
pool rulesets too.

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoOSD: return NULL when the OSD does not have the pg in lookup_lock_raw_pg
Samuel Just [Tue, 20 Sep 2011 20:34:31 +0000 (13:34 -0700)]
OSD: return NULL when the OSD does not have the pg in lookup_lock_raw_pg

Previously, we returned NULL if the osd lacked the pool, but not if the
osd had the pool and lacked the pg.  In that case, the assert in
_lookup_lock_pg would crash the osd.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
14 years agoReplicatedPG: populate obc watchers on sub_op_push
Samuel Just [Tue, 20 Sep 2011 17:50:07 +0000 (10:50 -0700)]
ReplicatedPG: populate obc watchers on sub_op_push

Previously, obc->unconnected_watchers did not get filled in during
sub_op_push.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
14 years agoosd: remove throttle_op_queue()
Sage Weil [Tue, 20 Sep 2011 17:58:20 +0000 (10:58 -0700)]
osd: remove throttle_op_queue()

There are subtle annoying problems with throttling and requeueing, and
throttling at this particular point in the stack makes little sense
anyway.  We have

 - messenger queue.  throttled based on total bytes/payload
 - op_queue, throttled before we queue items.

There is no real value in throttling a message before checking whether it
is valid (sent to the right osd, etc.) or putting it on the op_queue,
where it will sit until a worker thread picks it up and processes it.

When we get an osd_map, for instance, we pause op_queue, requeue
everything on the op_queue for reprocessing, and do the map update, so
not having a load of messages on that queue doesn't hurt us.  It just
complicates requeueing in the throttle_op_queue case, and delays the
checks for non-existent PGs or misdirected requests.

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoosd: preserve ordering when throttling races with missing/degraded requeue
Sage Weil [Tue, 20 Sep 2011 01:23:10 +0000 (18:23 -0700)]
osd: preserve ordering when throttling races with missing/degraded requeue

When we delay an op because the op_queue is full, we can violate the op
order:

 - op1 comes in, waits because object is missing
 - op2 comes in, throttles on op queue
 - op1 is requeued (no longer missing)
 - queue drains, op2 happens
 - op1 happens

To avoid this, if we delay, requeue ourselves... after whatever else is
on the queue.

Fixes: #1490
Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoosd: set reply version for dup requests
Sage Weil [Mon, 19 Sep 2011 23:50:48 +0000 (16:50 -0700)]
osd: set reply version for dup requests

If we get a dup request, set the version in the reply.  That means the
client knows the client was successful and committed, and they know the
version.  They don't get anything else (e.g., data payload resulting from
mutations).

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoCDir: put delete with pop so we don't read free'd memory in output
Greg Farnum [Mon, 19 Sep 2011 21:09:44 +0000 (14:09 -0700)]
CDir: put delete with pop so we don't read free'd memory in output

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoosd: clear need_up_thru in build_prior as appropriate
Sage Weil [Mon, 19 Sep 2011 21:00:59 +0000 (14:00 -0700)]
osd: clear need_up_thru in build_prior as appropriate

The only time need_up_thru is cleared is in the Peering state AdvMap
handler, but it doesn't get called if prior_set_affected() and we go
into build_prior().  Build_prior() sets need_up_thru if it's needed, but
it doesn't clear it if its not, which means the pg never goes active.

Reported-by: Sam Lang <samlang@gmail.com>
Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoMerge branch 'wip-flock'
Greg Farnum [Mon, 19 Sep 2011 17:40:45 +0000 (10:40 -0700)]
Merge branch 'wip-flock'

14 years agoflock: clean up waiting records of a lock when adding it succeeds
Greg Farnum [Mon, 19 Sep 2011 16:48:13 +0000 (09:48 -0700)]
flock: clean up waiting records of a lock when adding it succeeds

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoflock: add a replay parameter to add_lock
Greg Farnum [Mon, 19 Sep 2011 16:47:37 +0000 (09:47 -0700)]
flock: add a replay parameter to add_lock

Only insert locks into the waiting lost when NOT replaying
an already-attempted lock.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoceph_common.sh: Do not sudo to root unless needed
Tommi Virtanen [Mon, 19 Sep 2011 16:47:11 +0000 (09:47 -0700)]
ceph_common.sh: Do not sudo to root unless needed

Using do_root_cmd() doesn't really need to sudo to root
if you're already root.

Commit 71dc75bdafe62a098c0493ad62f2d0d2a6ca7946 causes a regression:
when system "foo" has a sudoers config that requires a tty,
init-ceph now fails like this:
  sudo: sorry, you must have a tty to run sudo

when it is invoked by root with something like this:
   ssh foo /etc/init.d/init-ceph start

Signed-off-by: Jim Schutt <jaschut@sandia.gov>
Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
14 years agoflock: move operator<<() to flock header, remove extra line
Greg Farnum [Mon, 19 Sep 2011 16:37:40 +0000 (09:37 -0700)]
flock: move operator<<() to flock header, remove extra line

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agoflock: remove doubled debug output
Greg Farnum [Mon, 19 Sep 2011 16:20:10 +0000 (09:20 -0700)]
flock: remove doubled debug output

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
14 years agofix .gitignore for test_addrs
Sage Weil [Mon, 19 Sep 2011 01:30:37 +0000 (18:30 -0700)]
fix .gitignore for test_addrs

14 years agotest/test_addrs: unit tests for addr parsing
Sage Weil [Sat, 17 Sep 2011 22:19:40 +0000 (15:19 -0700)]
test/test_addrs: unit tests for addr parsing

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agoRemove various unused variables
Wido den Hollander [Sat, 17 Sep 2011 14:25:36 +0000 (16:25 +0200)]
Remove various unused variables

Signed-off-by: Wido den Hollander <wido@widodh.nl>
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agomsgr: parse ipv6 addresses without []'s
Sage Weil [Sat, 17 Sep 2011 04:59:46 +0000 (21:59 -0700)]
msgr: parse ipv6 addresses without []'s

inet_pton() is annoying.  Be less lazy and work around it.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
14 years agodoc/dev/logs.rst: Add performance counter writeup
Colin Patrick McCabe [Fri, 16 Sep 2011 21:58:59 +0000 (14:58 -0700)]
doc/dev/logs.rst: Add performance counter writeup

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agodoc: Add section about changing config values
Colin Patrick McCabe [Fri, 16 Sep 2011 21:58:28 +0000 (14:58 -0700)]
doc: Add section about changing config values

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
14 years agoosd: use target obj locator for source object if empty
Yehuda Sadeh [Fri, 16 Sep 2011 18:18:03 +0000 (11:18 -0700)]
osd: use target obj locator for source object if empty

14 years agoconf: allow ; as a list separator
Sage Weil [Wed, 14 Sep 2011 19:59:22 +0000 (12:59 -0700)]
conf: allow ; as a list separator

Signed-off-by: Sage Weil <sage@newdream.net>
14 years agoMerge branch 'wip-1477'
Colin Patrick McCabe [Wed, 14 Sep 2011 23:05:42 +0000 (16:05 -0700)]
Merge branch 'wip-1477'