Commit Graph

26172 Commits

Author SHA1 Message Date
Joao Eduardo Luis
c307d427d1 ceph-osd: specify which types of addresses to pick
Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
2013-05-22 17:57:38 +01:00
Joao Eduardo Luis
6d8932304c ceph-mon: only care about public addr during pick_addresses()
Fixes: #4228

Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
2013-05-22 17:57:38 +01:00
Joao Eduardo Luis
1ba9f84db6 common: add mask argument to pick_addresses() to specify what we need
Fixes: #4228

Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
2013-05-22 17:57:37 +01:00
Sage Weil
78a1834d81 ceph: remove cli test
This is about to be removed by wip-ceph-cli anyway.  And it broke in
commit 132d5bf7f9.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-22 09:39:11 -07:00
Sage Weil
308d7c4609 Merge pull request #297 from dalgaaf/wip-da-CID-727982
Reviewed-by: Sage Weil <sage@inktank.com>
2013-05-22 08:54:56 -07:00
Sage Weil
0e733ba58b Merge pull request #310 from dalgaaf/wip-da-CID-fixes-4
Reviewed-by: Sage Weil <sage@inktank.com>
2013-05-22 08:37:09 -07:00
Danny Al-Gaaf
549e547b3b mds/Migrator.cc: fix possible dereference NULL return value
CID 716997 (#1 of 1): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "in" when
  calling "MDSCacheObject::is_auth() const".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 17:28:06 +02:00
Danny Al-Gaaf
32b024c6c6 mds/Migrator.cc: fix possible dereference NULL return value
ID 716998 (#1 of 2): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "in" when
  calling "operator <<(std::ostream &, CInode &)".

CID 716998 (#2 of 2): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "in" when
  calling "MDCache::add_replica_dir(ceph::buffer::list::iterator &,
  CInode *, int, std::list<Context *, std::allocator<Context *> > &)".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 17:25:16 +02:00
Danny Al-Gaaf
ed53bf17c5 mds/Migrator.cc: delete some empty lines at EOF
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 17:23:40 +02:00
Danny Al-Gaaf
158e740935 mds/Migrator.cc: fix possible dereference NULL return value
CID 716999 (#1 of 1): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "in" when
  calling "CInode::put_stickydirs()".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 17:21:59 +02:00
Sage Weil
cfebb83522 Merge pull request #309 from dalgaaf/wip-da-CID-fixes-3-v2
Reviewed-by: Sage Weil <sage@inktank.com>
2013-05-22 08:20:49 -07:00
Danny Al-Gaaf
7ba34c1384 mds/Migrator.cc: fix dereference NULL return value
CID 717000 (#1 of 2): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "dir" when
  calling "operator <<(std::ostream &, CDir &)".

CID 717000 (#2 of 2): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "dir" when
  calling "Migrator::import_reverse_unfreeze(CDir *)".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 17:17:01 +02:00
Danny Al-Gaaf
de1e355360 mds/Migrator.cc: fix possible NULL pointer dereference
Move dout() calls behind the related asserts to prevent possible NULL
pointer dereference.

CID 717001 (#1 of 1): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "diri" when calling
  "operator <<(std::ostream &, CInode

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 17:06:40 +02:00
Danny Al-Gaaf
c266d7c7d4 mds/Server.cc: fix possible NULL pointer dereference
Add asserts to solve these CID issues:

CID 717002 (#1 of 2): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "dir"
  when calling "CDir::lookup(std::string const &, snapid_t)".
CID 717002 (#2 of 2): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "dir"
  when calling "CDir::lookup(std::string const &, snapid_t)".

CID 717003 (#1 of 2): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "dn" when
  calling "operator <<(std::ostream &, CDentry &)"
CID 717003 (#2 of 2): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "straydn"
  when calling "CDentry::push_projected_linkage()".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 15:45:22 +02:00
Danny Al-Gaaf
fd818a20c3 src/rbd.cc: silence CID COPY_PASTE_ERROR warning
CID 1021212 (#1 of 1): Copy-paste error (COPY_PASTE_ERROR)
  copy_paste_error: "r" in "r = -*__errno_location()" looks like
  a copy-paste error. Should it say "fd" instead?

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 15:45:18 +02:00
Danny Al-Gaaf
fa3149d21e mds/MDS.cc: fix dereference null return value
Fix for:

returned_null: Function "SessionMap::get_session(entity_name_t)" returns
  null (checked 12 out of 14 times)

CID 739601 (#1 of 1): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null
  "this->sessionmap.get_session(entity_name_t::CLIENT(client.v))" when
  calling "MDS::send_message_client_counted(Message *, Session *)"

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 15:42:52 +02:00
Danny Al-Gaaf
711810870e mds/MDCache.cc: fix possible NULL pointer dereference
Assert if 'cur' is NULL.

CID 966616 (#1 of 1): Dereference null return value (NULL_RETURNS)
  dereference: Dereferencing a pointer that might be null "cur" when
  calling "CInode::is_dir()".

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-05-22 15:38:26 +02:00
Sage Weil
5110497e31 doc: update mon cluster rescue process for cuttlefish+
Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 15:14:29 -07:00
David Zafman
132d5bf7f9 Fix usage for "ceph osd lost"
Will be superceded, but use this commit to backport

Signed-off-by: David Zafman <david.zafman@inktank.com>
Reviewed-by: Dan Mick <dan.mick@inktank.com>
2013-05-21 14:43:41 -07:00
Sage Weil
c0268e2749 mon: implement --extract-monmap <filename>
This will make for a simpler process for
  http://ceph.com/docs/master/rados/operations/add-or-rm-mons/#removing-monitors-from-an-unhealthy-cluster

Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 14:36:23 -07:00
Sage Weil
0822b3606a Merge pull request #306 from Elbandi/wip-fuse-ioctl
ceph-fuse: add ioctl support

Reviewed-by: Sage Weil <sage@inktank.com>
2013-05-21 14:26:40 -07:00
Sage Weil
5671fa9fe5 ceph-monstore-tool: implement getmonmap
Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 13:27:42 -07:00
Andras Elso
14d8cc6783 ceph-fuse: add ioctl support
Signed-off-by: Andras Elso <elso.andras@gmail.com>
2013-05-21 21:53:38 +02:00
Sage Weil
bcc8bfdb67 ceph-disk: fix stat errors with new suppress code
Broken by 225fefe5e7.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 12:52:20 -07:00
Alex Elder
bfb08ee4b2 rbd image_read.sh: test different clone object orders
An rbd clone image can be created with an object order that differs
from that of its parent.  This patch adds testing for that in
qa/workunits/rbd/image_read.sh.  By default, clone images will be
created with an object size twice as big as that of its parent.

For simplicity, when a clone's object order differs from its parent
the order will be either one more than or one less than that of its
parent image, meaning its object size is either double or half of
the size of objects used in the parent.

Signed-off-by: Alex Elder <elder@inktank.com>
2013-05-21 14:44:40 -05:00
Alex Elder
7ad5cebae1 rbd image_read.sh: add clone-of-clone testing
Add testing to verify that a snapshot of a clone and a clone of
that snapshot both produce the correct results when read.

Signed-off-by: Alex Elder <elder@inktank.com>
2013-05-21 14:44:38 -05:00
Alex Elder
a6b4847ef2 rbd image_read.sh: allocate local file at create time
Move the dd command that touches the last byte in a local file
into create_image() where it belongs (out of fill_original()).

Signed-off-by: Alex Elder <elder@inktank.com>
2013-05-21 14:44:35 -05:00
Alex Elder
512e907726 rbd image_read.sh: a few cleanups
The function boolean_toggle() in qa/workunits/rbd/image_read.sh is
defined but never used.  My intentions were good though.  Fix it and
use it for argument parsing.

Change the minimum supported object order so it matches what the
command line interface enforces.

Assign the initial value of TEST_CLONES from the environment if it's
available.

Change defaults to use format 2 and test clones.

Output details about the parameters of the run even if not being
verbose.

Make the order of assignment of argument variables consistent.

And fix a typo unmap_image().

Signed-off-by: Alex Elder <elder@inktank.com>
2013-05-21 14:44:30 -05:00
Sage Weil
cbff720ff5 rbd: prevent import of a dir
Fixes: #2865
Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 12:16:24 -07:00
Sage Weil
ebc0913677 ceph-monstore-tool: be more verbose when replaying a trace
Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 12:16:24 -07:00
Sage Weil
a6569c5f94 ceph-monstore-tool: compact command
Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 12:16:24 -07:00
Sage Weil
9cc787a9be ceph-monstore-tool: dump-keys command
Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 12:16:24 -07:00
Josh Durgin
bb64adb7ac Merge pull request #303 from ceph/wip-librbd-config-create
Reviewed-by: Sage Weil <sage.weil@inktank.com>
2013-05-21 11:16:53 -07:00
Sage Weil
bbcbab448b Merge branch 'next'
Conflicts:
	debian/ceph.prerm
2013-05-21 08:26:57 -07:00
Sage Weil
150e1706cc Merge pull request #304 from javacruft/wip-invoke-rc.d
Use invoke-rc.d in maintainer scripts
2013-05-21 08:25:21 -07:00
Sage Weil
1c7b9c3505 os/LevelDBStore: fix compression selection
We were always disabling compression.

Fixes: #5131
Reported-by: Sylvain Munaut <s.munaut@whatever-company.com>
Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 08:16:56 -07:00
James Page
19c5ac37ef Use invoke-rc.d in maintainer scripts
Upstart configurations and sysv init scripts should be started and stopped
using invoke-rc.d in maintainer scripts.

This ensures the correct behaviour across both Debian (sysv) and Ubuntu (upstart)
and in restricted environments such as schroot where start/stop of services from
maintainer scripts is normally disabled.

Signed-off-by: James Page <james.page@ubuntu.com>
2013-05-21 09:22:39 +01:00
Samuel Just
183280c864 PG: kill some dead IndexedLog methods
Signed-off-by: Samuel Just <sam.just@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>
2013-05-20 15:48:25 -07:00
Samuel Just
4cf00b9d5b OSD: kill old split code, it's been dead for a while
Signed-off-by: Samuel Just <sam.just@inktank.com>
Reviewed-by: David Zafman <david.zafman@inktank.com>
2013-05-20 15:32:53 -07:00
Sage Weil
d9c92e772c Merge pull request #260 from ceph/wip-suppress
Reviewed-by: Gary Lowell <gary.lowell@inktank.com>
2013-05-20 14:40:22 -07:00
Sage Weil
2f193fb931 debian: stop sysvinit on ceph.prerm
Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-20 14:39:16 -07:00
Sage Weil
d2a42538b1 mds: better error check on sessionmap load
Would have helped with #5104.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-20 13:34:05 -07:00
Sage Weil
87767fb1fb mon: be a bit more verbose about osd mark down events
Put these in the cluster log; they are interesting.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-20 12:41:30 -07:00
Sage Weil
03b93260f5 Makefile: add -Wformat-security
Clean up the formatting a bit here too.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-20 12:35:13 -07:00
Sage Weil
d37a7bcce4 Merge remote-tracking branch 'gh/next' 2013-05-20 12:22:29 -07:00
Sage Weil
80973a0002 Merge pull request #301 from javacruft/wip-upstart-tasks
Reviewed-by: Sage Weil <sage@inktank.com>
2013-05-20 09:10:04 -07:00
Sage Weil
ea6a262b5d Merge pull request #300 from javacruft/wip-format-security
Fix -Werror=format-security errors
2013-05-20 09:07:10 -07:00
Mike Kelly
d05a4e5574 ceph df: fix si units for 'global' stats
si_t expects bytes, but it was being given kilobytes.

Signed-off-by: Mike Kelly <pioto@pioto.org>
(cherry picked from commit 0c2b738d8d07994fee4c73dd076ac9364a64bdb2)
2013-05-20 09:06:09 -07:00
Sage Weil
90740d882a Merge pull request #302 from pioto/ceph-df-unit-fix
Reviewed-by: Sage Weil <sage@inktank.com>
2013-05-20 09:05:25 -07:00
Mike Kelly
0c2b738d8d ceph df: fix si units for 'global' stats
si_t expects bytes, but it was being given kilobytes.

Signed-off-by: Mike Kelly <pioto@pioto.org>
2013-05-20 08:48:35 -04:00