Commit Graph

23842 Commits

Author SHA1 Message Date
Danny Al-Gaaf
3acc4d2cfe rbd-fuse: fix for loop in open_rbd_image()
Remove uninitialized usage of 'int i' as i++ from 'for' loop.
The variale 'i' is never used in this loop and initialized
before the next use with 0.

Related warning from clang++:

rbd_fuse/rbd-fuse.c:141:36: warning: variable 'i' is uninitialized
when used here [-Wuninitialized]
        for (im = rbd_images; im != NULL; i++, im = im->next) {

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-02-06 08:42:43 -08:00
Danny Al-Gaaf
db0dbe5db8 msg/Message.h: fix C-style pointer casting
Replace C-style pointer casting with correct static_cast<>().

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-02-06 08:42:04 -08:00
Danny Al-Gaaf
b1fc10ef93 messages/MOSDRepScrub.h: initialize member variable in constructor
Initialize chunky and deep bool member variables in the constructor
with false.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-02-06 08:42:04 -08:00
Danny Al-Gaaf
22e48b5751 include/xlist.h: fix C-style pointer casting
Replace C-style pointer casting with correct static_cast<>().

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-02-06 08:42:03 -08:00
Danny Al-Gaaf
d54bd1700f include/types.h: change operator<< function parameter
Fix "Function parameter 'v' should be passed by reference." from cppchecker.
Use 'const pair<A,B>& v' similar to the other operator<< in this file.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-02-06 08:42:03 -08:00
Danny Al-Gaaf
0327cbaa2a include/buffer.h: fix operator=
Fix operator=: return "iterator&" instead of 'iterator'. Check if 'this'
equals 'other' before set anything.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-02-06 08:42:03 -08:00
Danny Al-Gaaf
ad526c0e44 obj_bencher.cc: use vector instead of VLA's
Fix "variable length array of non-POD element type" error. (-Wvla)

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-02-06 08:42:03 -08:00
Danny Al-Gaaf
a4042cc3c9 ceph_crypto.cc: remove unused shutdown() outside crypto ifdef's
Fix "out-of-line declaration of a member must be a definition
[-Wout-of-line-declaration]". Remove ceph::crypto::shutdown() outside
the crypto related ifdef's. Without nss or cryptopp configure will
fail anyways.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-02-06 08:42:03 -08:00
Danny Al-Gaaf
42682963cc WorkQueue.h: fix cast
Replace C-style pointer casting with correct static_cast<>().

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-02-06 08:42:03 -08:00
Yehuda Sadeh
27fb0e6305 rgw: a tool to fix buckets with leaked multipart references
Checks specified bucket for the #4011 symptoms, optionally fix
the issue.

sytax:
  radosgw-admin bucket check --bucket=<bucket> [--fix]

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
(cherry picked from commit 2d8faf8e5f)

Conflicts:
	src/rgw/rgw_admin.cc
	src/rgw/rgw_rados.h
2013-02-05 17:56:02 -08:00
Yehuda Sadeh
50c1775dda rgw: radosgw-admin object unlink
Add a radosgw-admin option to remove object from bucket index

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
(cherry picked from commit 16235a7acb)

Conflicts:
	src/rgw/rgw_admin.cc
	src/rgw/rgw_rados.h
	src/test/cli/radosgw-admin/help.t
2013-02-05 17:55:55 -08:00
Sage Weil
9eff2ee13d Merge remote-tracking branch 'gh/wip-osd-commands'
Reviewed-by: Dan Mick <dan.mick@inktank.com>
Reviewed-by: Joao Luis <joao.luis@inktank.com>
2013-02-05 17:31:48 -08:00
Sage Weil
3b635423bd mon: move list_rules into CrushWrapper method
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 16:35:55 -08:00
Sage Weil
9f4d4ac9cc crush: add list_rules() method
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 16:35:43 -08:00
Gary Lowell
7f237be2e2 Makefile: Add rgw/logrotate.conf source tarball
Signed-off-by: Gary Lowell  <gary.lowell@inktank.com>
2013-02-05 16:14:10 -08:00
Gary Lowell
99ea303054 logrotate.conf: Remove unneeded loop and update new rgw version.
Remove an unneeded for loop from the ceph logrotate.conf, and
update the new rgw logrotate.conf to reload the radosgw serivce.

Signed-off-by: Gary Lowell  <gary.lowell@inktank.com>
2013-02-05 15:20:43 -08:00
Yehuda Sadeh
c8eace6ff0 rgw: create a separate logrotate file for radosgw
Fixes: #3813
Since radosgw package is separate from the ceph package,
it also needs to have a separate logrotate. The default
path for radosgw log is changed to /var/log/radosgw,
and it now has a different logrotate script.
Updating both deb and rpm packaging.

Signed-off-by: Yehuda Sadeh <yehuda@inktank.com>
2013-02-05 14:54:38 -08:00
Sage Weil
b79067a863 qa: add workunits/mon/crush_ops.sh
Test creating, listing, removing crush rules via the mon.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:31:13 -08:00
Sage Weil
2c559a7ad1 mon: 'osd crush rule rm <name>'
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:31:13 -08:00
Sage Weil
a19cdd490a osdmap: method to check if a crush ruleset is in use
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:31:13 -08:00
Sage Weil
b9bd482d7e crush: remove_rule() method
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:31:13 -08:00
Sage Weil
43a01c9973 crush: factor out (trivial) crush_destroy_rule()
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:31:13 -08:00
Sage Weil
c370d85b42 mon: 'osd crush rules list|ls'
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:31:10 -08:00
Sage Weil
b6036a58b9 mon: 'osd crush dump'
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:30:37 -08:00
Sage Weil
9da6290c7b crush: factor out dump_rules from dump
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:30:37 -08:00
Sage Weil
a04d3f0ab1 mon: 'osd crush rule create-simple <name> <root> <failure_domain_type>'
Simple command to create simple rules.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:30:34 -08:00
Sage Weil
1a386d6c98 crush: add_simple_rule() command
Method to create a very generic rule the distributes objects across the
specified failure domain type underneath the given root.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:29:13 -08:00
Sage Weil
d7ada58a69 crush: fix get_rule_id() return value
There are 0 callers, yay!

Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:26:05 -08:00
Sage Weil
4f992ea344 crush: add rule_exists()
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:26:04 -08:00
Sage Weil
3105700d87 mon: 'osd find <osd-id>' command
Simple command to find the ip, host, rack, etc. for an OSD.  This is better
than 'ceph osd dump | grep ^osd.NNN\ '.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 14:26:04 -08:00
Greg Farnum
b3ffc718c9 Merge branch 'wip-2753-fsync-errors'
Reviewed-by: Sage Weil <sage@inktank.com>
2013-02-05 13:48:49 -08:00
Sage Weil
c058285dbe mds: uninline Capability encoders
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 13:29:06 -08:00
Greg Farnum
90d93d9431 mds: build dencoder with more stuff
Add libosdc and perfglue/disabled_heap_profiler to the
dencoder, because those are required for the MDS stuff
we're about to start putting in. *sigh*

Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:06 -08:00
Greg Farnum
ad40bdd8b6 MDSMap: mds_info_t now uses modern encoding
We have to update the older-style MDSMap encodings to generate
the previous versions for clients as well.

Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:06 -08:00
Greg Farnum
50ab924a27 mds: MDSMap now uses modern encoding
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:06 -08:00
Greg Farnum
771204b22d mds: move conditional MDSMap encoding into single encode method
Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:06 -08:00
Greg Farnum
21901d2148 mdsmap: uninline encode/decode
Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:06 -08:00
Greg Farnum
78632adca1 mds: modernize SimpleLock on-wire encoding
This is a wire protocol change.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 13:29:06 -08:00
Greg Farnum
924fb18fd9 mds: mds_table_pending_t now uses modern encoding
Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:06 -08:00
Greg Farnum
49b0be5815 mds: rename MDSTableServer::_pending to mds_table_pending_t
And move it from MDSTableServer into mdstypes.cc, so we can use it
in ceph-dencoder more gracefully (coming up next!).

Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:06 -08:00
Sage Weil
72c7bcd524 mds: MDSCacheObjectInfo now uses modern encoding
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-05 13:29:06 -08:00
Greg Farnum
d580a581cd mds: string_snap_t now uses modern encoding
Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:05 -08:00
Greg Farnum
f57f424495 mds: session_info_t now uses modern encoding
Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:05 -08:00
Greg Farnum
91555e2253 mds: move durable Session bits into session_info_t
This keeps the on-disk structure explicitly separate from the in-memory
functional stuff.

Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:05 -08:00
Greg Farnum
44865800fc mds: fnode_t now uses modern encoding
Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:05 -08:00
Greg Farnum
bd4897b826 mds: old_inode_t now uses modern encoding
Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:05 -08:00
Greg Farnum
7e85a17866 remove common/types.cc
It no longer has a purpose; the functions it used to host are now
implemented in mds/mdstypes.cc and more properly belong there
anyway.

Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:05 -08:00
Greg Farnum
843a35219c mds: inode_t now uses modern encoding
And we move implementations and the dumper into mdstypes.cc (from
mdstypes.h and common/types.cc).

Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:05 -08:00
Greg Farnum
87da20bfa1 mds: fold byte_range_t into client_writeable_range_t
As part of this, fold byte_range_t into it as a sub-struct
and eliminate its free-standing functions (it's too small
to live alone).

Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:05 -08:00
Greg Farnum
49eb4d68a4 mds: client_writeable_range_t now uses modern encoding
Signed-off-by: Sage Weil <sage@inktank.com>
Signed-off-by: Greg Farnum <greg@inktank.com>
2013-02-05 13:29:05 -08:00