Commit Graph

15371 Commits

Author SHA1 Message Date
Greg Farnum
387e46b445 Filer: return error codes from probing up to the calling layer.
This is pretty limited; if you get multiple errors in one batch
of probes it'll only return the last one to get sent back (ENOENT is
excluded). But it's better than nothing.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-20 15:58:40 -07:00
Yehuda Sadeh
ffd92d20ca rgw: dump is_truncated when listing bucket 2011-07-20 15:41:00 -07:00
Greg Farnum
73d66f677f mds: cinode: Add a little debugging and fix an output
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-20 13:22:19 -07:00
Greg Farnum
b2b44d47c9 mds: Drop locks and auth pins when waiting for freezingtree
In most cases we don't end up in this branch because there's an escape
if you already have an auth_pin on the ref in question. But when
you've got snapshots going on, you can process the request, block on
a lock state change, commit a snapshot change to the inode, and then
try to process the request again. On this second attempt, though,
you end up with a different ref which you don't have a pin on.
Deadlock and breakage ensues!
To fix, drop all locks and auth pins when you wait -- either
you don't have any to drop anyway, or you've got them on a previous
version of the inode that isn't useful anymore.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-20 13:22:19 -07:00
Greg Farnum
022c526180 uclient: correctly initialize mseq in flush_snaps.
Previously we set mseq=0 unconditionally; this was a mistake that
creeped in via bitrot. Instead, set mseq from the auth cap.
This bug meant that any inodes which had gotten migrated between
MDSes would have their flush_snap messages dropped by the MDS.
Resolves #1324.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-20 13:22:19 -07:00
Sage Weil
4adfd46630 mds: mark rmdir with slaves as a master in journal
Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-20 13:17:23 -07:00
Sage Weil
573e972098 mds: fix rmdir slave commit, rollback
We need to set the slave commit callback to journal a commit or rollback
as needed.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-20 13:06:37 -07:00
Sage Weil
8692ed7df7 mds: simplify journaled subtree_map
We may have subtrees split locally due to migrations that are just getting
started or stopped.  Simplify the map we journal to disk.  Among other
things this makes the replay check simple (it can compare against the
current "live" map).

Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-20 12:49:02 -07:00
Sage Weil
a3e47311b5 mds: add mds_debug_subtrees option
Verify that replayed ESubtreeMap events match what we have.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-20 12:49:02 -07:00
Sage Weil
4fe09c1cc9 mds: set LogEvent _start_off, drop unused _end_off
Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-20 12:49:02 -07:00
Sage Weil
a25374e40a mds: witness rmdir when subtrees are on other hosts
If there is an rmdir with an empty subtree on another mds, we need to witness/
journal that on the dirfrag's auth mds so that replay correctly updates the
subtree map.

This is simpler than the rename witnesses (and the link/unlink ones) because
we aren't actually journaling a modification to any actual metadata; it's just
the subtree map that is changing.

The projection of the subtree map update needs work still, but that is also the
case for renames.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-20 12:46:57 -07:00
Yehuda Sadeh
0c913a8721 Merge branch 'wip-rgw-multithreaded' 2011-07-20 10:35:55 -07:00
Yehuda Sadeh
820b3f3684 rgw: setup as external server is configurable 2011-07-20 10:35:06 -07:00
Yehuda Sadeh
9eed12f57f rgw: clearer logging context 2011-07-20 10:01:17 -07:00
Colin Patrick McCabe
41f7acf5bc config.cc: fix comments
Fix comments that were reverted to an older version by commit
a51b983a8b.

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
2011-07-20 09:31:31 -07:00
Samuel Just
019955a1f4 PGMonitor.cc: add force_create_pg command to monitor
ceph pg force_create_pg <pgid> will now reset that pg's status to
creating to handle corner cases where no osd has that pg.

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
2011-07-19 17:59:41 -07:00
Yehuda Sadeh
43575c7ac7 rgw: fix concurrency issue 2011-07-19 14:02:11 -07:00
Sage Weil
b3b06d02ab Merge branch 'stable' 2011-07-19 11:26:25 -07:00
Sage Weil
62e6f36a35 mds: clean up file flags to file mode translation
There was some seriously wrong and ancient cruft in there.  open(2)
specifies that one of O_RDONLY, O_WRONLY, and O_RDWR must always be
specified.  Drop all the crazy.

Linux VFS interprets O_WRONLY|O_RDWR as read+write, so we'll do the same.

Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-19 11:25:46 -07:00
Sage Weil
82faf3d6dd client: check for invalid file mode
Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-19 11:03:22 -07:00
Sage Weil
ff82b60bd0 mds: check for invalid file mode
Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-19 11:03:20 -07:00
Yehuda Sadeh
5e988b8e99 rgw: fix i386 compilation 2011-07-19 10:28:55 -07:00
Yehuda Sadeh
a51b983a8b config: fix compilation in certain environments 2011-07-19 09:43:50 -07:00
Sage Weil
626f0b1ffe mon: fix dump_json quoting
Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-19 08:41:58 -07:00
Sage Weil
650f9f315b mds: fix O_APPEND file mode calculation
Currently

  fd = open("aaa",O_RDWR|O_CREAT|O_APPEND,0666);

gives us fmode of 1 instead of 3.  We should only infer O_WRONLY if no
other mode is explicitly specified.

Reported-by: Fyodor Ustinov <ufm@ufm.su>
Signed-off-by: Sage Weil <sage@newdream.net>
2011-07-19 08:33:37 -07:00
Yehuda Sadeh
51039da1a6 rgw: use thread pool for rgw work 2011-07-18 17:14:25 -07:00
Sage Weil
59a8e65e47 mon: pg dump_json
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
2011-07-18 16:31:24 -07:00
Yehuda Sadeh
431df83e0a rgw: radosgw_admin log show dumps parsable json 2011-07-18 16:23:22 -07:00
Greg Farnum
6424149783 osd: remove unused variables
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-18 13:24:41 -07:00
Greg Farnum
d07c480e38 mon: remove unused variables
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-18 13:24:41 -07:00
Greg Farnum
1dedbf63c3 mds: remove unused variables
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-18 13:24:41 -07:00
Greg Farnum
7db65d5770 tools: remove unused variables
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-18 13:24:41 -07:00
Greg Farnum
442b5d5b6a clien: rados: bench: remove unused variables
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-18 13:24:41 -07:00
Samuel Just
09c8d12a51 ReplicatedPG: _rollback_to
_delete_head modifies clone_overlap and stats incorrectly for
_rollback_to

Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
2011-07-18 12:45:37 -07:00
Samuel Just
c54aa7db3b testsnaps: use self managed snaps and other fixes
Signed-off-by: Samuel Just <samuel.just@dreamhost.com>
2011-07-18 12:45:37 -07:00
Greg Farnum
94c3763954 Makefile: librados-config apparently depends on libcrypto++
In newer versions of gcc/ld, librados-config breaks without
the CRYPTO_LIBS.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-18 12:18:40 -07:00
Greg Farnum
35b60c6968 gitignore: ignore Eclipse files/folders
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
2011-07-18 12:18:40 -07:00
Colin Patrick McCabe
77bcc069b1 Remove lingering references to g_conf
These were harmless, but silly.

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
2011-07-18 10:37:42 -07:00
Yehuda Sadeh
92df6e323a rgw: fix range dump 2011-07-18 10:07:27 -07:00
Sage Weil
aef29cafba mds: fix protocol versions
I screwed this up in a928f767b9.

Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
2011-07-17 16:49:59 -07:00
Yehuda Sadeh
a7d791de55 rgw: multithreaded handling 2011-07-15 16:46:01 -07:00
Colin Patrick McCabe
d4ed22ffe5 recalc_op_target must give an error if pool gone
Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
2011-07-15 15:01:39 -07:00
Sage Weil
172dc20ed0 Makefile: remove dup testrados_list_parallel_SOURCES
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
2011-07-15 14:44:56 -07:00
Sage Weil
ccf5e266b8 Merge remote branch 'origin/stable' 2011-07-15 13:03:14 -07:00
Sage Weil
41c9680ae7 Merge remote branch 'origin/wip-1287' 2011-07-15 13:01:37 -07:00
Yehuda Sadeh
02abdca1f6 rgw: multiple fixes, prepare main loop for multithreading 2011-07-15 12:54:32 -07:00
Yehuda Sadeh
4f08881d8e rgw: fix compilation for certain architectures 2011-07-15 10:58:33 -07:00
Colin Patrick McCabe
29557834d0 botol_tool: add --xattr argument for PUT
boto_tool can now set extended attributes when performing a PUT
operation.

Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
2011-07-15 10:09:35 -07:00
Colin Patrick McCabe
b4b3672d64 boto_tool: add --get-obj-xattr
Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
2011-07-15 10:09:35 -07:00
Colin Patrick McCabe
5cb98c95c0 rgw_op: mime-encode ugly xattrs in PUT
Signed-off-by: Colin McCabe <colin.mccabe@dreamhost.com>
2011-07-15 10:09:30 -07:00