Commit Graph

7372 Commits

Author SHA1 Message Date
Sage Weil
464d248e35 Makefile: fix up initscript packaging 2009-07-15 14:07:37 -07:00
Sage Weil
6b3309a87c initscripts: /etc, not /usr/etc 2009-07-15 14:07:37 -07:00
Sage Weil
1c1e7df4d8 kclient: kill debug msg 2009-07-15 12:19:18 -07:00
Sage Weil
8f09da9544 kclient: fix up patchset comments, docs 2009-07-15 12:06:23 -07:00
Sage Weil
36dd23aba5 mds: adjust client reconnect timeout 2009-07-15 11:50:48 -07:00
Sage Weil
f80db8dfa5 msgr: use SIGUSR2 for pipe kills, USR1 for accepter kills
Otherwise our pthread sigmask change for accepter pselect() call
can block signals sent to kill pipe threads, and we get hangs on
msgr shutdown.
2009-07-14 16:33:55 -07:00
Sage Weil
81cc70a858 kclient: whitespace 2009-07-14 14:06:09 -07:00
Sage Weil
7cf994d530 kclient: some comment cleanup 2009-07-14 14:04:35 -07:00
Sage Weil
8e1d2ad7fc mds: eval locks too in reissue_all_caps after mds restart
We may have correct wanted, issued info for the clients, but that
doesn't help us if we don't use it.
2009-07-14 13:46:58 -07:00
Sage Weil
09dffea8e9 mds: reset seq on mds after reconnect, too
We were setting it to 1 (due to the issue_norevoke() call), but the
client is resetting to 0, so do the same here.  (Otherwise
subsequent client cap messages may get ignored.)
2009-07-14 13:46:10 -07:00
Sage Weil
b32f7cfb4c mds: flush log during clientreplay 2009-07-14 13:27:14 -07:00
Sage Weil
161a8b1c7a mds: fix max_size calculation
We want to ROUND_UP_TO from (size+1)<<1, otherwise size=0 gives us
a max_size of 0 (no good!).
2009-07-14 13:18:04 -07:00
Sage Weil
5249a2bd50 uclient: make lstat() take mask 2009-07-14 12:50:06 -07:00
Sage Weil
b5bae80b66 mds: truncate journal on partial write
Otherwise, we start writing new entries, then restart, and end up
with garbage at the write pos.
2009-07-14 12:40:39 -07:00
Sage Weil
ab824409ac mds: apply cap mask in choose_lock_state
Otherwise we get CAP_GWR and other bits outside of simplelock
mask.
2009-07-14 12:40:38 -07:00
Sage Weil
e9f456843c msgr: fix race with signals vs select with pselect
Fixes hang where accepter thread misses the stop signal and
doesn't shut down.
2009-07-14 10:35:03 -07:00
Sage Weil
82fe78cf1d mkcephfs: chown/chmod mount point if non-root 2009-07-14 10:17:29 -07:00
Sage Weil
e4f817030f mds: reconnect caps added via replay+issue_new_caps
Also, set up the initial lock states after reconnecting them!
2009-07-13 17:48:19 -07:00
Sage Weil
ea2f8343d2 mds: check client ranges on mds restart 2009-07-13 17:48:19 -07:00
Sage Weil
2b03d81b1d mds: adjust client range on open existing for write 2009-07-13 17:48:19 -07:00
Sage Weil
e842cf55b2 mds: journal recovered mtime; cleanup
Also avoid using in->inode as that may fail with concurrent updates
(if that's even possible?).
2009-07-13 17:48:19 -07:00
Sage Weil
6867c0cb9a mds: do not check_inode_max_size in eval() path
This is super dangerous, since we may journal something in the
middle of preparing another journal entry.  (This is notably a
problem with calls to issue_new_caps).

Kill fugly NO_SIZE_CHECK flag too, yay.
2009-07-13 17:48:18 -07:00
Sage Weil
b1d5bea560 mds: set client_range on open O_TRUNC
Set client_ranges explicitly.  Move get_layout_size_inc into
inode_t.
2009-07-13 17:48:18 -07:00
Sage Weil
0b454296a3 mds: base client_ranges update on issued|wanted, not just issued 2009-07-13 17:48:18 -07:00
Sage Weil
23aeea4ee7 mds: use SCAN state for file recovery on mds restart
This ensures we revoke other caps before scanning for file
sizes.
2009-07-13 17:48:18 -07:00
Sage Weil
0d5b2c08ad Makefile: fix whitespace 2009-07-13 10:39:25 -07:00
Sage Weil
5cfa35e4af initscript: fix 'reload' 2009-07-13 10:38:23 -07:00
Sage Weil
9a7fdb22a9 initscripts: do what we can to run as user specified in the conf 2009-07-13 10:38:23 -07:00
Sage Weil
5bb2968985 initscripts: substitute in proper autoconf paths
Based on
http://www.gnu.org/software/hello/manual/autoconf/Installation-Directory-Variables.html
2009-07-13 10:30:43 -07:00
Sage Weil
08a6fb733d mds todos 2009-07-10 15:32:56 -07:00
Sage Weil
2789732c9e kclient: simplify/fix cap delay timeouts
Do NOT reset timeouts at the top of ceph_check_caps.. that's just
wrong, and screws up cap release logic.

Reset timeouts when we requeue the cap, since that's what all the
callers do.
2009-07-10 15:32:56 -07:00
Sage Weil
f871d3e0a0 mds: on restart, only recover files affected by missing clients 2009-07-10 15:32:56 -07:00
Sage Weil
3a86b94cb3 mds: maintain per-client write ranges instead of single max_size
We need to track individual clients' ability to write to a file in
order to behave rationally when a client dies or fails to reconnect
after an mds restart.

There is also a behavior change hiding in here: before we were
adjusting max_size based on _wanted_ caps, but that was unsafe,
since a client may have the old max_size value and initiate a write
after informing the mds it no longer wants said caps.  There will
undoubtably be some fallout from that change...

Also clean up instances of memset() on inode_t and friends.  Define
and use constructors instead.
2009-07-10 15:32:56 -07:00
Sage Weil
167f4cad26 uclient: fix getdir() to use new readdir_r return value 2009-07-10 15:32:55 -07:00
Sage Weil
8733b56fe5 uclient: stop using mds inode_t 2009-07-10 15:32:55 -07:00
Sage Weil
28e444dd0a mds: add SCAN, PRE_SCAN lock states
Also clean up state machine array sizes
2009-07-10 15:32:55 -07:00
Sage Weil
2ca5659eec osd: less hexdump on tmap updates 2009-07-10 15:32:55 -07:00
Yehuda Sadeh
bdfc852106 objecter: fix pool objects listing 2009-07-10 13:19:13 -07:00
Sage Weil
58fa7c1bed kclient: fix uninitialized vars 2009-07-09 16:44:09 -07:00
Sage Weil
21804bcc19 todo 2009-07-09 16:34:54 -07:00
Sage Weil
9a5d053459 Revert "kclient: strip out kernel version compatibility cruft"
This reverts commit ac1cf5dc7343953462aa27dc3526dd5ccec9cb53.
2009-07-09 16:33:38 -07:00
Sage Weil
28aa4e8a43 Merge branch 'master' of ssh://ceph.newdream.net/git/ceph 2009-07-09 16:29:36 -07:00
Sage Weil
67822ef05a s3gw: make compilation optional (./configure --with-s3gw) 2009-07-09 16:28:18 -07:00
Sage Weil
280e4df95d uclient: include tid in cap flush, flushsnap 2009-07-09 15:50:29 -07:00
Sage Weil
1961fb75eb kclient: include tid in cap flush, flushsnap
This avoids (dirty 1, flush 1, dirty 2, flush 2, flush_ack 1 ->
mark clean) badness.
2009-07-09 15:41:23 -07:00
Sage Weil
6d95e290aa mds: add tid to cap flush/flushsnap ops
And include in the ACK.
2009-07-09 15:35:22 -07:00
Sage Weil
45e409451a kclient: assign seq to cap flush; avoid starvation on sync_fs
Assign a seq# to each cap flush.  When we sync_fs, wait only for
prior cap flushes to complete.

Also, fix wait_unsafe_requests.
2009-07-09 15:11:52 -07:00
Sage Weil
c8744d6d48 kclient: debug output cleanup 2009-07-09 14:35:19 -07:00
Sage Weil
b5d32fa451 uclient: assign sequence to cap flushes, avoiding sync_fs starvation
Order flushes, so we can wait for them without possibility of
starvation.
2009-07-09 14:35:19 -07:00
Sage Weil
1a255ca1a0 kclient: fix write_inode; force dirty cap flush by mdsc_sync
Adding flag to ceph_check_flags to flush any dirty data.  Pass
through from mdsc_sync.

Also, flush if i_ceph_flags & CEPH_I_FLUSH to avoid letting
write_inode calls similarly leak through.
2009-07-09 14:35:19 -07:00