Commit Graph

55667 Commits

Author SHA1 Message Date
John Spray
40208315c9 Merge pull request #10027 from batrick/client-root-lock
client: add missing client_lock for get_root

Reviewed-by: John Spray <john.spray@redhat.com>
2016-07-06 14:12:55 +01:00
John Spray
47d3abe62e Merge pull request #10100 from fullerdj/wip-djf-16144
tools/cephfs: Remove cephfs-data-scan tmap_upgrade

Reviewed-by: John Spray <john.spray@redhat.com>
2016-07-06 14:12:09 +01:00
John Spray
835fdcac2d Merge pull request #9971 from fullerdj/wip-djf-16288
mds: Kill C_SaferCond in evict_sessions()

Reviewed-by: John Spray <john.spray@redhat.com>
2016-07-06 14:11:21 +01:00
Mykola Golub
9737a8d6cb qa/workunits/rbd: before removing image make sure it is not bootstrapped
If an image is being bootstrapped, it implies that the rbd-mirror
daemon currently has the image open. The removal API will prevent the
removal of any image that is opened by another client.

Works-around: http://tracker.ceph.com/issues/16555
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-07-06 12:59:25 +03:00
Jason Dillaman
a21b3df0ad cmake: fix incorrect dependencies to librados
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-07-06 00:12:03 -04:00
Kefu Chai
c8b36efd15 rpm: build rpm with cmake
Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-06 10:07:20 +08:00
Jason Dillaman
b342bf8ea1 Merge pull request #10136 from runsisi/sisi-wip-fix-missing-return
librbd: fix missing return statement if failed to get mirror image state

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2016-07-05 21:44:32 -04:00
Samuel Just
2daf3ef220 Merge pull request #10094 from athanatos/wip-throttle-test
test/common/Throttle.cc: fix race in shutdown

Reviewed-by: David Zafman <dzafman@redhat.com>
2016-07-05 10:50:50 -07:00
Casey Bodley
953fdecf15 Merge pull request #10088 from pritha-srivastava/wip_s3_signedurl_errors
rgw: Fix for using port 443 with pre-signed urls.

Reviewed-by: Casey Bodley <cbodley@redhat.com>
Reviewed-by: Matt Benjamin <mbenjamin@redhat.com>
2016-07-05 13:37:15 -04:00
Ali Maredia
59a46b96a5 Merge pull request #10112 from tchaikov/wip-cmake
cmake changes

Reviewed-by: Ali Maredia <amaredia@redhat.com>
2016-07-05 11:29:24 -04:00
Jason Dillaman
a700116ded Merge pull request #10134 from trociny/wip-run-rbd-tests-fixup
test: run-rbd-tests test cmake fixup

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2016-07-05 08:27:42 -04:00
Kefu Chai
0c13676126 Merge pull request #10133 from tchaikov/wip-fixc-cephtool-test.sh
test: cephtool/test.sh: fix expect_false() calls

Reviewed-by: Loic Dachary <ldachary@redhat.com>
2016-07-05 17:46:39 +08:00
Mykola Golub
8a1fa024a4 Merge pull request #10072 from dillaman/wip-16561
librbd: failed assertion after shrinking a clone image twice

Reviewed-by: Mykola Golub <mgolub@mirantis.com>
2016-07-05 11:44:45 +03:00
runsisi
ea775178b6 librbd: fix missing return statement if failed to get mirror image state
Signed-off-by: runsisi <runsisi@zte.com.cn>
2016-07-05 16:08:40 +08:00
Kefu Chai
5e16f2379d test: cephtool/test.sh: fix expect_false with pipe
this fixes failures like,

/home/jenkins-build/build/workspace/ceph-pull-requests/qa/workunits/cephtool/test.sh:
line 32: ceph osd blacklist ls | grep 192.168.0.1: command not found

where the failure is not the "failure" we are expecting.

in our tests, following command

expect_false "ceph osd blacklist ls | grep 192.168.0.1"

is designed to to verify that "ceph osd blacklist ls | grep 192.168.0.1"
fails with non-zero return code. but expect_false() evaluates the command
line using plain "$@", which will send the arguments direct to the shell,
and $0 is "ceph auth get client.xx | grep caps | grep mon", which does
not exist and is not built-in command. so we need to check the grep
command instead.

for multiple piped command line, use

expect_false sh <<< "echo foo  | grep bar | grep baz"

Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-05 15:26:43 +08:00
xie xingguo
643a4b04a8 os/bluestore: use p2 macros to simplify the _write() process
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2016-07-05 14:37:16 +08:00
Mykola Golub
acb4d67b0e test: run-rbd-tests test cmake fixup
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-07-05 09:27:00 +03:00
Brad Hubbard
d15ad96d38 tests: ceph-authtool, add test for empty "--add-key="
Signed-off-by: Brad Hubbard <bhubbard@redhat.com>
2016-07-05 15:35:08 +10:00
Brad Hubbard
00c2489685 authtool: Enhance argument combinations validation
Under certain circumstances ceph-authtool can create invalid key entries in
the specified keyring and behave less than intuitively. What's worse these
keys can currently cause ceph daemons to crash. This patch attempts to tighten
the behaviour and eliminate the possibility an invalid key can be created.

Fixes: http://tracker.ceph.com/issues/2904
Signed-off-by: Brad Hubbard <bhubbard@redhat.com>
2016-07-05 15:34:45 +10:00
Mykola Golub
5485296a3d Merge pull request #10076 from dillaman/wip-rbd-mirror-cmake
test: fix rbd-mirror workunit test cases for cmake

Reviewed-by: Mykola Golub <mgolub@mirantis.com>
2016-07-05 08:28:43 +03:00
Kefu Chai
38afdbe590 Merge pull request #9731 from badone/wip-doc-ceph-authtool-print-fix
doc: ceph-authtool man page option is --print-key not --print

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-05 13:03:46 +08:00
Kefu Chai
161e44554a Merge pull request #10124 from trociny/wip-cmake-tests
test: cmake related fixups for rbd tests

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-05 11:26:46 +08:00
xie xingguo
c48c19957c os/bluestore: fix potential access past eof during debugging prefill
1. pre-calculate r, so we don't have to do the division each loop, which
   is expensive.

2. make sure the extent to be allocated is within the block device size.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2016-07-05 11:10:32 +08:00
xie xingguo
b5a40d09e5 os/bluestore: introduce power 2 macros for block alignment and rounding
Macros for various sorts of alignment and rounding.
So we can get rid of the annoying division and mod operation and simplify
the blob/space access logic.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2016-07-05 10:38:24 +08:00
xie xingguo
25db05d3e7 os/bluestore: make sure path_fd is correctly closed during destruction
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2016-07-05 10:10:53 +08:00
xie xingguo
27657d6c80 os/bluestore: simplify buffer eviction logic of LRUCache
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2016-07-05 10:10:53 +08:00
Mykola Golub
3f66da7239 test: fix run-rbd-tests test for cmake
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-07-04 22:32:29 +03:00
Mykola Golub
8d1959ccfc test: fix run-rbd-valgrind-unit-tests when built with cmake
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-07-04 22:32:20 +03:00
Mykola Golub
0c4063d6b7 test: ceph_test_librbd does not need rados_test_stub
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-07-04 22:32:11 +03:00
Sage Weil
fa8107a0c5 Merge pull request #10117 from xiexingguo/xxg-wip-bluestore-2016-07-04
os/bluestore: fix incorrect pool decoding of bnode

Reviewed-by: Sage Weil <sage@redhat.com>
2016-07-04 10:55:29 -04:00
Kefu Chai
c6286c231c Merge pull request #9755 from dx9/wip-ns-name-uncompress
common/dns_resolve: use ns_name_uncompress instead of ns_name_ntop

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-04 21:53:20 +08:00
Kefu Chai
873aba7dd9 Merge pull request #9766 from dx9/wip-autotools-arch
configure.ac: Use uname instead of arch.

Reviewed-by: Willem Jan Withagen <wjw@digiware.nl>
2016-07-04 21:49:41 +08:00
Kefu Chai
ed473638e5 Merge pull request #9772 from tchaikov/wip-close-on-exec
msgr: set close on exec flag

Reviewed-by: Haomai Wang <haomai@xsky.com>
2016-07-04 21:47:42 +08:00
Kefu Chai
0efb391a40 Merge pull request #9820 from dx9/wip-fix-res-query-detect
configure.ac: fix res_query detection

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-04 21:46:55 +08:00
Kefu Chai
81ca1cbdd7 Merge pull request #9845 from dx9/wip-config-basename
common: remove basename() dependency

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-04 21:46:14 +08:00
Kefu Chai
c5d50caa67 Merge pull request #9969 from liewegas/wip-assert
include/assert: clean up ceph assertion macros

Reviewed-by: Greg Farnum <gfarnum@redhat.com>
2016-07-04 21:44:17 +08:00
Kefu Chai
a758a028b6 Merge pull request #9983 from SUSE/wip-cmake-fix-fcgi-include-dir
cmake: Fix FCGI include directory

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-04 21:43:24 +08:00
Kefu Chai
e0f15d9946 Merge pull request #10093 from tchaikov/wip-16525
crush: reset bucket->h.items[i] when removing tree item

Reviewed-by: Sage Weil <sage@redhat.com>
2016-07-04 21:42:34 +08:00
Kefu Chai
042c0aa957 Merge pull request #9330 from dachary/wip-15176-partprobe
ceph-disk: partprobe should block udev induced BLKRRPART

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-04 20:29:16 +08:00
Kefu Chai
8b433e13c2 Merge pull request #9394 from xiexingguo/xxg-wip-batchpgstates
mon/PGMonitor: batch filter pg states; add sanity check

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-04 20:19:20 +08:00
huanwen ren
c4a60ecdeb mds/CDentry: add path_ino and is_primary in the dump()
path_ino and is_primary are  main reference information in the dump(),
so add their

Signed-off-by: huanwen ren <ren.huanwen@zte.com.cn>
2016-07-04 20:04:38 +08:00
huanwen ren
f1d37778e4 mds: fixup dump Formatter' type error
fixup dump Formatter' type error,
dump_int->dump_unsigned

Signed-off-by: huanwen ren <ren.huanwen@zte.com.cn>
2016-07-04 19:22:21 +08:00
Anirudha Bose
238d13cadc pybind: Prefer using $TMPDIR if available
Signed-off-by: Anirudha Bose <ani07nov@gmail.com>
2016-07-04 14:39:07 +05:30
xie xingguo
29d2931d81 os/bluestore: fix incorrect pool decoding of bnode
"pool" is a pointer, and we shall alter its value instead.

Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
2016-07-04 17:08:59 +08:00
Kefu Chai
19c0731751 cmake: add ceph-{disk,detect-init} to ALL
Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-04 17:02:00 +08:00
Loic Dachary
8519481b72 ceph-disk: partprobe should block udev induced BLKRRPART
Wrap partprobe with flock to stop udev from issuing BLKRRPART because
this is racy and frequently fails with a message like:

    Error: Error informing the kernel about modifications to partition
    /dev/vdc1 -- Device or resource busy.  This means Linux won't know about
    any changes you made to /dev/vdc1 until you reboot -- so you shouldn't
    mount it or use it in any way before rebooting.

Opening a device (/dev/vdc for instance) in write mode indirectly
triggers a BLKRRPART ioctl from udev (starting version 214 and up)
when the device is closed (see below for the udev release note).

However, if udev fails to acquire an exclusive lock (with
flock(fd, LOCK_EX|LOCK_NB); ) the BLKRRPART ioctl is not issued.

045e00cf16/src/udev/udevd.c (L1042)

Acquiring an exclusive lock before running the process that opens the
device in write mode is therefore an effective way to control this
behavior.

git clone git://anonscm.debian.org/pkg-systemd/systemd.git
systemd/NEWS:
CHANGES WITH 214:

  * As an experimental feature, udev now tries to lock the
       disk device node (flock(LOCK_SH|LOCK_NB)) while it
       executes events for the disk or any of its partitions.
       Applications like partitioning programs can lock the
       disk device node (flock(LOCK_EX)) and claim temporary
       device ownership that way; udev will entirely skip all event
       handling for this disk and its partitions. If the disk
       was opened for writing, the close will trigger a partition
       table rescan in udev's "watch" facility, and if needed
       synthesize "change" events for the disk and all its partitions.
       This is now unconditionally enabled, and if it turns out to
       cause major problems, we might turn it on only for specific
       devices, or might need to disable it entirely. Device Mapper
       devices are excluded from this logic.

Fixes: http://tracker.ceph.com/issues/15176

Signed-off-by: Marius Vollmer <marius.vollmer@redhat com>
Signed-off-by: Loic Dachary <loic@dachary.org>
2016-07-04 11:01:32 +02:00
Orit Wasserman
76705d87ad Merge pull request #10077 from yehudasa/wip-16494
rgw: fix for issue 16494
2016-07-04 09:37:34 +02:00
Kefu Chai
b6a1e50ae8 Merge pull request #10064 from BlaXpirit/brag-py3
Port ceph-brag to Python 3 (+ small fixes)

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-04 15:00:50 +08:00
Kefu Chai
4ca9152512 Merge pull request #10115 from runsisi/ss-wip-fix-rpm-spec
ceph.spec.in: fix rpm package building error

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-04 14:08:35 +08:00
Kefu Chai
e1f67bdea8 cmake: do not depend on sse jerasure plugins if not avaiable
should not depend on them if SSE3 and/or SSE4 is not around.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-04 13:55:44 +08:00