]> git.apps.os.sepia.ceph.com Git - ceph.git/log
ceph.git
4 years agodoc/cephadm: rewrite "preparation" in adoption.rst 39916/head
Zac Dover [Mon, 8 Mar 2021 16:23:51 +0000 (02:23 +1000)]
doc/cephadm: rewrite "preparation" in adoption.rst

This rewrites the "Adoption" section of
preparation.rst in the Cephadm manual.

Signed-off-by: Zac Dover <zac.dover@gmail.com>
4 years agoMerge pull request #39226 from rhcs-dashboard/host-maintenance-feature
Ernesto Puerta [Tue, 9 Mar 2021 09:09:14 +0000 (10:09 +0100)]
Merge pull request #39226 from rhcs-dashboard/host-maintenance-feature

mgr/dashboard: Host Maintenance Feature

Reviewed-by: Alfonso Martínez <almartin@redhat.com>
Reviewed-by: Avan Thakkar <athakkar@redhat.com>
Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
4 years agoMerge pull request #39909 from smithfarm/wip-revert-make-build-on-suse
Kefu Chai [Tue, 9 Mar 2021 08:58:58 +0000 (16:58 +0800)]
Merge pull request #39909 from smithfarm/wip-revert-make-build-on-suse

rpm: refrain from using %make_build macro on SUSE

Reviewed-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39936 from tchaikov/wip-workflow-use-known-sha1
Kefu Chai [Tue, 9 Mar 2021 06:09:45 +0000 (14:09 +0800)]
Merge pull request #39936 from tchaikov/wip-workflow-use-known-sha1

.github/workflows: use a released sha1

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
4 years ago.github/workflows: use a released sha1 39936/head
Kefu Chai [Tue, 9 Mar 2021 04:16:26 +0000 (12:16 +0800)]
.github/workflows: use a released sha1

otherwise the action cannot be found

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39892 from tchaikov/wip-github-workflow-milestone
Kefu Chai [Mon, 8 Mar 2021 19:42:32 +0000 (03:42 +0800)]
Merge pull request #39892 from tchaikov/wip-github-workflow-milestone

.github: correct the regex in milestone workflow

Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
4 years ago.github/workflows: rename labeler.yml to pr-triage.yml 39892/head
Kefu Chai [Mon, 8 Mar 2021 18:46:46 +0000 (02:46 +0800)]
.github/workflows: rename labeler.yml to pr-triage.yml

to reflect the change in the actions in it.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years ago.github/workflows: use @{sha1} for actions
Kefu Chai [Mon, 8 Mar 2021 18:26:34 +0000 (02:26 +0800)]
.github/workflows: use @{sha1} for actions

more secure this way. see also https://julienrenaux.fr/2019/12/20/github-actions-security-risk/

point the sha1 to

* labeler@v3
* milestone@main HEAD

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years ago.github/workflows: move milestone.yml into labeler.yml
Kefu Chai [Sun, 7 Mar 2021 11:21:25 +0000 (19:21 +0800)]
.github/workflows: move milestone.yml into labeler.yml

no need to have two actions triggered by the same event.

we could backport this labeler.yml to LTS branches.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39246 from rhcs-dashboard/fix-45415-master
Ernesto Puerta [Mon, 8 Mar 2021 16:17:49 +0000 (17:17 +0100)]
Merge pull request #39246 from rhcs-dashboard/fix-45415-master

mgr/dashboard: test prometheus rules through promtool

Reviewed-by: Avan Thakkar <athakkar@redhat.com>
Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
Reviewed-by: p-se <NOT@FOUND>
4 years agomgr/dashboard: Host Maintenance Feature 39226/head
Nizamudeen A [Tue, 2 Feb 2021 12:26:13 +0000 (17:56 +0530)]
mgr/dashboard: Host Maintenance Feature

In Cluster -> Hosts, I've added additional button to put the selected host on maintenance or exit out of the maintenance mode. Also for some hosts the ok-to-stop tests may trigger some warnings which requires a --force command to pass along with the maintenance enter command to enter a host into maintenance. In UI this is achieved using a confirmation Modal. In addition to this if the check error is It is NOT safe to stop the host then the host wont be able to put into maintenance mode.

Fixes: https://tracker.ceph.com/issues/49101
Signed-off-by: Nizamudeen A <nia@redhat.com>
4 years agoMerge pull request #38605 from mdw-at-linuxbox/wip-master-transit
Casey Bodley [Mon, 8 Mar 2021 16:00:01 +0000 (11:00 -0500)]
Merge pull request #38605 from mdw-at-linuxbox/wip-master-transit

rgw: new vault transit logic for SSE-C

Reviewed-by: Casey Bodley <cbodley@redhat.com>
4 years agoMerge pull request #37536 from xxhdx1985126/wip-crimson-interruptible-future-final
Kefu Chai [Mon, 8 Mar 2021 15:07:55 +0000 (23:07 +0800)]
Merge pull request #37536 from xxhdx1985126/wip-crimson-interruptible-future-final

crimson: add continuation chain interruption capabilities

Reviewed-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39876 from dang/wip-dang-tempest
Daniel Gryniewicz [Mon, 8 Mar 2021 13:36:09 +0000 (08:36 -0500)]
Merge pull request #39876 from dang/wip-dang-tempest

RGW - Fix TempURL user handling

4 years agoMerge pull request #39476 from rhcs-dashboard/fix-host-label
Ernesto Puerta [Mon, 8 Mar 2021 13:29:12 +0000 (14:29 +0100)]
Merge pull request #39476 from rhcs-dashboard/fix-host-label

mgr/dashboard: fix PUT - /api/host/{hostname} while adding labels

Reviewed-by: Aashish Sharma <aasharma@redhat.com>
Reviewed-by: Alfonso Martínez <almartin@redhat.com>
Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
4 years agoMerge pull request #39825 from mgfritch/cephadm-rgw-nfs-health
Sebastian Wagner [Mon, 8 Mar 2021 12:18:26 +0000 (13:18 +0100)]
Merge pull request #39825 from mgfritch/cephadm-rgw-nfs-health

mgr/cephadm: alias rgw-nfs -> nfs

Reviewed-by: Sebastian Wagner <sebastian.wagner@suse.com>
4 years agoMerge pull request #38908 from smithfarm/wip-script-agpl3
Kefu Chai [Mon, 8 Mar 2021 12:02:03 +0000 (20:02 +0800)]
Merge pull request #38908 from smithfarm/wip-script-agpl3

COPYING: add entries for backport scripts

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
4 years agoMerge pull request #39593 from mychoxin/fix_promote_dead_loop
Kefu Chai [Mon, 8 Mar 2021 11:44:04 +0000 (19:44 +0800)]
Merge pull request #39593 from mychoxin/fix_promote_dead_loop

osd: avoid two copy with same src cancel each other

Reviewed-by: Sage Weil <sage@redhat.com>
4 years agorpm: refrain from using %make_build macro on SUSE 39909/head
Nathan Cutler [Mon, 8 Mar 2021 10:14:56 +0000 (11:14 +0100)]
rpm: refrain from using %make_build macro on SUSE

The recently merged commit 0e511973f7b6b0e5dbb3c4caf98f1290f81829e9 replaced

    make %{_smp_mflags}

with

    %make_build

for the stated purpose of hiding the %_smp_mflags macro in a higher-level macro.

But, on SUSE, the higher-level macro (%make_build) expands to:

    make -O %{_smp_mflags}

The addition of the -O flag makes the build considerably slower and increases
the memory requirement. The exact reason for this is unknown - possibly it's due
to a bug in make, although the same slowness was observed with ninja as well.
In any event, this is a deal-breaker when building in the OBS, because the build
infrastructure there is optimized for builds that do not require huge amounts of
memory and we would rather have a fast build with mixed up compiler messages
than a very slow one with synced compiler messages.

Fixes: 0e511973f7b6b0e5dbb3c4caf98f1290f81829e9
Signed-off-by: Nathan Cutler <ncutler@suse.com>
4 years agoMerge pull request #39821 from dillaman/wip-qa-objectstore-logs
Kefu Chai [Mon, 8 Mar 2021 10:43:59 +0000 (18:43 +0800)]
Merge pull request #39821 from dillaman/wip-qa-objectstore-logs

qa: reduce debug log levels for bluestore

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
Reviewed-by: Neha Ojha <nojha@redhat.com>
4 years agoMerge pull request #39900 from tchaikov/wip-crimson-watch
Kefu Chai [Mon, 8 Mar 2021 08:23:20 +0000 (16:23 +0800)]
Merge pull request #39900 from tchaikov/wip-crimson-watch

crimson/osd: cleanup Notify::send_completion()

Reviewed-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
4 years agomgr/dashboard:test prometheus rules through promtool 39246/head
Aashish Sharma [Wed, 3 Feb 2021 07:23:56 +0000 (12:53 +0530)]
mgr/dashboard:test prometheus rules through promtool

This PR intends to add unit testing for prometheus rules using promtool. To run the tests run 'run-promtool-unittests.sh' file.

Fixes: https://tracker.ceph.com/issues/45415
Signed-off-by: Aashish Sharma <aasharma@redhat.com>
4 years agoMerge pull request #39729 from aclamk/wip-rocksdb-aware-bluefs-buffered-io
Kefu Chai [Sun, 7 Mar 2021 16:07:42 +0000 (00:07 +0800)]
Merge pull request #39729 from aclamk/wip-rocksdb-aware-bluefs-buffered-io

Allows RocksDB to distinguish between buffered/direct_io files

Reviewed-by: Mark Nelson <mnelson@redhat.com>
4 years agoMerge pull request #38997 from gerald-yang/patch-48946
Kefu Chai [Sun, 7 Mar 2021 15:54:06 +0000 (23:54 +0800)]
Merge pull request #38997 from gerald-yang/patch-48946

common: Fix assertion when disabling and re-enabling clog_to_monitors

Reviewed-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39775 from rishabh-d-dave/fs-qa-accept-cmds-as-str
Kefu Chai [Sun, 7 Mar 2021 15:52:54 +0000 (23:52 +0800)]
Merge pull request #39775 from rishabh-d-dave/fs-qa-accept-cmds-as-str

qa/ceph_manager: accepts commands as str too

Reviewed-by: Xiubo Li <xiubli@redhat.com>
Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
4 years agoMerge pull request #39690 from rishabh-d-dave/qa-raw_cluster_cmd
Kefu Chai [Sun, 7 Mar 2021 15:51:05 +0000 (23:51 +0800)]
Merge pull request #39690 from rishabh-d-dave/qa-raw_cluster_cmd

qa/ceph_manger: fixes bugs in CephManager

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
4 years agoMerge pull request #39712 from tchaikov/wip-prometheus-ann
Kefu Chai [Sun, 7 Mar 2021 15:50:02 +0000 (23:50 +0800)]
Merge pull request #39712 from tchaikov/wip-prometheus-ann

mgr/prometheus: add type annotations

Reviewed-by: Sebastian Wagner <swagner@suse.com>
Reviewed-by: Patrick Seidensal <pseidensal@suse.com>
4 years agoMerge pull request #39740 from tchaikov/wip-pybind-rtype
Kefu Chai [Sun, 7 Mar 2021 15:48:06 +0000 (23:48 +0800)]
Merge pull request #39740 from tchaikov/wip-pybind-rtype

pybind/{rados,cephfs}: use type annotation for rtype docstring

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
4 years agocrimson/osd: add constness to Notify 39900/head
Kefu Chai [Sun, 7 Mar 2021 13:51:53 +0000 (21:51 +0800)]
crimson/osd: add constness to Notify

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agocrimson/osd: cleanup Notify::send_completion()
Kefu Chai [Sun, 7 Mar 2021 13:32:28 +0000 (21:32 +0800)]
crimson/osd: cleanup Notify::send_completion()

Notify::send_completion() should just send the completion message. so,
move irrelevant code out of Notify::send_completion().

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agocrimson/osd: differentiate Notify with and without watchers
Kefu Chai [Sun, 7 Mar 2021 13:23:54 +0000 (21:23 +0800)]
crimson/osd: differentiate Notify with and without watchers

we don't need to arm the timer, if there is no watchers.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agocrimson/osd: factor out "maybe" from maybe_send_completion()
Kefu Chai [Sun, 7 Mar 2021 13:04:52 +0000 (21:04 +0800)]
crimson/osd: factor out "maybe" from maybe_send_completion()

for better readability

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39896 from bolapara/patch-1
Kefu Chai [Sun, 7 Mar 2021 12:23:21 +0000 (20:23 +0800)]
Merge pull request #39896 from bolapara/patch-1

docs: Ubuntu uses 'apt' not 'dnf'

Reviewed-by: Sebastian Wagner <swagner@suse.com>
Reviewed-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39895 from tchaikov/wip-crimson-watch
Kefu Chai [Sun, 7 Mar 2021 11:18:05 +0000 (19:18 +0800)]
Merge pull request #39895 from tchaikov/wip-crimson-watch

crimson/osd: watch-notify related cleanups

Reviewed-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
4 years agodoc/cephadm: use 'apt' to install cephadm on Ubuntu 39896/head
Josh [Sun, 7 Mar 2021 03:59:46 +0000 (21:59 -0600)]
doc/cephadm: use 'apt' to install cephadm on Ubuntu

Adjusted so Ubuntu command uses 'apt' and added Fedora since that uses 'dnf'.

4 years agocrimson/common: deal with seastar::thread in interruptible_future 37536/head
Xuehan Xu [Tue, 10 Nov 2020 09:14:44 +0000 (17:14 +0800)]
crimson/common: deal with seastar::thread in interruptible_future

Signed-off-by: Xuehan Xu <xxhdx1985126@gmail.com>
4 years agocrimson/test: add interruptible future unit test
Xuehan Xu [Tue, 20 Oct 2020 10:19:11 +0000 (18:19 +0800)]
crimson/test: add interruptible future unit test

Signed-off-by: Xuehan Xu <xxhdx1985126@gmail.com>
4 years agocrimson/osd: use interruptible future in the PG layer
Xuehan Xu [Sun, 4 Oct 2020 09:51:59 +0000 (17:51 +0800)]
crimson/osd: use interruptible future in the PG layer

Signed-off-by: Xuehan Xu <xxhdx1985126@gmail.com>
4 years agocrimson: add interruptible future facilities
Xuehan Xu [Sun, 4 Oct 2020 09:50:48 +0000 (17:50 +0800)]
crimson: add interruptible future facilities

Signed-off-by: Xuehan Xu <xxhdx1985126@gmail.com>
Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agocrimson/osd: no need to clear watchers beforehand 39895/head
Kefu Chai [Sun, 7 Mar 2021 02:55:35 +0000 (10:55 +0800)]
crimson/osd: no need to clear watchers beforehand

as long as we don't yield, we can assume the atomicity.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agocrimson/osd: use transparent comparator
Kefu Chai [Sun, 7 Mar 2021 02:47:20 +0000 (10:47 +0800)]
crimson/osd: use transparent comparator

for better readability

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39879 from rzarzynski/wip-crimson-notify-timeout
Kefu Chai [Sun, 7 Mar 2021 01:44:12 +0000 (09:44 +0800)]
Merge pull request #39879 from rzarzynski/wip-crimson-notify-timeout

crimson/osd: implement timeout for notify propagation.

Reviewed-by: Kefu Chai <kchai@redhat.com>
4 years ago.github: correct the regex in mileston workflow
Kefu Chai [Sat, 6 Mar 2021 16:32:42 +0000 (00:32 +0800)]
.github: correct the regex in mileston workflow

also use pull_request_target event so the action is run in the
context of the base of the pull request. this helps us to overcome
the "Resource not accessible by integration" issue where the action
is run in the context of the pull request.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agocommon: provide description for osd_default_notify_timeout. 39879/head
Radoslaw Zarzynski [Fri, 5 Mar 2021 21:43:07 +0000 (21:43 +0000)]
common: provide description for osd_default_notify_timeout.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
4 years agocrimson/osd: unify initialization in Notify.
Radoslaw Zarzynski [Fri, 5 Mar 2021 21:37:05 +0000 (21:37 +0000)]
crimson/osd: unify initialization in Notify.

Let's be consistent with the `Notify::timeout_timer`.

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
4 years agocrimson/osd: implement timeout for notify propagation.
Radoslaw Zarzynski [Fri, 5 Mar 2021 18:49:05 +0000 (18:49 +0000)]
crimson/osd: implement timeout for notify propagation.

This missed feature was the root cause of the following
failure at Sepia:

```
2021-03-04T15:40:03.013 INFO:tasks.workunit.client.0.smithi058.stdout:         api_watch_notify: [ RUN      ] LibRadosWatchNotify.WatchNotify2Timeout
2021-03-04T15:40:03.013 INFO:tasks.workunit.client.0.smithi058.stdout:         api_watch_notify: watch_notify2_test_cb from 4394 notify_id 120259084288 cookie 94023196911472
2021-03-04T15:40:03.013 INFO:tasks.workunit.client.0.smithi058.stdout:         api_watch_notify: /home/jenkins-build/build/workspace/ceph-dev-new-build/ARCH/x86_64/AVAILABLE_ARCH/x86_64/AVAILABLE_DIST/centos8/DIST/centos8/MACHINE_SIZE/gigantic/release/17.0.0-1471-g8bd81c29/rpm/el8/BUILD/ceph-17.0.0-1471-g8bd81c29/src/test/librados/watch_notify.cc:425: Failure
2021-03-04T15:40:03.014 INFO:tasks.workunit.client.0.smithi058.stdout:         api_watch_notify: Expected equality of these values:
2021-03-04T15:40:03.015 INFO:tasks.workunit.client.0.smithi058.stdout:         api_watch_notify:   -110
2021-03-04T15:40:03.015 INFO:tasks.workunit.client.0.smithi058.stdout:         api_watch_notify:   rados_notify2(ioctx, notify_oid, "notify", 6, 1000, &reply_buf, &reply_buf_len)
2021-03-04T15:40:03.015 INFO:tasks.workunit.client.0.smithi058.stdout:         api_watch_notify:     Which is: 0
2021-03-04T15:40:03.016 INFO:tasks.workunit.client.0.smithi058.stdout:         api_watch_notify: [  FAILED  ] LibRadosWatchNotify.WatchNotify2Timeout (3020 ms)
```

Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
4 years agoMerge pull request #39886 from tchaikov/wip-github-workflow-milestone
Kefu Chai [Sat, 6 Mar 2021 14:38:46 +0000 (22:38 +0800)]
Merge pull request #39886 from tchaikov/wip-github-workflow-milestone

.github: add workflow for adding milestone

Reviewed-by: Sage Weil <sage@redhat.com>
4 years ago.github: add workflow for adding milestone 39886/head
Kefu Chai [Sat, 6 Mar 2021 13:18:13 +0000 (21:18 +0800)]
.github: add workflow for adding milestone

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39846 from tchaikov/wip-cmake-find-pmem
Kefu Chai [Sat, 6 Mar 2021 09:03:39 +0000 (17:03 +0800)]
Merge pull request #39846 from tchaikov/wip-cmake-find-pmem

cmake: support COMPONENTS param in Findpmem.cmake

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
4 years agocmake: make the linkage to pmem::pmemobj public 39846/head
Kefu Chai [Sat, 6 Mar 2021 07:43:33 +0000 (15:43 +0800)]
cmake: make the linkage to pmem::pmemobj public

tools/ceph-dencoder/rbd_types.cc includes Types.h which in turn includes
libpmemobj.h via librbd/cache/pwl/Types.h. and ceph-dencoder pulls in the
rbd_type.cc's linked libraries by linking against rbd_types. but before
this change, rbd_types links against pmem::pmemobj as a PRIVATE library.

so, if we want to pull in rbd_types linkage we should always link
rbd_types as a PUBLIC library. as rbd_types include libpmemobj.h in its
header file.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agocmake: link libpmemobj against libpmem
Kefu Chai [Sat, 6 Mar 2021 04:22:39 +0000 (12:22 +0800)]
cmake: link libpmemobj against libpmem

libpmemobj should link against libpmem, but, in CMake, imported library
does not allow PRIVATE linkage. so pmem::pmem is added to the list of
INTERFACE_LINK_LIBRARIES.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agocmake: support COMPONENTS param in Findpmem.cmake
Kefu Chai [Fri, 5 Mar 2021 06:04:23 +0000 (14:04 +0800)]
cmake: support COMPONENTS param in Findpmem.cmake

add two components: pmem and pmemobj to this package. so we can find
them and link against them in a more intuitive way.

before this change the COMPONENTS parameter passed to

find_package(pmem ...)

is dropped on the floor and ignored.

after this change, it is checked and taken into consideration.

also, in this change, the exposed variables are renamed from

PMEM_* to pmem_*

to be consistent with the package name. it's encouraged to be consistent
with the package name when it comes to the INCLUDE_DIR and LIBRARIES
variable names.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agorgw/kms/vault - PendingReleaseNotes pointer 38605/head
Marcus Watts [Tue, 2 Mar 2021 04:10:35 +0000 (23:10 -0500)]
rgw/kms/vault - PendingReleaseNotes pointer

The "new" transit logic requires configure changes to be
effective.  Here is a pointer to the revised
documentation for those who already have data encrypted
using the previous version.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - s3tests for both old and new test logic.
Marcus Watts [Tue, 26 Jan 2021 01:49:16 +0000 (20:49 -0500)]
rgw/kms/vault - s3tests for both old and new test logic.

Test both "old" and "new" transit logic with s3tests.  Does not test
migration - that will need to be done separately.  I've added
a "flavor" parameter so the test logic can tell the difference
between the "old" engine and the "new" engine.  The vault
keys creation logic now has options to determine whether
the keys created are exportable (needed for the old transit
engine), or not (should be the case going forward with the
new transit engine.)

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - rework unit test logic for new transit logic.
Marcus Watts [Fri, 8 Jan 2021 22:49:20 +0000 (17:49 -0500)]
rgw/kms/vault - rework unit test logic for new transit logic.

The "new" transit logic is organized quite differently
than the old logic, so the existing unit test logic was
very broken.  Additionally, it's possible to test the
input arguments and send_request() has more of them now,
so add logic to verify most of those arguments are correct.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - 0 terminate before rapidjson
Marcus Watts [Fri, 8 Jan 2021 22:43:58 +0000 (17:43 -0500)]
rgw/kms/vault - 0 terminate before rapidjson

bufferlist c_str() doesn't guarantee a trailing nul, which is req'd
by rapidjson.  So, append a nul to make that guarantee explicit.

Also, add an optional "virtual" so unit test logic can override
send_request().

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - document configuration for new transit logic
Marcus Watts [Tue, 5 Jan 2021 02:22:07 +0000 (21:22 -0500)]
rgw/kms/vault - document configuration for new transit logic

Using the new transit logic requires slightly different configuration.
additionally there is some backwards compatibility support, which
also needed documentation.

The existing description of how to configure hashicorp vault
to work with ceph was also incomplete.  I've fleshed that out a bit,
including considerably more information on how to use configure
and use the vault secret agent with ceph.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - new transit logic - fix compat logic
Marcus Watts [Tue, 5 Jan 2021 02:21:33 +0000 (21:21 -0500)]
rgw/kms/vault - new transit logic - fix compat logic

Teuthology passes in a vault uri that ends in /export/encryption-key/
So: we need to handle (and ignore) trailing slashes when deciding
to enable compatibility support.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - define attribute for new transit logic
Marcus Watts [Sat, 12 Dec 2020 19:09:44 +0000 (14:09 -0500)]
rgw/kms/vault - define attribute for new transit logic

For the new transit logic; I need to store a wrapped key
per object.  This names that attribute on the rados object.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - "compat" option
Marcus Watts [Tue, 8 Dec 2020 23:09:04 +0000 (18:09 -0500)]
rgw/kms/vault - "compat" option

For transit engine:
"compat" option: 0=new only, 1=old & new, 2=old only.
This is just the option parsing itself: not the actual logic
for make_key | reconstitute_key.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - encryption context - first part
Marcus Watts [Mon, 7 Dec 2020 22:55:22 +0000 (17:55 -0500)]
rgw/kms/vault - encryption context - first part

This includes the logic to process the user provided
encryption context, turn it into "canonical json", and
to add in a default arn if it's not present.

Also present here is the start of logic to distinguish
between "prepare_encrypt" and "prepare_decrypt" at a lower
level; as "make_key" and "reconstitute_key" these will be
the functions that separately create a new datakey using
the vault transit operation, and to retrieve a previously
stored datakey.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agocmake: do not link blk against pmem::pmemobj
Kefu Chai [Fri, 5 Mar 2021 13:15:59 +0000 (21:15 +0800)]
cmake: do not link blk against pmem::pmemobj

as blk does not use pmem::pmemobj, librbd does.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agoMerge pull request #39719 from zdover23/wip-doc-dev-t8y-interactive-on-error-rewrite...
Neha Ojha [Sat, 6 Mar 2021 01:32:42 +0000 (17:32 -0800)]
Merge pull request #39719 from zdover23/wip-doc-dev-t8y-interactive-on-error-rewrite-2021-Feb-26

doc/dev: t8y interactive-on-error rewrite

Reviewed-by: Neha Ojha <nojha@redhat.com>
4 years agorgw/kms/vault - define attribute to store encryption context
Marcus Watts [Mon, 7 Dec 2020 22:53:05 +0000 (17:53 -0500)]
rgw/kms/vault - define attribute to store encryption context

For rgw sse:kms use, the aws s3 standard provides an attribute
to store the base-64 encoded canonical json "encryption context".
This should be used to vary the per-object keys used for the
actual object encryption.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - share get/set attr between rgw_crypt.cc and rgw_kms.cc
Marcus Watts [Mon, 7 Dec 2020 22:48:31 +0000 (17:48 -0500)]
rgw/kms/vault - share get/set attr between rgw_crypt.cc and rgw_kms.cc

In order to pass down and manage "attrs" from crypt logic to kms
logic, it's necessary to share the functions that can get and
set strings in that structure.  Eventually, I plan to have
the various engines store and retrieve a per-object "datakey" that
is encrypted (wrapped) by the named kms key.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agoMerge PR #38819 into master
Patrick Donnelly [Fri, 5 Mar 2021 22:28:25 +0000 (14:28 -0800)]
Merge PR #38819 into master

* refs/pull/38819/head:
win32*.sh: use ninja instead of make
doc: add ceph-dokan documentation
cephfs: Add ceph-dokan, providing Windows support
cephfs: add ceph_may_delete function
cephfs: disable inode emulation on Windows

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
4 years agorgw/kms/vault - relax configuration parsing for rgw_crypt_vault_secret_engine
Marcus Watts [Mon, 7 Dec 2020 22:28:59 +0000 (17:28 -0500)]
rgw/kms/vault - relax configuration parsing for rgw_crypt_vault_secret_engine

To better manage forwards and backwards compatibility when using vault
transit for rgw object encryption (sse:kms); it is desirable to provide
parameters to control how this works.  It was more attractive to overload
the existing rgw_crypt_vault_secret_engine parameter for this purpose
than to invent one or more all-new parameters.

Additionally, the enum support in the configuration parser looks like
it ought to have helpful syntax checking functionality.  This is not so;
failure to provide a supported enum results in silently replacing that
with the default option, resulting in confusing and non-obvious behavior
that is not at all helpful.

This change removes the enum constraint on rgw_crypt_vault_secret_engine,
allowing for more useful messages from the rgw code, and the possibility
to also provide additional information on the same line.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agorgw/kms/vault - need libicu to make canonical json for encryption contexts.
Marcus Watts [Mon, 7 Dec 2020 22:20:49 +0000 (17:20 -0500)]
rgw/kms/vault - need libicu to make canonical json for encryption contexts.

for encryption, aws s3 provides an "encryption" context to vary per-object
keys.  The encryption context is a base64 encoded json structure, which
must be converted to a determinstic form -- "canonical json".  This
requires converting all strings to a normalized canonical form: "utf-8 nfc",
it also requires thta keys in objects be sorted in a fixed order; so some
form of sorting based on nfc.

It turns out that libicu was the best way to produce utf-8 nfc (boost also
provides a mechanism, but it has many quirks).  So, here are the hooks
to pull the system libicu into the build.

Fixes: http://tracker.ceph.com/issues/48746
Signed-off-by: Marcus Watts <mwatts@redhat.com>
4 years agoMerge PR #39874 into master
Patrick Donnelly [Fri, 5 Mar 2021 22:06:48 +0000 (14:06 -0800)]
Merge PR #39874 into master

* refs/pull/39874/head:
qa/crontab: simplify pacific cronjob def

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
Reviewed-by: Yuri Weinstein <yweins@redhat.com>
4 years agoMerge PR #39873 into master
Patrick Donnelly [Fri, 5 Mar 2021 22:05:09 +0000 (14:05 -0800)]
Merge PR #39873 into master

* refs/pull/39873/head:
qa/crontab: set teuthology envvars in crontab

Reviewed-by: Yuri Weinstein <yweins@redhat.com>
Reviewed-by: Josh Durgin <jdurgin@redhat.com>
4 years agoMerge pull request #33996 from mdw-at-linuxbox/wip-master-kmip
Matt Benjamin [Fri, 5 Mar 2021 21:20:18 +0000 (16:20 -0500)]
Merge pull request #33996 from mdw-at-linuxbox/wip-master-kmip

rgw / kmip kms

4 years agoMerge PR #39817 into master
Sage Weil [Fri, 5 Mar 2021 20:33:50 +0000 (15:33 -0500)]
Merge PR #39817 into master

* refs/pull/39817/head:
qa/suites/rados/cephadm: drop centos/rhel cephadm tests for the moment
qa/sites/rados/cephadm/thrash: rename 3-tasks.yaml/ -> 3-tasks/
qa/suites/rados/cephadm: adjust distros
qa/suites/upgrade: use kubic; test all distros
qa/suites/rados/cephadm/upgrade: use kubic on centos
qa: new kubic distro files; use kubic podman for centos/rhel

Reviewed-by: Sebastian Wagner <swagner@suse.com>
4 years agoMerge PR #39855 into master
Sage Weil [Fri, 5 Mar 2021 20:33:38 +0000 (15:33 -0500)]
Merge PR #39855 into master

* refs/pull/39855/head:
qa/suites/rgw/singleton: add trivial cephadm case
Revert "rgw: register daemon in service map with more details"

Reviewed-by: Sebastian Wagner <swagner@suse.com>
4 years agoRGW - Fix TempURL user handling 39876/head
Daniel Gryniewicz [Thu, 4 Mar 2021 16:18:54 +0000 (11:18 -0500)]
RGW - Fix TempURL user handling

Zipper brok user handling for TempURL, missing the fallback to
untenentaed UID.

Signed-off-by: Daniel Gryniewicz <dang@redhat.com>
4 years agoMerge pull request #39861 from tchaikov/wip-doc-theme
Josh Durgin [Fri, 5 Mar 2021 19:42:30 +0000 (11:42 -0800)]
Merge pull request #39861 from tchaikov/wip-doc-theme

doc/_theme: remove the spacing at top of "dl dt"

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
4 years agoMerge PR #39841 into master
Patrick Donnelly [Fri, 5 Mar 2021 19:34:14 +0000 (11:34 -0800)]
Merge PR #39841 into master

* refs/pull/39841/head:
qa: ignorelist slow ops during scrub

Reviewed-by: Rishabh Dave <ridave@redhat.com>
4 years agoMerge PR #38859 into master
Patrick Donnelly [Fri, 5 Mar 2021 19:33:08 +0000 (11:33 -0800)]
Merge PR #38859 into master

* refs/pull/38859/head:
mds: don't start purging inodes in the middle of recovery
mds: purge orphan objects created by lost async file creation
mds: track free prealloc_inos and delegated_inos separately
mds: cleanup code that purges orphan objects created by lost unsafe file creation
mds: subtract inos_to_purge from prealloc_inos when session close is logged
mds: use vector to define old_pools in PurgeItem and inode_backtrace_t

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
4 years agoqa/crontab: simplify pacific cronjob def 39874/head
Patrick Donnelly [Fri, 5 Mar 2021 18:18:50 +0000 (10:18 -0800)]
qa/crontab: simplify pacific cronjob def

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
4 years agoqa/crontab: set teuthology envvars in crontab 39873/head
Patrick Donnelly [Fri, 5 Mar 2021 17:01:44 +0000 (09:01 -0800)]
qa/crontab: set teuthology envvars in crontab

These are magically set somewhere in teuthology's startup rc files.
Instead, define them here.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
4 years agoMerge pull request #39838 from sebastian-philipp/doc-rm-cephadm-install
zdover23 [Fri, 5 Mar 2021 17:38:37 +0000 (03:38 +1000)]
Merge pull request #39838 from sebastian-philipp/doc-rm-cephadm-install

doc/install/index_manual: remove cephadm from toctree

Reviewed-by: Zac Dover <zac.dover@gmail.com>
4 years agodoc/_theme: remove the spacing at top of "dl dt" 39861/head
Kefu Chai [Fri, 5 Mar 2021 16:13:05 +0000 (00:13 +0800)]
doc/_theme: remove the spacing at top of "dl dt"

otherwise there is a margin-top on top of dt.

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agoqa/suites/rgw/singleton: add trivial cephadm case 39855/head
Sage Weil [Fri, 5 Mar 2021 14:47:19 +0000 (09:47 -0500)]
qa/suites/rgw/singleton: add trivial cephadm case

Make sure we can deploy an rgw and not generate any warnings.

Signed-off-by: Sage Weil <sage@newdream.net>
4 years agoRevert "rgw: register daemon in service map with more details"
Sage Weil [Fri, 5 Mar 2021 14:40:59 +0000 (09:40 -0500)]
Revert "rgw: register daemon in service map with more details"

This reverts commit 46ec2f0ddd81b4b5b4a61633eada998dcd606c9b.

This broke cephadm (by triggering CEPHADM_STRAY_DAEMON) because cephadm
assumes that a daemon named rgw.r.z.foo will register as rgw.r.z.foo.

It is not clear to me that there is a way to work around this naming
mismatch that makes much sense.  I think it makes more sense to focus on
the use-case that needs daemons to register under unique names and perhaps
control that naming behavior via an option or invest in providing daemons
with unique ids up front.

Signed-off-by: Sage Weil <sage@newdream.net>
4 years agoMerge pull request #39813 from smithfarm/wip-49583
Nathan Cutler [Fri, 5 Mar 2021 13:28:08 +0000 (14:28 +0100)]
Merge pull request #39813 from smithfarm/wip-49583

rpm: disable parallel compression on SUSE

Reviewed-by: Kefu Chai <kchai@redhat.com>
4 years agowin32*.sh: use ninja instead of make 38819/head
Lucian Petrut [Wed, 3 Feb 2021 13:45:14 +0000 (13:45 +0000)]
win32*.sh: use ninja instead of make

In order to avoid overcomplicating the ceph cmake files, we're
picking make targets individually.

This is quite inefficient. Ninja can improve the build concurrency,
reducing the build duration by almost 50%.

Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
4 years agodoc: add ceph-dokan documentation
Lucian Petrut [Fri, 5 Mar 2021 13:14:29 +0000 (13:14 +0000)]
doc: add ceph-dokan documentation

This change documents ceph-dokan, describing the prerequisites,
usage and limitations.

Some of this was mentioned in README.windows.rst but is now being
moved to the Ceph doc pages.

Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
4 years agocephfs: Add ceph-dokan, providing Windows support
Lucian Petrut [Fri, 7 Aug 2020 12:07:20 +0000 (12:07 +0000)]
cephfs: Add ceph-dokan, providing Windows support

In order to expose ceph filesystems to Windows hosts, we propose
including ceph-dokan[1][2] in the Ceph tree, while updating it to
work with the latest CephFS and Dokany APIs.

Dokany is a well maintained project (fork of the original Dokan
project), allowing filesystems to be implemented in userspace,
even providing a Fuse compatibility layer.

One reason for not using the FUSE compatibility layer is that it's
only covering the high level API while Ceph is using the low level
FUSE API, which among other things is inode centric.

Changes made by this patch compared to the upstream ceph-dokan:

* support latest stable Dokany API. The upstream version relies on
  the legacy unmaintained Dokan API
* return proper error codes, converting standard errno.h values to
  NTSTATUS
* minor changes to support latest cephfs API
* drop duplicated ceph code, no longer needed if we're to include it
  in tree. This makes it much easier to maintain.
* drop redundant permission checks, leaving it up to libcephfs
* use ceph argparse helpers
* use ceph logging and daemon initialization
* fixed unicode handling
* switched to ceph coding style
* made ceph.conf param optional, using the default path if available
* enabled setting file timestamps
* append support
* configurable timeouts set once per mount
* ensure that the error code is always logged
* various cleanups (removed unused entry points, checks that have
  been moved to dokany, simplified conditional statements,
  unnecessary conversions in the hot path, etc).

[1] https://github.com/ketor/ceph-dokan
[2] https://github.com/ceph/ceph-dokan

Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
4 years agoMerge pull request #39809 from sebastian-philipp/cephadm-compatibilty
Sebastian Wagner [Fri, 5 Mar 2021 11:20:33 +0000 (12:20 +0100)]
Merge pull request #39809 from sebastian-philipp/cephadm-compatibilty

doc/cephadm: remove warning about cephadm in production

Reviewed-by: Sage Weil <sage@redhat.com>
4 years agoMerge pull request #39639 from sebastian-philipp/cephadm-deploy-daemon-units-for...
Sebastian Wagner [Fri, 5 Mar 2021 09:43:39 +0000 (10:43 +0100)]
Merge pull request #39639 from sebastian-philipp/cephadm-deploy-daemon-units-for-existing-osds

mgr/cephadm: Activate existing OSDs

Reviewed-by: Michael Fritch <mfritch@suse.com>
4 years agocephfs: add ceph_may_delete function
Lucian Petrut [Fri, 26 Feb 2021 08:32:38 +0000 (08:32 +0000)]
cephfs: add ceph_may_delete function

We're adding a new libcephfs function: ceph_may_delete. It checks
if the mount permissions allow deleting a file or directory, without
actually deleting it.

This will allow us to drop the redundant permission checks at
ceph-dokan level, saving about 1500 LOC.

Note that the "DeleteFile" Dokan callback expects us to say if a
delete operation is allowed. The "Cleanup" callback is supposed
to perform the actual file or directory deletion.

Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
4 years agocephfs: disable inode emulation on Windows
Lucian Petrut [Mon, 22 Feb 2021 11:24:56 +0000 (11:24 +0000)]
cephfs: disable inode emulation on Windows

cephfs will use fake inodes when sizeof(ino_t) < 8. On Windows,
ino_t is defined as unsigned short (2B), which isn't enough.

On the other hand, most "native" Windows structures, including the
Dokan ones, are using 64b identifiers.

That being considered, we'll disable inode emulation on Windows.

Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
4 years agodoc/dev: t8y interactive-on-error rewrite 39719/head
Zac Dover [Fri, 26 Feb 2021 13:47:01 +0000 (23:47 +1000)]
doc/dev: t8y interactive-on-error rewrite

This PR rewrites the section of the Teuthology
documentation that is about the --interactive-
on-error flag.

Signed-off-by: Zac Dover <zac.dover@gmail.com>
4 years agoMerge pull request #39824 from batrick/nightly-partitions
Josh Durgin [Fri, 5 Mar 2021 02:15:56 +0000 (18:15 -0800)]
Merge pull request #39824 from batrick/nightly-partitions

qa: allow specifying partition size for nightlies

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
Reviewed-by: Josh Durgin <jdurgin@redhat.com>
Reviewed-by: Yuri Weinstein <yweins@redhat.com>
4 years agoMerge pull request #39457 from tchaikov/wip-sphinx-rtd-theme
Kefu Chai [Fri, 5 Mar 2021 02:08:12 +0000 (10:08 +0800)]
Merge pull request #39457 from tchaikov/wip-sphinx-rtd-theme

doc: switch to sphinx_rtd_theme theme

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
4 years agoMerge pull request #39842 from liewegas/smoke-timeout
Neha Ojha [Fri, 5 Mar 2021 02:05:35 +0000 (18:05 -0800)]
Merge pull request #39842 from liewegas/smoke-timeout

src/test/smoke.sh: increase timeout

Reviewed-by: Neha Ojha <nojha@redhat.com>
4 years agoMerge pull request #39840 from rzarzynski/wip-crimson-notify_reply_t
Kefu Chai [Fri, 5 Mar 2021 02:05:13 +0000 (10:05 +0800)]
Merge pull request #39840 from rzarzynski/wip-crimson-notify_reply_t

crimson/osd: fix the serialization of notify_reply_t.

Reviewed-by: Kefu Chai <kchai@redhat.com>
4 years agodoc/_theme: customize sphinx_rtd_theme 39457/head
Kefu Chai [Sat, 13 Feb 2021 04:57:19 +0000 (12:57 +0800)]
doc/_theme: customize sphinx_rtd_theme

* move the breadcrumbs to the top
* add border around admonition elements
* use different colors and fonts for section headers
* add decoration lines at the bottom of breadcrumbs
* remove left and right borders in tables
* override the injected versions, the name of theme
  is different from "sphinx_rtd_theme", but the
  versions element is still displayed at the
  bottom-left corner as "versions.html" defines.
  without overriding .rst-badge CSS styling,
  readthedocs puts the injected versions at
  the default bottom-right corner, see
  https://github.com/readthedocs/readthedocs.org/blob/2a519f1146142d18f6a63b61c2f08984067280e0/readthedocs/api/v2/templates/restapi/footer.html

Signed-off-by: Kefu Chai <kchai@redhat.com>
4 years agoqa/suites/rados/cephadm: drop centos/rhel cephadm tests for the moment 39817/head
Sage Weil [Thu, 4 Mar 2021 18:33:12 +0000 (12:33 -0600)]
qa/suites/rados/cephadm: drop centos/rhel cephadm tests for the moment

...until we sort out the podman problems!  :( :(

Signed-off-by: Sage Weil <sage@newdream.net>
4 years agoqa/sites/rados/cephadm/thrash: rename 3-tasks.yaml/ -> 3-tasks/
Sage Weil [Thu, 4 Mar 2021 18:32:27 +0000 (12:32 -0600)]
qa/sites/rados/cephadm/thrash: rename 3-tasks.yaml/ -> 3-tasks/

Signed-off-by: Sage Weil <sage@newdream.net>
4 years agoqa/suites/rados/cephadm: adjust distros
Sage Weil [Thu, 4 Mar 2021 18:32:00 +0000 (12:32 -0600)]
qa/suites/rados/cephadm: adjust distros

Signed-off-by: Sage Weil <sage@newdream.net>