]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
7 years agomon/OSDMonitor: rename outer name declaration to avoid shadowing 20032/head
Sage Weil [Fri, 19 Jan 2018 13:26:52 +0000 (07:26 -0600)]
mon/OSDMonitor: rename outer name declaration to avoid shadowing

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agomon/OSDMonitor: squelch 'id' arg errors 19998/head
Sage Weil [Wed, 17 Jan 2018 17:23:39 +0000 (11:23 -0600)]
mon/OSDMonitor: squelch 'id' arg errors

Several commands use 'id' but for other types (e.g., vector<int64_t>).

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agouse stringsream::str(), not rdbuf()
Sage Weil [Wed, 17 Jan 2018 17:22:55 +0000 (11:22 -0600)]
use stringsream::str(), not rdbuf()

Fixes: http://tracker.ceph.com/issues/22715
Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoMerge pull request #17520 from joscollin/wip-cleanup-drop-return
Casey Bodley [Wed, 17 Jan 2018 15:18:07 +0000 (10:18 -0500)]
Merge pull request #17520 from joscollin/wip-cleanup-drop-return

rgw: Drop unnecessary return

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge PR #19803 into master
Patrick Donnelly [Wed, 17 Jan 2018 04:06:37 +0000 (20:06 -0800)]
Merge PR #19803 into master

* refs/pull/19803/head:
mds: get rid of unnecessary if condition

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Sage Weil <sage@redhat.com>
7 years agoMerge PR #19837 into master
Patrick Donnelly [Wed, 17 Jan 2018 04:06:31 +0000 (20:06 -0800)]
Merge PR #19837 into master

* refs/pull/19837/head:
client: avoid recursive lock in ll_get_vino

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Jeff Layton <jlayton@redhat.com>
Reviewed-by: huanwen ren <ren.huanwen@zte.com.cn>
7 years agoMerge PR #19860 into master
Patrick Donnelly [Wed, 17 Jan 2018 04:06:26 +0000 (20:06 -0800)]
Merge PR #19860 into master

* refs/pull/19860/head:
cephfs-journal-tool: add usage help info for header set <field>
mds: add error log info
cephfs-journal-tool: add "set pool_id" option

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
7 years agoMerge PR #19891 into master
Patrick Donnelly [Wed, 17 Jan 2018 04:06:21 +0000 (20:06 -0800)]
Merge PR #19891 into master

* refs/pull/19891/head:
mds: handle 'inode gets queued for recovery multiple times'
mds: use elist to track recover queue items

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
7 years agoMerge PR #19911 into master
Patrick Donnelly [Wed, 17 Jan 2018 04:06:12 +0000 (20:06 -0800)]
Merge PR #19911 into master

* refs/pull/19911/head:
cephfs: Switch MIN/MAX for std::min/max and use intarith templates

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
7 years agoMerge pull request #19876 from theanalyst/build/do-cmake-args
Kefu Chai [Wed, 17 Jan 2018 01:50:26 +0000 (09:50 +0800)]
Merge pull request #19876 from theanalyst/build/do-cmake-args

build: do_cmake: allow ARGS to be overridden

Reviewed-by: Kefu Chai <kchai@redhat.com>
7 years agoMerge pull request #19433 from liewegas/wip-pg-removal
Sage Weil [Tue, 16 Jan 2018 21:44:27 +0000 (15:44 -0600)]
Merge pull request #19433 from liewegas/wip-pg-removal

osd: put pg removal in op_wq

Reviewed-by: Greg Farnum <gfarnum@redhat.com>
7 years agoosd/PrimaryLogPG: do on_shutdown on removal 19433/head
Sage Weil [Fri, 12 Jan 2018 19:26:16 +0000 (13:26 -0600)]
osd/PrimaryLogPG: do on_shutdown on removal

This cleans up our reservations and misc other state in OSDService that
needs to be cleaned up.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd: track deleted pools' pg_nums for calculating split
Sage Weil [Tue, 9 Jan 2018 21:18:58 +0000 (15:18 -0600)]
osd: track deleted pools' pg_nums for calculating split

This is needed to determine (quickly) whether PGs have split.  Calling
get_pg_num() on the latest map does not work when the pool has been
deleted from that map.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoMerge pull request #19850 from dzafman/wip-calc-stats
David Zafman [Tue, 16 Jan 2018 19:58:49 +0000 (11:58 -0800)]
Merge pull request #19850 from dzafman/wip-calc-stats

osd/PG: re-write of _update_calc_stats and improve pg degraded state

Fixes: http://tracker.ceph.com/issues/20059
Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Josh Durgin <jdurgin@redhat.com>
7 years agotests: recovery-unfound-found test needs to account for correct misplaced calculations 19850/head
David Zafman [Tue, 16 Jan 2018 18:44:29 +0000 (10:44 -0800)]
tests: recovery-unfound-found test needs to account for correct misplaced calculations

The test expected HEALTH_OK when in a state with misplaced objects therefore HEALTH_WARN

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoMerge pull request #19613 from qrGitHub/wip-rgw-optimize-bucketLCPrepare
Yuri Weinstein [Tue, 16 Jan 2018 17:06:21 +0000 (09:06 -0800)]
Merge pull request #19613 from qrGitHub/wip-rgw-optimize-bucketLCPrepare

rgw: optimize function bucket_lc_prepare

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #19878 from cbodley/wip-rgw-get-omap-keys-cr
Yuri Weinstein [Tue, 16 Jan 2018 17:05:28 +0000 (09:05 -0800)]
Merge pull request #19878 from cbodley/wip-rgw-get-omap-keys-cr

rgw: fix handling of ENOENT in RGWRadosGetOmapKeysCR

Reviewed-by: Adam Emerson <aemerson@redhat.com>
7 years agoMerge pull request #19897 from cbodley/wip-rgw-put-system-obj
Yuri Weinstein [Tue, 16 Jan 2018 17:04:36 +0000 (09:04 -0800)]
Merge pull request #19897 from cbodley/wip-rgw-put-system-obj

rgw: rgw_put_system_obj takes bufferlist

Reviewed-by: Matt Benjamin <mbenjami@redhat.com>
Reviewed-by: Orit Wasserman <owasserm@redhat.com>
7 years agoMerge pull request #19945 from tchaikov/wip-deprecated-in-cxx17
Kefu Chai [Tue, 16 Jan 2018 14:16:43 +0000 (22:16 +0800)]
Merge pull request #19945 from tchaikov/wip-deprecated-in-cxx17

librbd,librados: do not include stdbool.h in C++ headers

Reviewed-by: Adam C. Emerson <aemerson@redhat.com>
7 years agoMerge pull request #19261 from dillaman/wip-22286
Kefu Chai [Tue, 16 Jan 2018 14:15:47 +0000 (22:15 +0800)]
Merge pull request #19261 from dillaman/wip-22286

mgr: disconnect unregistered service daemon when report received

Reviewed-By: Kefu Chai <kchai@redhat.com>
7 years agoMerge pull request #19942 from shinobu-x/wip-sk-minmax-ms_async_op_threads
Sage Weil [Tue, 16 Jan 2018 13:33:22 +0000 (07:33 -0600)]
Merge pull request #19942 from shinobu-x/wip-sk-minmax-ms_async_op_threads

common: Add min/max of ms_async_op_threads

Reviewed-by: Sage Weil <sage@redhat.com>
7 years agoMerge pull request #19397 from xxhdx1985126/master
Sage Weil [Tue, 16 Jan 2018 13:33:09 +0000 (07:33 -0600)]
Merge pull request #19397 from xxhdx1985126/master

mon: update PaxosService::cached_first_committed in PaxosService::maybe_trim()

Reviewed-by: Kefu Chai <kchai@redhat.com>
Reviewed-by: Sage Weil <sage@redhat.com>
7 years agoMerge pull request #19822 from trociny/wip-ggate-ceph-globals
Jason Dillaman [Mon, 15 Jan 2018 13:51:34 +0000 (08:51 -0500)]
Merge pull request #19822 from trociny/wip-ggate-ceph-globals

rbd-ggate: fix parsing ceph global options

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
Reviewed-by: Willem Jan Withagen <wjw@digiware.nl>
7 years agoMerge pull request #19673 from zouaiguo/wip_erase_code
Kefu Chai [Mon, 15 Jan 2018 10:34:34 +0000 (18:34 +0800)]
Merge pull request #19673 from zouaiguo/wip_erase_code

mon/OSDMonitor.cc : set erasure-code-profile to "" when create replicated pools.

Reviewed-by: Joao Eduardo Luis <joao@suse.de>
Reviewed-by: Kefu Chai <kchai@redhat.com>
7 years agoMerge pull request #19896 from tchaikov/wip-vive-cxx-17
Kefu Chai [Mon, 15 Jan 2018 03:27:28 +0000 (11:27 +0800)]
Merge pull request #19896 from tchaikov/wip-vive-cxx-17

msg/simple: s/ceph::size/std::size/

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Adam C. Emerson <aemerson@redhat.com>
7 years agoMerge pull request #19870 from liewegas/wip-strip-ceph-base
Kefu Chai [Mon, 15 Jan 2018 03:24:08 +0000 (11:24 +0800)]
Merge pull request #19870 from liewegas/wip-strip-ceph-base

debian/rules: strip ceph-base libraries

Reviewed-By: Kefu Chai <kchai@redhat.com>
7 years agoMerge pull request #18755 from aclamk/wip-reverted-approx-size
Kefu Chai [Mon, 15 Jan 2018 03:14:45 +0000 (11:14 +0800)]
Merge pull request #18755 from aclamk/wip-reverted-approx-size

osd/PG: revert approx size

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: xie xingguo <xie.xingguo@zte.com.cn>
Reviewed-by: Kefu Chai <kchai@redhat.com>
7 years agoMerge pull request #18191 from hjwsm1989/osd-mark-down
Kefu Chai [Mon, 15 Jan 2018 03:09:02 +0000 (11:09 +0800)]
Merge pull request #18191 from hjwsm1989/osd-mark-down

qa/standalone/osd/osd-mark-down: create pool to get updated osdmap faster

Reviewed-by: Kefu Chai <kchai@redhat.com>
7 years agoMerge pull request #19877 from adamemerson/wip-dencish
Kefu Chai [Mon, 15 Jan 2018 03:06:12 +0000 (11:06 +0800)]
Merge pull request #19877 from adamemerson/wip-dencish

denc cleanups and other fixes

Reviewed-by: Willem Jan Withagen <wjw@digiware.nl>
Reviewed-by: Kefu Chai <kchai@redhat.com>
7 years agotest: Verify stat calculations during backfill
David Zafman [Wed, 29 Nov 2017 01:51:52 +0000 (17:51 -0800)]
test: Verify stat calculations during backfill

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agotest: Verify stat calculations during recovery
David Zafman [Sat, 18 Nov 2017 01:01:56 +0000 (17:01 -0800)]
test: Verify stat calculations during recovery

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoceph-helpers.sh: Add flush_pg_stats() to wait_for_clean() to make it reliable
David Zafman [Thu, 11 Jan 2018 22:22:54 +0000 (14:22 -0800)]
ceph-helpers.sh: Add flush_pg_stats() to wait_for_clean() to make it reliable

osd-scrub-repair.sh: Fixes for omap keys landing on different OSDs due to flush

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoosd: Don't start recovery for missing until active pg state set
David Zafman [Wed, 10 Jan 2018 21:30:41 +0000 (13:30 -0800)]
osd: Don't start recovery for missing until active pg state set

I was seeing recovery hang when it is started before _activate_committed()
The state machine passes into "Active" but this transitions to activating
pg state and after commmitted into "active" pg state.

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoqa: Ignore degraded PGs when injecting random eio errors
David Zafman [Mon, 4 Dec 2017 21:02:04 +0000 (13:02 -0800)]
qa: Ignore degraded PGs when injecting random eio errors

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoosd: Improve the way insufficient targets is handled to be compatible with EC
David Zafman [Sat, 18 Nov 2017 18:16:53 +0000 (10:16 -0800)]
osd: Improve the way insufficient targets is handled to be compatible with EC

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoosd: Improve pg degraded state setting based on _update_calc_stats() degraded count
David Zafman [Wed, 1 Nov 2017 01:15:53 +0000 (18:15 -0700)]
osd: Improve pg degraded state setting based on _update_calc_stats() degraded count

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoMerge pull request #19946 from liewegas/wip-22677
Sage Weil [Sun, 14 Jan 2018 19:40:54 +0000 (13:40 -0600)]
Merge pull request #19946 from liewegas/wip-22677

qa/workunits/rados/test_rados_tool: fix stray |, race

7 years agoosd: Handling when recovery sources have missing
David Zafman [Thu, 26 Oct 2017 22:36:54 +0000 (15:36 -0700)]
osd: Handling when recovery sources have missing

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoosd: Base pg degraded state on num_degraded_objects
David Zafman [Thu, 26 Oct 2017 04:44:14 +0000 (21:44 -0700)]
osd: Base pg degraded state on num_degraded_objects

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoosd: Rewrite _update_calc_stats() to make it cleaner and more accurate
David Zafman [Wed, 25 Oct 2017 16:37:00 +0000 (09:37 -0700)]
osd: Rewrite _update_calc_stats() to make it cleaner and more accurate

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoosd: cleanup: Remove unused const vars
David Zafman [Tue, 14 Nov 2017 21:00:06 +0000 (13:00 -0800)]
osd: cleanup: Remove unused const vars

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoosd: cleanup: Fix log message
David Zafman [Thu, 26 Oct 2017 17:36:32 +0000 (10:36 -0700)]
osd: cleanup: Fix log message

Signed-off-by: David Zafman <dzafman@redhat.com>
7 years agoqa/workunits/rados/test_rados_tool: remove stray |, fix race 19946/head
Sage Weil [Sun, 14 Jan 2018 16:35:14 +0000 (10:35 -0600)]
qa/workunits/rados/test_rados_tool: remove stray |, fix race

Fixes: http://tracker.ceph.com/issues/22676
Signed-off-by: Sage Weil <sage@redhat.com>
7 years agolibrbd,librados: do not include stdbool.h in C++ headers 19945/head
Kefu Chai [Sun, 14 Jan 2018 10:02:26 +0000 (18:02 +0800)]
librbd,librados: do not include stdbool.h in C++ headers

stdbool.h is offered to provide C++ keywords for C source file.

Signed-off-by: Kefu Chai <kchai@redhat.com>
7 years agoMerge pull request #12431 from VictorDenisov/snapshot_rename
Jason Dillaman [Sun, 14 Jan 2018 01:48:39 +0000 (20:48 -0500)]
Merge pull request #12431 from VictorDenisov/snapshot_rename

rbd: group snapshot rename

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
7 years agocephfs: Switch MIN/MAX for std::min/max and use intarith templates 19911/head
Adam C. Emerson [Thu, 11 Jan 2018 03:24:17 +0000 (22:24 -0500)]
cephfs: Switch MIN/MAX for std::min/max and use intarith templates

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agorbd: Add group snapshot rename commands
Victor Denisov [Thu, 1 Dec 2016 20:40:16 +0000 (12:40 -0800)]
rbd: Add group snapshot rename commands

Signed-off-by: Victor Denisov <denisovenator@gmail.com>
7 years agolibrbd: Add group snap rename method
Victor Denisov [Fri, 2 Dec 2016 20:43:42 +0000 (12:43 -0800)]
librbd: Add group snap rename method

Signed-off-by: Victor Denisov <denisovenator@gmail.com>
7 years agoqa/workunits/rados/test_rados_tool.sh: -x
Sage Weil [Sat, 13 Jan 2018 16:07:31 +0000 (10:07 -0600)]
qa/workunits/rados/test_rados_tool.sh: -x

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoMerge pull request #19913 from adamemerson/wip-minimax-rados
Sage Weil [Sat, 13 Jan 2018 15:56:28 +0000 (09:56 -0600)]
Merge pull request #19913 from adamemerson/wip-minimax-rados

rados: Prefer templates to macros

Reviewed-by: Kefu Chai <kchai@redhat.com>
7 years agoMerge pull request #19914 from tchaikov/wip-cmake-check-boost-in-src
Sage Weil [Sat, 13 Jan 2018 15:56:08 +0000 (09:56 -0600)]
Merge pull request #19914 from tchaikov/wip-cmake-check-boost-in-src

cmake: check version of boost in src/boost

Reviewed-by: Casey Bodley <cbodley@redhat.com>
Reviewed-by: Brad Hubbard <bhubbard@redhat.com>
7 years agoMerge pull request #19926 from batrick/i22527
Sage Weil [Sat, 13 Jan 2018 15:55:12 +0000 (09:55 -0600)]
Merge pull request #19926 from batrick/i22527

mon: revert mds metadata argument name change

Reviewed-by: Kefu Chai <kchai@redhat.com>
Reviewed-by: Sage Weil <sage@redhat.com>
7 years agoMerge pull request #19903 from dillaman/wip-librbd-op-features
Mykola Golub [Sat, 13 Jan 2018 02:13:49 +0000 (04:13 +0200)]
Merge pull request #19903 from dillaman/wip-librbd-op-features

librbd: add preliminary support for new operation feature bit

Reviewed-by: Mykola Golub <mgolub@suse.com>
7 years agocommon: Add min/max of ms_async_op_threads 19942/head
Shinobu Kinjo [Sat, 13 Jan 2018 01:02:39 +0000 (10:02 +0900)]
common: Add min/max of ms_async_op_threads

Signed-off-by: Shinobu Kinjo <shinobu@redhat.com>
7 years agoMerge pull request #19793 from badone/wip-blocking-deep-scrub
Yuri Weinstein [Fri, 12 Jan 2018 22:47:30 +0000 (14:47 -0800)]
Merge pull request #19793 from badone/wip-blocking-deep-scrub

ceph.in: Add blocking mode for scrub and deep-scrub

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
7 years agoMerge pull request #19910 from jdurgin/wip-21897
Yuri Weinstein [Fri, 12 Jan 2018 22:46:26 +0000 (14:46 -0800)]
Merge pull request #19910 from jdurgin/wip-21897

config: lower default omap entries recovered at once

Reviewed-by: Sage Weil <sage@redhat.com>
7 years agoMerge PR #19894 into master
Patrick Donnelly [Fri, 12 Jan 2018 22:37:39 +0000 (14:37 -0800)]
Merge PR #19894 into master

* refs/pull/19894/head:
cmake: link against ceph-common instead of common

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
7 years agoMerge PR #19920 into master
Patrick Donnelly [Fri, 12 Jan 2018 22:37:32 +0000 (14:37 -0800)]
Merge PR #19920 into master

* refs/pull/19920/head:
client: fix cap revoke race
client: release revoking Fc after invalidate cache

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
7 years agoMerge PR #19885 into master
Patrick Donnelly [Fri, 12 Jan 2018 22:37:25 +0000 (14:37 -0800)]
Merge PR #19885 into master

* refs/pull/19885/head:
qa: increase osd count for ec testing
qa: add missing openstack configs

Reviewed-by: Sage Weil <sage@redhat.com>
7 years agorgw: RGWRados::put_system_obj takes const bufferlist 19897/head
Casey Bodley [Fri, 12 Jan 2018 18:41:50 +0000 (13:41 -0500)]
rgw: RGWRados::put_system_obj takes const bufferlist

Signed-off-by: Casey Bodley <cbodley@redhat.com>
7 years agorados: Switch MIN/MAX for std::min/max and use intarith templates 19913/head
Adam C. Emerson [Thu, 11 Jan 2018 03:24:46 +0000 (22:24 -0500)]
rados: Switch MIN/MAX for std::min/max and use intarith templates

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agoMerge pull request #19900 from dillaman/wip-rbd-lock-list
Mykola Golub [Fri, 12 Jan 2018 19:31:54 +0000 (21:31 +0200)]
Merge pull request #19900 from dillaman/wip-rbd-lock-list

rbd: adjusted "lock list" JSON and XML formatted output

Reviewed-by: Mykola Golub <mgolub@suse.com>
7 years agorgw: rgw_put_system_obj takes bufferlist
Casey Bodley [Wed, 10 Jan 2018 14:37:02 +0000 (09:37 -0500)]
rgw: rgw_put_system_obj takes bufferlist

all callers were converting from bufferlist to const char*, then
RGWRados::put_system_obj() copied that back into a new bufferlist

Signed-off-by: Casey Bodley <cbodley@redhat.com>
7 years agoMerge pull request #19933 from qrGitHub/wip-rgw-useless-line4
Casey Bodley [Fri, 12 Jan 2018 18:17:48 +0000 (13:17 -0500)]
Merge pull request #19933 from qrGitHub/wip-rgw-useless-line4

rgw: drop redundant RGW_OP_STAT_OBJ check

Reviewed-by: Casey Bodley <cbodley@redhat.com>
7 years agorbd: adjusted "lock list" JSON and XML formatted output 19900/head
Jason Dillaman [Wed, 10 Jan 2018 19:46:07 +0000 (14:46 -0500)]
rbd: adjusted "lock list" JSON and XML formatted output

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
7 years agolibrbd: operations should return -EROFS if disabled 19903/head
Jason Dillaman [Fri, 12 Jan 2018 15:46:33 +0000 (10:46 -0500)]
librbd: operations should return -EROFS if disabled

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
7 years agolibrbd: retrieve the op features on image refresh
Jason Dillaman [Fri, 5 Jan 2018 18:54:24 +0000 (13:54 -0500)]
librbd: retrieve the op features on image refresh

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
7 years agolibrbd: track new operation features within image
Jason Dillaman [Fri, 5 Jan 2018 02:50:02 +0000 (21:50 -0500)]
librbd: track new operation features within image

This will initially be utilized to restrict older clients from
performing operations against an image if (1) it doesn't
support the new feature bit, or (2) doesn't support the specific
enabled op feature.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
7 years agoinclude: Add templates along side macros in intarith 19905/head
Adam C. Emerson [Wed, 10 Jan 2018 22:06:53 +0000 (17:06 -0500)]
include: Add templates along side macros in intarith

The macros can be removed later.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agorgw: drop redundant RGW_OP_STAT_OBJ check 19933/head
Bingyin Zhang [Fri, 12 Jan 2018 06:26:30 +0000 (14:26 +0800)]
rgw: drop redundant RGW_OP_STAT_OBJ check

Signed-off-by: Bingyin Zhang <zhangbingyin@cloudin.cn>
7 years agodenc: Clean up tuples even more 19877/head
Adam C. Emerson [Wed, 10 Jan 2018 04:29:06 +0000 (23:29 -0500)]
denc: Clean up tuples even more

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agotypes: Output of arbitrary std::tuples
Adam C. Emerson [Wed, 10 Jan 2018 04:28:37 +0000 (23:28 -0500)]
types: Output of arbitrary std::tuples

Again, using ceph::for_each

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agoencoding: Encode/decode of arbitrary tuples
Adam C. Emerson [Wed, 10 Jan 2018 04:27:51 +0000 (23:27 -0500)]
encoding: Encode/decode of arbitrary tuples

Using ceph::for_each to avoid fiddling with indices everywhere.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agocommon: Add ceph::for_each for tuples
Adam C. Emerson [Wed, 10 Jan 2018 04:26:48 +0000 (23:26 -0500)]
common: Add ceph::for_each for tuples

Expand to pairs, optionals, and variants later.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agocommon: Make maybe functions support std::optional
Adam C. Emerson [Wed, 10 Jan 2018 01:25:31 +0000 (20:25 -0500)]
common: Make maybe functions support std::optional

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agodenc: Simplify tuple decode/encode
Adam C. Emerson [Tue, 9 Jan 2018 22:53:26 +0000 (17:53 -0500)]
denc: Simplify tuple decode/encode

Use index_sequence instead of rolling our own support infrastructure.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agodenc: Fix std::array bound_encode
Adam C. Emerson [Tue, 9 Jan 2018 22:09:55 +0000 (17:09 -0500)]
denc: Fix std::array bound_encode

std::arrays are not variable length structures and thus are not
encoded with a length.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agodenc: Remove unneeded enable_ifs
Adam C. Emerson [Tue, 9 Jan 2018 22:03:03 +0000 (17:03 -0500)]
denc: Remove unneeded enable_ifs

The idiom
```
template<typename U = T>
static enable_if_t<!!sizeof(U) && ... >
```

Exists to force SFINAE dependent on some aspect of T on functions that
are themselves members of a template parameterized on T. Without some
other expression conjoined to it, this construct is just noise.

Also replace the reserve switch with constexpr if.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agodenc: Simplify is_any_of
Adam C. Emerson [Tue, 9 Jan 2018 21:15:34 +0000 (16:15 -0500)]
denc: Simplify is_any_of

We can't simplify underlying type in the obvious way since template
evaluation is strict.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agodenc: Support std::optional
Adam C. Emerson [Tue, 9 Jan 2018 20:37:46 +0000 (15:37 -0500)]
denc: Support std::optional

Since we'll probably want to use it at some point.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years ago{common,mds,rbd}: Fix unused lambda capture warnings
Adam C. Emerson [Tue, 9 Jan 2018 19:54:11 +0000 (14:54 -0500)]
{common,mds,rbd}: Fix unused lambda capture warnings

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agodenc: Unbreak Clang support
Adam C. Emerson [Tue, 9 Jan 2018 18:11:10 +0000 (13:11 -0500)]
denc: Unbreak Clang support

We were using an enable_if<sizeof(U)> idiom that Clang rejects as an
illicit narrowing conversion.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
7 years agodoc/man: Add '--block' option for ceph command 19793/head
Brad Hubbard [Fri, 12 Jan 2018 02:47:36 +0000 (12:47 +1000)]
doc/man: Add '--block' option for ceph command

Signed-off-by: Brad Hubbard <bhubbard@redhat.com>
7 years agoMerge pull request #19886 from liu-chunmei/fix_dpdk_worker_references_issue
Haomai Wang [Fri, 12 Jan 2018 02:38:30 +0000 (10:38 +0800)]
Merge pull request #19886 from liu-chunmei/fix_dpdk_worker_references_issue

osd: fix dpdk worker references issue

Reviewed-by: Haomai Wang <haomai@xsky.com>
7 years agorbd: hide implicit / non-mutable features from the CLI help
Jason Dillaman [Fri, 5 Jan 2018 16:31:37 +0000 (11:31 -0500)]
rbd: hide implicit / non-mutable features from the CLI help

The layering and data-pool features are enabled automatically
when striping or a data pool is specified, respectively. For
the 'rbd feature XYZ' command, hide all non-mutable features.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
7 years agoosd: record final pg_pool_t when a pool is deleted
Sage Weil [Tue, 9 Jan 2018 21:05:25 +0000 (15:05 -0600)]
osd: record final pg_pool_t when a pool is deleted

Also, prevent OSD start if we have a PG whose pool is deleted and no
stored pool info.  (User should downgrade, let PG deletion complete, then
upgrade.)

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd/PG: simplify snapmapper init
Sage Weil [Tue, 9 Jan 2018 20:39:23 +0000 (14:39 -0600)]
osd/PG: simplify snapmapper init

Use PGPool info; don't look at map (pool may have been deleted).

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd/PG: drop PGPool auid member
Sage Weil [Tue, 9 Jan 2018 19:56:36 +0000 (13:56 -0600)]
osd/PG: drop PGPool auid member

It's at info.auid.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd: tolerate startup for pg with no pool in osdmap
Sage Weil [Thu, 4 Jan 2018 17:06:19 +0000 (11:06 -0600)]
osd: tolerate startup for pg with no pool in osdmap

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd/PG: clear requeued peering events
Sage Weil [Tue, 2 Jan 2018 21:25:01 +0000 (15:25 -0600)]
osd/PG: clear requeued peering events

Broken by fffcc8a50e684c9b67643ec002869a8b7024b01c

Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 3f07137f5f6b0448271be273db7b375ab1844d38)

7 years agoosd/PG: use local_reserver to schedule delete
Sage Weil [Tue, 19 Dec 2017 17:48:26 +0000 (11:48 -0600)]
osd/PG: use local_reserver to schedule delete

Use the reserver so that delete competes for the same slot(s) as recovery
and such.

Priority below recovery normally, unless the OSD is getting fullish, in
which case we set a very high priority.  We have to be careful here because
backfill will back off when the OSD gets full(ish) but log recovery does
not.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd: identify splits even if pool is eventually deleted
Sage Weil [Thu, 14 Dec 2017 21:09:04 +0000 (15:09 -0600)]
osd: identify splits even if pool is eventually deleted

Previously we wouldn't bother splitting if the pool was going away; now
we walk the pg forward and will process the split even if the pool is
later deleted.  Adjust the loop to terminate gracefully if that happens.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd: clean up pending splits when removing a pg
Sage Weil [Thu, 14 Dec 2017 02:15:17 +0000 (20:15 -0600)]
osd: clean up pending splits when removing a pg

Say we get an osdmap indicating a pg will split, but the pg is deleting and
finishes its delete before the pg consumes that map.  We need to clean up
the pending split state.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd: always call complete_split()
Sage Weil [Wed, 13 Dec 2017 00:50:50 +0000 (18:50 -0600)]
osd: always call complete_split()

We need to complete the split regardless of whether the pg will get
removed after.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd: do not clean up split state on deleted pools
Sage Weil [Wed, 13 Dec 2017 00:49:38 +0000 (18:49 -0600)]
osd: do not clean up split state on deleted pools

We want the PGs to get created and then process the newer osdmap(s) to
delete themselves.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd/PG: start delete after initial delete start info is applied
Sage Weil [Wed, 13 Dec 2017 00:35:55 +0000 (18:35 -0600)]
osd/PG: start delete after initial delete start info is applied

This allows us to eliminate the flush in _delete_some().

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd/PG: wait for commit *and* readable before deleting more of PG
Sage Weil [Tue, 12 Dec 2017 22:38:14 +0000 (16:38 -0600)]
osd/PG: wait for commit *and* readable before deleting more of PG

For filestore, waiting for onreadable ensures that (1) the backend has done
(all) of the deletion work (we are throttled) and (2) that the flush() will
not block.  So, all good.

For bluestore, onreadable happens at queue time, so the flush() was needed
to throttle progress.  However, we don't want to block the op thread on
flush.  And waiting for commit isn't sufficient because that would not
capture the filestore apply work.

Fix by waiting for both commit and readable before doing more deletion
work.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd: document split tracking structures a bit
Sage Weil [Tue, 12 Dec 2017 22:22:16 +0000 (16:22 -0600)]
osd: document split tracking structures a bit

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd: drop advance_pg() split_pgs arg
Sage Weil [Tue, 12 Dec 2017 22:20:44 +0000 (16:20 -0600)]
osd: drop advance_pg() split_pgs arg

We can do the same work inside the function and simplify the code.

Signed-off-by: Sage Weil <sage@redhat.com>
7 years agoosd/PG: do not publish_stats_to_osd in state exit() methods
Sage Weil [Tue, 12 Dec 2017 19:32:52 +0000 (13:32 -0600)]
osd/PG: do not publish_stats_to_osd in state exit() methods

exit() can happen due to AdvMap and a peering interval change, but it
runs before we have updated any of our internal state about whether we
are the primary, whether our pool is deleted and the pg no longer exists,
and so on.  The publish depends on (1) being primary, and (2) will crash
if the pool is gone from the OSDMap.

Signed-off-by: Sage Weil <sage@redhat.com>