Commit Graph

17293 Commits

Author SHA1 Message Date
Sage Weil
6b4b659594 Merge branch 'stable' 2011-12-02 12:06:50 -08:00
Mark Kampe
06228716e3 Doc: add a conceptual overview of the peering process
Signed-off-by: Mark Kampe <mark.kampe@dreamhost.com>
2011-12-02 11:28:38 -08:00
Sage Weil
c45a8491fe mds: remove obsolete doc 2011-12-02 11:19:24 -08:00
Sage Weil
0c183ec7b0 crush: ignore forcefed input that doesn't exist
This might happen if, e.g., the file_layout specifies an osd that later
is removed from the cluster entirely.  Just ignore it instead of making
upper layers duplicate this check.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
2011-12-02 09:58:45 -08:00
Sage Weil
faf5ce6293 Revert "CrushWrapper: ignore forcefeed if it does not exist"
This reverts commit 6fbab6da69.

This fails a unit test.

And I change my mind.. I think this is most cleanly handled inside crush, so
we don't duplicate the same check that is generating the error with an different
data structure.
2011-12-02 09:47:58 -08:00
Sage Weil
321ecdaba2 v0.39 2011-12-02 09:01:31 -08:00
Samuel Just
75aff02371 OSDMap: build_simple_from_conf pg_num should not be 0 with one osd
Previously, pg_num would end up set to 0 if osd.0 is the only osd.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
2011-12-02 09:00:27 -08:00
Sage Weil
2f5bd5f737 objecter: initialize global_op_flags to zero
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
2011-12-01 20:36:13 -08:00
Mark Kampe
813523a681 Doc: delete gratuitous index.html
It was not an index, and seems to contain recommendations
for system configuration.  I have renamed it to confusing.txt
and will merge it in a future commit.

Signed-off-by: Mark Kampe <mark.kampe@dreamhost.com>
2011-12-01 16:13:12 -08:00
Mark Kampe
48165af5c2 Doc: complete reversion of architecture.rst
(abandon in progress improvements until everything works)

Signed-off-by: Mark Kampe <mark.kampe@dreamhost.com>
2011-12-01 16:12:34 -08:00
Mark Kampe
3c7a82a6dc Doc: deleted gratuitious PlanningImplementation.html,
which was a copy of PlanningImplementation.txt
(and not html at all).

restored previous index.rst, which was overwritten with a copy
of PlanninImplementation.txt, but removed all of the recursively
included content from the document.

I will cherry-pick merge the new contents in a subsequent commit.

Signed-off-by: Mark Kampe <mark.kampe@dreamhost.com>
2011-12-01 16:12:12 -08:00
Mark Kampe
fdf3f7bd7d Doc: Restore the previous version of architecture.rst
it was accidentally overwritten with a version of the product
had a somewhat different audience/focus and a few sphinx
formatting errors.

I will cherry-pick the corrections in a subsequent commit.

Signed-off-by: Mark Kampe <mark.kampe@dreamhost.com>
2011-12-01 16:11:05 -08:00
Mark Kampe
4cfe0815cb doc: change state model from .svg to .png
Signed-off-by: Mark Kampe <mark.kampe@dreamhost.com>
2011-12-01 16:07:41 -08:00
Steve MacGregor
1bbf9ae6b5 fixed ubuntu version typo 2011-12-01 14:41:38 -08:00
Samuel Just
6fbab6da69 CrushWrapper: ignore forcefeed if it does not exist
Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
2011-12-01 14:20:12 -08:00
Josh Durgin
363ebb6ccc librbd: report an error if rbd header does not match
This will fail on future incompatible versions of the header format.

Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
2011-12-01 12:38:57 -08:00
Greg Farnum
cce67171a7 Merge branch 'wip_local_reads' 2011-12-01 11:15:44 -08:00
Greg Farnum
d4aef20210 hadoop: apache license.
We haven't made explicit that the Hadoop Java code is under the Apache
License. Do so (with permission from the other contributors, thanks!).

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-12-01 11:15:29 -08:00
Sage Weil
348c71c414 mds: fix blocking in standby replay thread
We need to hold mylock before waiting on the cond or else we get

./common/Cond.h: In function 'int Cond::Wait(Mutex&)', in thread '7f37fe0c8700'
./common/Cond.h: 46: FAILED assert(mutex.is_locked())
 ceph version 0.38-2-g73f99a1 (commit:73f99a189f491866da2be88adcfe0bd512282755)
 1: (MDLog::_replay_thread()+0x2483) [0x6c4393]
 2: (MDLog::ReplayThread::entry()+0xd) [0x4decbd]
 3: (()+0x6d8c) [0x7f3803e8fd8c]
 4: (clone()+0x6d) [0x7f38028d504d]
 ceph version 0.38-2-g73f99a1 (commit:73f99a189f491866da2be88adcfe0bd512282755)
 1: (MDLog::_replay_thread()+0x2483) [0x6c4393]
 2: (MDLog::ReplayThread::entry()+0xd) [0x4decbd]
 3: (()+0x6d8c) [0x7f3803e8fd8c]
 4: (clone()+0x6d) [0x7f38028d504d]
*** Caught signal (Aborted) **
 in thread 7f37fe0c8700

Signed-off-by: Sage Weil <sage@newdream.net>
2011-12-01 09:17:56 -08:00
Sage Weil
f6ee3699c9 global: make daemon banner print explicit
This eliminates some flags and avoids annoying cases where the banner is
printed but we don't want to see it.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-12-01 09:17:51 -08:00
Sage Weil
5828009e69 mds: fix usage text
Filename is not optional.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-12-01 08:19:47 -08:00
Sage Weil
353ee0004a mds: adjust flock lock state on export
Looks like this was missed when flocklock was added.  Did a quick grep and
it doesn't look like it is missing anywhere else.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-30 09:57:58 -08:00
Greg Farnum
2443878b81 Objecter: loop the right direction when searching for local replicas
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-11-29 18:14:29 -08:00
Samuel Just
1c696b6566 doc: Add peering state diagram
Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
2011-11-29 16:35:59 -08:00
Sage Weil
30ede648fe Makefile: ipaddr.h, pick_address.h
Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-29 15:36:07 -08:00
Sage Weil
77a62fdce4 Makefile: add missing uuid.h to tarball
Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-29 13:31:38 -08:00
Greg Farnum
ebb585d9c0 Objecter: fix local reads in recalc_op_target
We want to use the actual OSD, not the index into the array!

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-11-29 13:30:45 -08:00
Sage Weil
8788a404ae osd: subscribe to next map if flagged FULL
This ensures the osd finds out when we become un-full in a timely manner.

Fixes: #1755
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
2011-11-29 08:28:57 -08:00
Sage Weil
c2889fef42 mds: encode truncate_pending in inode
Otherwise we don't actually journal this value, and we get confused when
we replay a start_truncate and try to restart it.

Fixes: #1756
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
2011-11-28 21:39:21 -08:00
Greg Farnum
98e0a6fddf uclient: remove filer_flags and use Objecter::global_op_flags instead
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-11-28 12:52:51 -08:00
Greg Farnum
da2e0c3c14 Objecter: add a new global_op_flags that is passed to every Op constructor.
We can use this for a global use of LOCALIZE_READS (and are about
to do so!).

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-11-28 12:52:46 -08:00
Greg Farnum
51385930cd Objecter: remove unused variable in op_submit
These flags are probably relics from when the function got split;
they belong in send_op now.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-11-28 12:30:46 -08:00
Greg Farnum
4974a9c284 uclient: remove useless if-else based on snapid
These are the same command anyway!

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-11-28 10:32:07 -08:00
Wido den Hollander
cef16732e7 debian init: Do not stop or start daemons when installing or upgrading
Signed-off-by: Wido den Hollander <wido@widodh.nl>
2011-11-28 09:01:50 -08:00
Sage Weil
ce65722739 mon: search for local ip during mkfs
If an address isn't explicitly specified during mkfs, look for an unnamed
monitor in the (generated) monmap and see if any of those addresses is
configured on the local machine.  If so, assume it's us, and name ourselves
in the seed monmap.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-27 16:11:29 -08:00
Sage Weil
61b9db3a8e pick_address: implement have_local_addr()
Check for a local ip from within a list of addresses.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-27 16:11:28 -08:00
Sage Weil
84b0059755 monclient: name nameless monitors noname-<foo>
This makes them easy to pick out as unnamed.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-27 16:04:52 -08:00
Sage Weil
7a453402e3 pick_address: whitespace
Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-27 14:50:46 -08:00
Mark Kampe
30def38d21 corrected variable (con) to be consistent with prior examples (cluster)
Signed-off-by: Mark Kampe <mark.kampe@dreamhost.com>
2011-11-23 15:56:52 -08:00
Samuel Just
934e1e5251 ReplicatedPG: Also count overlaps for snapsets on snapdirs
Previously, the overlaps for snapdirs would not be included in
cstat causing the computed total to be incorrect.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
2011-11-23 14:07:54 -08:00
Samuel Just
97d82ed950 ReplicatedPG: Account for clone space usage in make_writeable
Previously, we accounted for clone space usage inconsistently in
write_update_size_and_usage etc when walking through the operations.
make_writeable may change the most recent clone overlap, however, so we
can't handle it until then.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
2011-11-23 14:07:08 -08:00
Sage Weil
32a6837839 Merge branch 'wip-mon' 2011-11-23 06:45:26 -08:00
Sage Weil
ad13d0b731 ceph: fix shutdown race
Shut down MonClient before messenger, to avoid race with MonClient::tick()
and MonClient::shutdown().

Fixes

#0  __lll_lock_wait () at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S:136
#1  0x00007f44475e2849 in _L_lock_953 () from /lib/libpthread.so.0
#2  0x00007f44475e266b in __pthread_mutex_lock (mutex=0x14d8dc8) at pthread_mutex_lock.c:61
#3  0x00000000005ae090 in Mutex::Lock (this=0x14d8db8, no_lockdep=false) at ./common/Mutex.h:108
#4  0x000000000068440e in MonClient::shutdown (this=0x14d8c30) at mon/MonClient.cc:386
#5  0x00000000005b2653 in ceph_tool_common_shutdown (ctx=0x14d84c0) at tools/common.cc:661
#6  0x00000000005ada29 in main (argc=7, argv=0x7fff8a2394c8) at tools/ceph.cc:304

vs

#0  0x00007f44475e8a0b in raise (sig=<value optimized out>) at ../nptl/sysdeps/unix/sysv/linux/pt-raise.c:42
#1  0x00000000005eff6b in reraise_fatal (signum=11) at global/signal_handler.cc:59
#2  0x00000000005f0165 in handle_fatal_signal (signum=11) at global/signal_handler.cc:106
#3  <signal handler called>
#4  0x0000000000000000 in ?? ()
#5  0x000000000068661a in MonClient::tick (this=0x14d8c30) at mon/MonClient.cc:621
#6  0x0000000000689e3b in MonClient::C_Tick::finish(int) ()
#7  0x000000000061b3c5 in SafeTimer::timer_thread (this=0x14d8df8) at common/Timer.cc:102
#8  0x000000000061c6f0 in SafeTimerThread::entry() ()
#9  0x00000000005f1219 in Thread::_entry_func (arg=0x14e1a00) at common/Thread.cc:41
#10 0x00007f44475e0971 in start_thread (arg=<value optimized out>) at pthread_create.c:304
#11 0x00007f4445ead92d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112
#12 0x0000000000000000 in ?? ()

Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-23 06:44:58 -08:00
Tommi Virtanen
414caa7d15 common/pick_address: Fix IP address stringification.
Different sockaddr_* have the actual address (sin_addr, sin6_addr)
at different offsets, and sockaddr->sa_data just isn't enough.
inet_ntop conspires by taking a void*. I could figure out the right
offset with a switch (found->sa_family), but let's go for the
supposedly write-once-run-with-any-AF solution, getnameinfo.

Which, naturally, takes an extra length argument that is AF-specific,
and not provided anywhere nicely by getifaddrs. Huzzah!

Signed-off-by: Tommi Virtanen <tommi.virtanen@dreamhost.com>
2011-11-22 20:52:16 -08:00
Sage Weil
9870e2f77b mon: pick_addresses before common_init_finish
We can't modify g_conf->public_addr after that.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-22 16:28:42 -08:00
Sage Weil
036ad4c73c mon: set default port if not specified...
...when looking for self in monmap during mkfs.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-22 16:22:07 -08:00
Sage Weil
36978a6329 mon: calculate rank by addr, not name
Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-22 16:04:10 -08:00
Sage Weil
0045c90169 monmap: assign rank by sorting addr, not name
This allows monitors to bootstrap knowing peer addrs but not their names,
as when we specify mon_host.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-22 16:04:10 -08:00
Yehuda Sadeh
ebe5fc60d2 obsync: tear out rgw 2011-11-22 15:06:16 -08:00
Sage Weil
3a20b425d6 mon: name self in monmap if --public-addr specified during mkfs
Signed-off-by: Sage Weil <sage@newdream.net>
2011-11-22 14:53:45 -08:00