Sage Weil [Tue, 9 Mar 2010 23:02:30 +0000 (15:02 -0800)]
thread: mask all signals on child threads
Mask all signals on any threads we create. Since we don't use
signals for anything, this leaves the signal behavior to the
original parent thread or process linking in librados or
libceph.
Sage Weil [Tue, 9 Mar 2010 18:41:42 +0000 (10:41 -0800)]
mds: fix MDentryUnlink
Need to replicate mds dir + stray dir dentry as well as the stray
inode, dir, dentry. This was overlooked when the /.ceph and
per-mds directories were set up.
Greg Farnum [Fri, 5 Mar 2010 19:13:59 +0000 (11:13 -0800)]
cephx: Piece-wise initialization of structs is BAD!
If you add, say, a field "auid" to the struct and it's being
piece-wise initialized then you need to change every copy to include it.
Or you assume it's just copied wholesale and then spend many hours trying
to find where it isn't. Like in this one.
Greg Farnum [Fri, 5 Mar 2010 20:37:56 +0000 (12:37 -0800)]
After discussing with Sage, we do want auid to be a part
of AuthTicket, et al. Let's do it that way.
Revert "authtool: give generated key specific uid if one is provided on the cli."
Sage Weil [Thu, 4 Mar 2010 00:49:58 +0000 (16:49 -0800)]
mds: accept stray reconnects
Hmm. Ultimately this is the direction we want to go, so that,
for example, a client that is forcefully disconnected can at
least attempt a reconnect (even if all its caps go ESTALE).
There are undoubtably some issues that need to be dealt with to
keep the mds from choking on weird client data, but those things
need to be fixed regardless.
Sage Weil [Thu, 4 Mar 2010 17:29:23 +0000 (09:29 -0800)]
crushtool: fix parsing with new boost library (compress whitespace)
The latest spirit breaks parsing. It seems to choke on
whitespace (e.g., fail to parse if there is any trailing
whitespace). I couldn't find any obvious problems with how
spirit is beign used, so work around it by stripping out any
extra whitespace from the input. Bleh!
Greg Farnum [Wed, 3 Mar 2010 21:02:06 +0000 (13:02 -0800)]
Revert a number of auth_uid commits.
Attempting to add an auth_uid to all the relevant structs has gotten too messy;
it *will* get messed up at some point in the future. So we're moving it into
the string map caps, and the machines can store it in their local structs
however they like.
Note to self: In future, do not attempt to extend mirrored structs without
great cause. Or else commit to making them properly-encapsulated objects.
Revert "auth: Add an auth_uid to AuthTicket. Still to do: copy it around"
Sage Weil [Tue, 2 Mar 2010 23:35:49 +0000 (15:35 -0800)]
mds: fix snapid tests in encode_inodestat
Snapid should always be non-zero; assert as much.
This fixes bug where valid was set to false when stating dir
inodes on non-auth mds's, which in turn returned no caps to
clients and, in the case of cfuse, caused a crash.
Sage Weil [Wed, 3 Mar 2010 17:47:00 +0000 (09:47 -0800)]
journal: set committing_seq in commit_start
We need to set committing_seq when we first block access to the
fs in commit_start(), NOT in commit_started(), as by that time
we may have queued all sorts of additional entries for the
journal. The committing_seq is all about syncing up with the
live fs (via op_apply_start), not what's queued for the journal.
Sage Weil [Tue, 2 Mar 2010 23:09:24 +0000 (15:09 -0800)]
osd: use per-PG ObjectStore::Sequencer when possible
Otherwise, when it doesn't matter, use the default. This
serialized io submission to btrfs at the lower layer within a
single PG. In general this is not significant, since we have
lots of PGs. We could potentionally do per object in some cases,
but we'd have to be careful about snapshots and such. Keep it
simple for now.
Sage Weil [Tue, 2 Mar 2010 23:07:29 +0000 (15:07 -0800)]
filestore: add Sequencer to queue_transaction interface
The (optional) sequencer parameter lets you order operations
submitted via the same Sequencer relative to each other. If no
sequencer is specified, a default one is used. Operations are
single-threaded with respect to an individual sequencer, so you
effectively get single threaded io submission to btrfs/whatever
if you do not specify a sequencer.
Greg Farnum [Fri, 26 Feb 2010 19:28:25 +0000 (11:28 -0800)]
msgr: Remove the type CEPH_ENTITY_TYPE_ADMIN.
It *looks* like this won't break EntityName's isAdmin() function as that
depends on a set name, and client.admin will satisfy it. I think.
Greg Farnum [Fri, 26 Feb 2010 18:57:37 +0000 (10:57 -0800)]
ceph_fs: Split CEPH_FEATURE_{SUPPORTED, REQUIRED} flags into service-based flags
msgr: New get_{required,supported}_bits methods which calculate required bits
based on type of self and of peer. Replace all hard-coded flag uses with these.
Sage Weil [Tue, 2 Mar 2010 00:34:17 +0000 (16:34 -0800)]
mds: put forced open sessions in OPENING then OPEN
We use OPENING state to indicate sessions that are being
imported. Fix get_or_add_open_session() to NOT set the session
state (except to STATE_NEW if new) so that the caller can do
the right thing. Otherwise, the prepare_force_open_sessions()
can't tell if it just forced open a session (and needs it to be
OPENING) or if it was already open. Subsequently cap migrations
weren't working if the client didn't already have a session
open.
There is still a bug: if the import aborts, we have an OPENING
session with no actual open client_session message queued. Maybe
we should have a different state instead of OPENING... IMPORTING?