Commit Graph

56407 Commits

Author SHA1 Message Date
Kefu Chai
5b14e28392 cmake: no need to depend run-tox-ceph-disk on test
run-tox-ceph-disk and run-tox-ceph-detect-init are already added as
test, so "ctest" and "make {test,check}" will run them without extra
settings.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-16 10:57:14 +08:00
Kefu Chai
ce5724effb cmake: add a "tests" target to build tests
please note "make test" is used by cmake to run tests, so we cannot just
repurpose it to *build* them.

* AddCephTest.cmake: depends on "tests"
* CMakeLists.txt: let "check" depend on "tests"
* src/CMakeLists.txt: update the run-tox tests
* run-make-check.sh: use "make tests" and "ctest" instead of "make check"
* ceph-detect-init/CMakeLists.txt: let "tests" depend on
    "ceph-detect-init"
* ceph-disk/CMakeLists.txt: let "tests" depend on "ceph-disk"

Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-16 10:57:12 +08:00
Yehuda Sadeh
3e5775475b Merge pull request #10301 from cbodley/wip-rgw-meta-stack-wakeup
rgw: RGWMetaSyncCR holds refs to stacks instead of crs

Reviewed-by: Yehuda Sadeh <yehuda@redhat.com>
Reviewed-by: Matt Benjamin <mbenjami@redhat.com>
2016-07-15 19:19:57 -07:00
Noah Watkins
d11a6be155 release: release notes update for objclass-perms
Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
2016-07-15 12:41:18 -07:00
Noah Watkins
298bc93954 osd: use static method and simplify return
Signed-off-by: Noah Watkins <noahwatkins@gmail.com>
2016-07-15 12:28:10 -07:00
Casey Bodley
e4bc16044e rgw: RGWMetaSyncCR holds refs to stacks for wakeup
because RGWCoroutine::wakeup() calls RGWCoroutinesStack::wakeup(), the
stack must also stay alive

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

Signed-off-by: Casey Bodley <cbodley@redhat.com>
2016-07-15 11:20:13 -04:00
Kefu Chai
4025a2eb80 Merge pull request #10306 from tchaikov/wip-no-mktemp-p
qa/workunits/cephtool/test.sh: s/TMPDIR/TEMP_DIR/

Reviewed-by: Haomai Wang <haomai@xsky.com>
2016-07-15 21:34:02 +08:00
Kefu Chai
bf58aeb6d5 Merge pull request #9972 from ceph/objclass-perm
osd: object class loading and execution permissions

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
2016-07-15 17:25:44 +08:00
Kefu Chai
316c15bc9d Merge pull request #9980 from gaowanlong/split_out_handle_pg_scrub
osd: small cleanups

Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-15 17:09:14 +08:00
Kefu Chai
9103958688 Merge pull request #10126 from dx9/wip-fcntl-warns
test/libcephfs: fix gcc sys/fcntl.h warnings

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-15 17:05:15 +08:00
Kefu Chai
56df5dcda4 Merge pull request #10166 from wjwithagen/wip-wjw-cmake-test_rados_tool.sh
test_rados_tool.sh: Make script work under ctest

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-15 17:03:59 +08:00
Kefu Chai
e0a5e67401 Merge pull request #9782 from Ved-vampir/zlib_cleanup
compressor: zlib compressor plugin  cleanup

Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-15 17:03:38 +08:00
Kefu Chai
83e64fad87 test: run_seed_to_range.sh: check existance of a directory using [ -d "$dir" ]
sadly, sh evalutes `[ -d ]` to true. as it takes "-d" as a non-empty
string as true.

this fixes following failure
```
2016-07-12T23:22:02.839 INFO:teuthology.orchestra.run.mira084.stderr:cp:
missing destination file operand after ‘.’
2016-07-12T23:22:02.839 INFO:teuthology.orchestra.run.mira084.stderr:Try
'cp --help' for more information.
```
see
http://pulpito.ceph.com/kchai-2016-07-12_23:09:35-rados-wip-kefu-testing2---basic-mira/311334/

Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-15 16:48:22 +08:00
Kefu Chai
7c1b456022 qa/workunits/cephtool/test.sh: s/TMPDIR/TEMP_DIR/
this fixes the test failure of
```
2016-07-12T23:29:40.935
INFO:tasks.workunit.client.0.mira101.stderr:/home/ubuntu/cephtest/workunit.client.0/cephtool/test.sh:
line 153: /CEPH_WATCH_9445: Permission denied
```
see
http://pulpito.ceph.com/kchai-2016-07-12_23:09:35-rados-wip-kefu-testing2---basic-mira/311333/

it's a regression introduced by e5c262b

Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-15 16:20:37 +08:00
Kefu Chai
e5c262bfe6 qa/workunits/cephtool/test.sh: use mktemp $TEMP_DIR/XXX instead
mktemp -p is not supported on FreeBSD

Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-15 14:21:52 +08:00
Kefu Chai
e0b94ff38d Merge pull request #10131 from badone/wip-peering-doc-fixes
doc: peering.rst, fix typo

Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@gmail.com>
Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-15 12:15:55 +08:00
Kefu Chai
b342e4f06b Merge pull request #10292 from badone/wip-perf-counters-doc-fixes
doc: perf_counters.rst fix trivial typo

Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@gmail.com>
Reviewed-by: xie xingguo <xie.xingguo@zte.com.cn>
Reviewed-by: Kefu Chai <kchai@redhat.com>
2016-07-15 12:13:19 +08:00
Yan, Zheng
ce166c2cd7 ObjectCacher: fix last_write check in bh_write_adjacencies()
Make the last_write check in bh_write_adjacencies() match corresponding
check in flush().

Fixes: http://tracker.ceph.com/issues/16610
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 11:39:01 +08:00
Kefu Chai
3be6e1c76b test: ceph-detect-init/run-tox.sh: run it from any path
this follows the pattern in ceph-disk. this enables us to run
ceph-detect-init/run-tox.sh from the ${CMAKE_BINARY_DIRECTORY}
as well.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2016-07-15 09:55:51 +08:00
Yan, Zheng
265f96bda7 client: fix MetaRequest::set_other_inode()
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:15:55 +08:00
Yan, Zheng
3099cabd11 client: close directory's snapdir when deleting directory
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:15:55 +08:00
Yan, Zheng
f180ad149a client: invalidate snap inodes after removing snapshot
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
85e687de87 mds: fix incorrect "unconnected snaprealm xxx" warning
If a snaprealm has no child/parent snaprelam, and the snaprealm inode
is not in the cache while client reconnects. The snaprealm does not
get properly removed from MDCache::reconnected_snaplrealm. This causes
incorrect "unconnected snaprealm xxx" warning

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
16f7d7c71e qa/workunits/fs: fix expect_failure function in test scripts
The origin expect_failure function return 0 regardness of command's
return value.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
d3916717e2 client: make sure snapflush is sent before normal cap message
MDS does null snapflush when it receives normal cap message. So client
must send snapflush first.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
a05e996b2a client: unify cap flush and snapcap flush
This patch includes following changes
- assign flush tid to snapcap flush
- remove session's flushing_capsnaps list. add inode with snapcap
  flushes to session's flushing_caps list instead.
- when reconnecting to MDS, re-send one inode's snapcap flushes and
  cap flushes at the same time.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
bc50e03092 mds: handle partly purged directory
For a snapshoted direcotry whose snaprealm parents are being opened,
MDS does not know if the directory is purgeable. So MDS can't skip
committing dirfrags of the directory. But if the direcotry is purgeale,
some dirfrags could have already been deleted during MDS failover.
Committing them could return -ENOENT.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
dd98448d3d mds: do files recovery after processing cap flushes
File recovery may update inode and trigger inode COW. MDS relies on
client caps to setup CInode::client_need_snapflush. But for a given
client, the reconnected caps may not include the flushing caps.
(Before MDS failover, client released and flushed some caps at the
same time. When MDS recovers, client re-send the cap flush and send
cap reconnect to the MDS.) This may cause later snapflush to get
dropped.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
57067e032e mds: combine MDCache::{reconnected_caps,cap_imports_dirty}
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
cfc3ec17b6 mds: remove CEPH_LOCK_IFLOCKL from cinode_lock_info
Currently we don't support dirty CEPH_CAP_FLOCK_EXCL

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
1b7d198f63 mds: rebuild the internal states that tracking pending snapflush
Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
25b6011dcf mds: using cap_reconnect_t to track cap recconect
Previous commit extended cap_reconnect_t to include snapflush
related information. This information are needed in various
places

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
dd3963a878 mds: add 'follows' of first pending snapflush to cap reconnect message
This helps the recovering MDS to reconstruct the internal states that
tracking pending snapflush.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
306153b3d0 mds: journal snap inodes that need flush when expiring log segment
Treat snap inodes that need flush in the same way as open files.
When MDS recovers, this make sure that journal replay bring snap
inodes that need flush into the cache

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yan, Zheng
4883779935 mds: properly update client_snap_caps when splitting snap inode
update the new snap inode's client_snap_caps according to the old
snap inode.

Signed-off-by: Yan, Zheng <zyan@redhat.com>
2016-07-15 09:11:49 +08:00
Yuri Weinstein
3f6daa90e2 Merge pull request #9491 from Yan-waller/yj-wip-fixbuildpushop
osd/ReplicatedBackend: add sanity check during build_push_op()

Reviewed-by: Haomai Wang <haomai@xsky.com>
2016-07-14 15:16:22 -07:00
Yuri Weinstein
f748b95966 Merge pull request #9510 from renhwztetecs/renhw-wip-common
common: unknown hash type of judgment modification

Reviewed-by: Sage Weil <sage@redhat.com>
2016-07-14 15:15:18 -07:00
Yuri Weinstein
5d1339bbc5 Merge pull request #9729 from stiopaa1/common_workqueue_addMove
common/WorkQueue: add std move

Reviewed-by: Casey Bodley <cbodley@redhat.com>
2016-07-14 15:14:39 -07:00
Yuri Weinstein
125c42a452 Merge pull request #9770 from tanghaodong25/submit-transaction-perfcounter
kv/RocksDB: add perfcounter for submit_transaction_sync operation

Reviewed-by: Sage Weil <sage@redhat.com>
2016-07-14 15:13:31 -07:00
Casey Bodley
49001d99ed Merge pull request #10274 from yehudasa/wip-16665
rgw: collect skips a specific coroutine stack

Reviewed-by: Casey Bodley <cbodley@redhat.com>
2016-07-14 17:06:11 -04:00
Mykola Golub
ba849e3b04 librbd: prevent creation of clone from non-primary mirrored image
Fixes: http://tracker.ceph.com/issues/16449
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-07-14 23:02:18 +03:00
Yehuda Sadeh
f01f2190b5 Merge pull request #10187 from dreamhost/wip-16618
rgw: fix multi-delete query param parsing.

Reviewed-by: Yehuda Sadeh <yehuda@redhat.com>
2016-07-14 11:42:37 -07:00
Samuel Just
6785393c04 Merge pull request #10289 from jdurgin/wip-googletest-centos
fix the rpm build for centos

Reviewed-by: Samuel Just <sjust@redhat.com>
2016-07-14 07:48:35 -07:00
Samuel Just
57264b9bf3 ReplicatedPG::on_removal: clear missing set as well
Signed-off-by: Samuel Just <sjust@redhat.com>
2016-07-14 07:48:14 -07:00
Samuel Just
820c5b7028 osd: add option to verify stored missing on start
Signed-off-by: Samuel Just <sjust@redhat.com>
2016-07-14 07:48:14 -07:00
Samuel Just
56b3f4bf66 OSD: add superblock incompat bit for explicit missing
Signed-off-by: Samuel Just <sjust@redhat.com>
2016-07-14 07:48:14 -07:00
Samuel Just
c47d14a59b TestPGLog: verify that the tracker is tracking changes in the test cases
Signed-off-by: Samuel Just <sjust@redhat.com>
2016-07-14 07:48:14 -07:00
Samuel Just
44cb6d3064 PGLog,ceph_objectstore_tool: persist the missing set
As a side effect, the divergent_priors set is no longer
necessary, remove it.  Also, ceph_objectstore_tool needed
to be updated to handle the new format.

Signed-off-by: Samuel Just <sjust@redhat.com>
2016-07-14 07:48:13 -07:00
Samuel Just
3fc1c7e3fd PGLog: s/read_log/read_log_and_missing/g
Signed-off-by: Samuel Just <sjust@redhat.com>
2016-07-14 07:48:13 -07:00
Samuel Just
9e1cc04822 PGLog: s/write_log/write_log_and_missing/g
Signed-off-by: Samuel Just <sjust@redhat.com>
2016-07-14 07:48:13 -07:00