Commit Graph

103683 Commits

Author SHA1 Message Date
Sage Weil
f5c7a8c986 qa/standalone/test_ceph_daemon: fix multi-version python test
We have to rewrite the shebang line, since it is no longer just
'#/usr/bin/env python' (as of e12ad1b016).

Signed-off-by: Sage Weil <sage@redhat.com>
2019-11-03 10:09:06 -06:00
Sage Weil
728d50f674 Merge PR #31314 into master
* refs/pull/31314/head:
	mgr/orchestrator_cli: pass default value to "req=False" params

Reviewed-by: Sage Weil <sage@redhat.com>
2019-11-01 08:57:33 -05:00
Sage Weil
196eda988e Merge PR #31315 into master
* refs/pull/31315/head:
	ceph-daemon: create ~/.ssh if not exist

Reviewed-by: Sage Weil <sage@redhat.com>
2019-11-01 08:56:36 -05:00
Kefu Chai
3d12fc16c6 ceph-daemon: create ~/.ssh if not exist
there is chance that /root/.ssh does not exist yet, when we are trying
to add key to authorized_keys.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 21:33:25 +08:00
Kefu Chai
6af2340d5d
Merge pull request #31045 from tchaikov/wip/librados/no-more-ack-commit
librados,test,rgw: cleanups to deprecate safe_cb related functions

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Casey Bodley <cbodley@redhat.com>
Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2019-11-01 20:06:20 +08:00
Jason Dillaman
4abf21c81e
Merge pull request #31311 from tchaikov/wip/rbd/cleanup
librbd: always initialize local variables

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2019-11-01 07:47:26 -04:00
Mykola Golub
1dc0db74d4
Merge pull request #30912 from dillaman/wip-42265
mgr: add 'rbd' profiles to support 'rbd_support' module commands

Reviewed-by: Mykola Golub <mgolub@suse.com>
Reviewed-by: Sage Weil <sage@redhat.com>
2019-11-01 13:41:28 +02:00
Kefu Chai
60c7ebe628
Merge pull request #31244 from changchengx/deploy_doc
doc: update with osd addition

Reviewed-by: Alfredo Deza <adeza@redhat.com>
Reviewed-by: Kefu Chai <kchai@redhat.com>
2019-11-01 18:15:15 +08:00
Kefu Chai
7c2ec07a0c
Merge pull request #31196 from liewegas/wip-osdmon-iec
mon/OSDMonitor: expand iec_options for 'osd pool set'

Reviewed-by: Kefu Chai <kchai@redhat.com>
2019-11-01 18:00:38 +08:00
Kefu Chai
3aabe9e4d6 rgw: use new aio_create_completion()
Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:21 +08:00
Kefu Chai
32f37574cc journal: use new aio_create_completion()
Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:21 +08:00
Kefu Chai
c25b5a0d64 test/librados_test_stub: implement aio_create_completion2() and friends
Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:21 +08:00
Kefu Chai
9e1d1deeaf librbd: use new aio_create_completion()
to silence warnings like:

src/librbd/Utils.h:139:48: warning: 'static librados::v14_2_0::AioCompletion* librados::v14_2_0::Rados::aio_create_completion(void*, librados::callback_t, librados::callback_t)' is deprecated
[-Wdeprecated-declarations]
   return librados::Rados::aio_create_completion(
          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
     obj, &detail::rados_callback<T, MF>, nullptr);
     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:21 +08:00
Kefu Chai
d2b0d699c3 test/libradosstriper: use new aio_create_completion()
to silence -Wdeprecated-declarations warnings

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:21 +08:00
Kefu Chai
5b78e33bc5 cls/journal: s/create_completion/create_completion2/
src/cls/journal/cls_journal_client.cc:154:72: warning: 'static librados::v14_2_0::AioCompletion* librados::v14_2_0::Rados::aio_create_completion(void*, librados::callback_t, librados::callback_t)' is
deprecated [-Wdeprecated-declarations]
       librados::Rados::aio_create_completion(this, rados_callback, NULL);
                                                                        ^

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:21 +08:00
Kefu Chai
5bbd31041c rgw: s/create_completion/create_completion2/
to silence the warnings like

s_user_client.cc:151:77: warning: 'static librados::v14_2_0::AioCompletion* librados::v14_2_0::Rados::aio_create_completion(void*, librados::callback_t, librados::callback_t)' is deprecated
[-Wdeprecated-declarations]
   AioCompletion *c = librados::Rados::aio_create_completion(NULL, NULL, NULL);
                                                                             ^

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:21 +08:00
Kefu Chai
cc2dedab08 librados: s/aio_create_completion/aio_create_completion2/
the former is deprecated

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:20 +08:00
Kefu Chai
cd59a348af libradosstriper: s/create_completion/create_completion2/
replace `librados::Rados::aio_create_completion(arg, complete_cb,
safe_cb)` with `librados::Rados::aio_create_completion(arg,
complete_cb)`

the former is deprecated

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:20 +08:00
Kefu Chai
02d0334ad3 tools: s/rados_aio_create_completion/rados_aio_create_completion2/
Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:20 +08:00
Kefu Chai
f18903a66c test: s/rados_aio_create_completion/rados_aio_create_completion2/
the former is deprecated and replaced with the latter

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:20 +08:00
Kefu Chai
00428e279f test: s/wait_for_safe/wait_for_complete/
Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:20 +08:00
Kefu Chai
3f5afc9386 rgw: s/wait_for_safe/wait_for_complete/
Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:20 +08:00
Kefu Chai
20bb201ebd librados: s/wait_for_safe/wait_for_complete/
Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:20 +08:00
Kefu Chai
fede81d363 test/ceph_kvstorebench: s/wait_for_safe/wait_for_complete/
Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:20 +08:00
Kefu Chai
d6514df945 tools/rados: s/wait_for_safe/wait_for_complete/
wait_for_safe() and friend are deprecated, so use wait_for_complete()
instead.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:27:20 +08:00
Kefu Chai
15a3eeb4e5 mgr/orchestrator_cli: pass default value to "req=False" params
in mds_add() command, both "num" and "hosts" are optional, so they
should have default values of "None". this change was introduced in
c35db383.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 17:23:58 +08:00
Changcheng Liu
3a691911fc doc: update with osd addition
Signed-off-by: Changcheng Liu <changcheng.liu@aliyun.com>
2019-11-01 13:55:41 +08:00
Kefu Chai
95aa2e5ab7 librbd: always initialize local variables
silence warnings like:

src/librbd/io/ImageRequestWQ.cc:576:7: warning: 'length' may be used uninitialized in this function [-Wmaybe-uninitialized]
       if (block_overlapping_io(&m_in_flight_extents, offset, length)) {
       ^~
...
src/librbd/io/ImageRequestWQ.cc:935:12: note: 'length' was declared here
   uint64_t length;
            ^~~~~~

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 13:34:23 +08:00
Sage Weil
ae17f3678d Merge PR #31225 into master
* refs/pull/31225/head:
	mgr/telemetry: send device telemetry via per-host POST to device endpoint

Reviewed-by: Dan Mick <dmick@redhat.com>
2019-10-31 21:49:46 -05:00
Kefu Chai
739427fd44 pybind/rados: do not use wait_for_safe() anymore
in librados, wait_for_safe() is an alias of wait_for_complete(). so in
this change, wait_for_safe() calls wait_for_complete(), and the callers
of wait_for_safe() will just call wait_for_complete(), instead of
calling both of them.

also, rados_aio_create_completion() is replaced with
rados_aio_create_completion2().

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 09:40:44 +08:00
Kefu Chai
aaab90fb07 librados: add Rados::aio_create_completion(arg, cb)
which does not take safe_cb, and will take the place of
Rados::aio_create_completion(arg, cb_complete, cb_safe)

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 09:40:44 +08:00
Kefu Chai
c2d6788aaa librados: add rados_aio_create_completion2()
rados_aio_create_completion2() is almost identical to
rados_aio_create_completion(). the only difference is that the former
does not accept the `safe` callback. as it's an alias of `complete`
callback since af01db76f6

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 09:40:44 +08:00
Kefu Chai
46fa68eb10 librados: mark wait_for_safe() functions deprecated
safe is an alias of completed since
af01db76f6. there is no need to have
two callbacks for tracking the state of an async operation anymore.

in this change, wait_for_safe() and friends are marked "deprecated"

Signed-off-by: Kefu Chai <kchai@redhat.com>
2019-11-01 09:40:44 +08:00
Patrick Donnelly
a3352d7e9a
Merge PR #31046 into master
* refs/pull/31046/head:
	doc: hide page contents for Ceph Internals

Reviewed-by: Neha Ojha <nojha@redhat.com>
Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@gmail.com>
2019-10-31 16:42:18 -07:00
Patrick Donnelly
ced05b9eb3
Merge PR #31206 into master
* refs/pull/31206/head:
	qa: test fs:upgrade when running upgrade suite

Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Josh Durgin <jdurgin@redhat.com>
2019-10-31 13:08:34 -07:00
Sage Weil
46867fd67b Merge PR #31270 into master
* refs/pull/31270/head:
	ceph-daemon: no extra newline needed in authorized_keys file
	ceph-daemon: use client.admin keyring during bootstrap

Reviewed-by: Alfredo Deza <adeza@redhat.com>
2019-10-31 10:40:59 -05:00
Ilya Dryomov
f41de0bec1
Merge pull request #31265 from idryomov/wip-krbd-unmap-msgr1
qa/suites/krbd: run unmap subsuite with msgr1 only

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2019-10-31 15:45:19 +01:00
Volker Theile
b315f2eeea
mgr/dashboard: Remove convertion to seconds (#31262)
mgr/dashboard: Remove convertion to seconds

Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
Reviewed-by: Ni-Feng Chang <kiefer.chang@suse.com>
Reviewed-by: Volker Theile <vtheile@suse.com>
2019-10-31 12:07:31 +01:00
Volker Theile
0562fc9a4b
mgr/dashboard: edit/clone/copy rbd image after its data is rec… (#31245)
mgr/dashboard: edit/clone/copy rbd image after its data is received

Reviewed-by: Laura Paduano <lpaduano@suse.com>
Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
Reviewed-by: Volker Theile <vtheile@suse.com>
2019-10-31 12:05:06 +01:00
Nathan Cutler
14cdd8e95f
Merge pull request #31247 from smithfarm/wip-bri-regression
backport-resolve-issue: "recognize that Target version is populated" and "prune duplicate URLs"

Reviewed-by: Abhishek Lekshmanan <abhishek@suse.com>
2019-10-31 12:02:58 +01:00
Patrick Donnelly
35b0b52153
Merge PR #31231 into master
* refs/pull/31231/head:
	qa: add tests for CephFS admin commands
	mds/MDSRank: report state to mgr as mds id, not rank

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
2019-10-30 12:22:48 -07:00
Sage Weil
57c6e51755 ceph-daemon: no extra newline needed in authorized_keys file
Signed-off-by: Sage Weil <sage@redhat.com>
2019-10-30 14:09:36 -05:00
Sage Weil
df40a49eb8 ceph-daemon: use client.admin keyring during bootstrap
It's usually okay to use the mon. key for CLI commands, except we had a
mgr but that prevented you from issuing mgr commands correctly.  We have
the new client.admin key available, so use that instead.

Update tests to not --skip-ssh (now that it doesn't hang).

Signed-off-by: Sage Weil <sage@redhat.com>
2019-10-30 14:07:52 -05:00
Sage Weil
d2c66f3879 Merge PR #31264 into master
* refs/pull/31264/head:
	ceph-daemon: deal with lack of TemporaryDirectory on py2
	ceph-daemon: make StringIO usage py2 compatible
	ceph-daemon: make ConfigParser py2 compatible

Reviewed-by: Alfredo Deza <adeza@redhat.com>
2019-10-30 14:04:07 -05:00
Ilya Dryomov
5011cc926c qa/suites/krbd: run unmap subsuite with msgr1 only
pre-single-major.yaml kernel doesn't have any of the monitor client
fixes that came in 4.6.  If the connection is closed, it closes the
session and retries only after 10 seconds.  On top of that, there is
nothing to prevent it from picking the same monitor when reconnecting.
This means that when given both v1 and v2 ports (which look like two
different monitors), it is susceptible to mount_timeout (60 seconds):

  $ sudo rbd map img
  rbd: sysfs write failed
  In some cases useful info is found in syslog - try "dmesg | tail".
  rbd: map failed: (5) Input/output error

  [  822.242313] libceph: mon0 172.21.15.132:3300 socket closed (con state CONNECTING)
  [  832.265494] libceph: mon0 172.21.15.132:3300 socket closed (con state CONNECTING)
  [  842.296175] libceph: mon0 172.21.15.132:3300 socket closed (con state CONNECTING)
  [  852.326924] libceph: mon0 172.21.15.132:3300 socket closed (con state CONNECTING)
  [  862.357611] libceph: mon0 172.21.15.132:3300 socket closed (con state CONNECTING)
  [  872.388373] libceph: mon0 172.21.15.132:3300 socket closed (con state CONNECTING)
  [  882.676136] libceph: mon0 172.21.15.132:3300 socket closed (con state CONNECTING)

Unlike newer kernels that return ETIMEDOUT, it returns EIO.

Newer kernels are much more aggressive about retries and will pick
a different monitor when reconnecting, hence they are always able to
establish the session in time.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
2019-10-30 19:51:55 +01:00
Patrick Donnelly
9dc07d8096
qa: add tests for CephFS admin commands
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2019-10-30 11:44:26 -07:00
Sage Weil
9c9bb19d43 ceph-daemon: deal with lack of TemporaryDirectory on py2
Signed-off-by: Sage Weil <sage@redhat.com>
2019-10-30 13:29:49 -05:00
Sage Weil
749a0bdb61 ceph-daemon: make StringIO usage py2 compatible
Otherwise,

Traceback (most recent call last):
  File "../src/ceph-daemon", line 1698, in <module>
    r = args.func()
  File "../src/ceph-daemon", line 767, in command_bootstrap
    with StringIO() as f:
AttributeError: StringIO instance has no attribute '__exit__'

Signed-off-by: Sage Weil <sage@redhat.com>
2019-10-30 13:29:49 -05:00
Sage Weil
93570a501b ceph-daemon: make ConfigParser py2 compatible
Signed-off-by: Sage Weil <sage@redhat.com>
2019-10-30 13:29:49 -05:00
Tiago Melo
a7daa902a6 mgr/dashboard: Remove convertion to seconds
This is no longer need since the values are already in seconds.

Fixes: https://tracker.ceph.com/issues/42567

Signed-off-by: Tiago Melo <tmelo@suse.com>
2019-10-30 15:15:18 -01:00