* refs/pull/40924/head:
mgr/cephadm: check hostname resolution before adding host
cephadm: provide a way to checkhost connection without /etc/hosts passed the shell
doc/cephadm: remove /etc/hosts from list of hostname resoltion methods
Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Adam King <adking@redhat.com>
* refs/pull/40941/head:
qa/suites/rados/cephadm/smoke-roleless: test client-keyring
qa/tasks/cephadm.py: adjust client.admin key mode; place on all hosts
cephadm: distribute client.admin keyring+conf to label:_admin on bootstrap
doc/cephadm: document the default 'admin' label
mgr/cephadm: 'ceph orch client-keyring ...' commands to manage keyring files
mgr/cephadm: reimplement ceph.conf pushing
mgr/cephadm: use _write_remote_file for ceph.conf
mgr/cephadm: _write_remote_file helper
mgr/cephadm: add placementspec for which hosts get ceph.conf
Reviewed-by: Sebastian Wagner <swagner@suse.com>
Reviewed-by: Adam King <adking@redhat.com>
* refs/pull/40943/head:
mgr/cephadm: skip ok-to-stop for mons in upgrade if < 3 mons
mgr/cephadm: don't allow upgrade start with less than 2 mgrs
Reviewed-by: Michael Fritch <mfritch@suse.com>
* refs/pull/41049/head:
cephadm: re-assimilate user provided conf after mgr created
Reviewed-by: Sage Weil <sage@redhat.com>
Reviewed-by: Sebastian Wagner <swagner@suse.com>
Setting auth_expose_insecure_global_id_reclaim to false disables the
"disconnect right after authentication" behavior, not the warning.
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
this change silences the warning from clang, like:
../src/crimson/common/interruptible_future.h:276:8: warning: lambda capture 'this' is not used [-Wunused-lambda-capture]
[this, func=std::move(func),
^
Signed-off-by: Kefu Chai <kchai@redhat.com>
this change silences warning like:
../src/crimson/os/seastore/onode_manager/staged-fltree/fltree_onode_manager.h:80:18: warning: class with destructor marked 'final' cannot be inherited from [-Wfinal-dtor-non-final-class]
~FLTreeOnode() final {}
^
../src/crimson/os/seastore/onode_manager/staged-fltree/fltree_onode_manager.h:13:8: note: mark 'crimson::os::seastore::onode::FLTreeOnode' as 'final' to silence this warning
struct FLTreeOnode : Onode, Value {
^
Signed-off-by: Kefu Chai <kchai@redhat.com>
this change addresses the build failure with clang:
src/crimson/os/seastore/onode_manager/staged-fltree/node_extent_accessor.h:352:29: error: 'encode_split' following the 'template' keyword does not refer to a template
test_recorder->template encode_split(split_at, read().p_start());
~~~~~~~~ ^
Signed-off-by: Kefu Chai <kchai@redhat.com>
structured binding does not define variables. unlike GCC, Clang does
not allow this. this change address following build failures with clang:
../src/crimson/os/seastore/omap_manager/btree/omap_btree_node_impl.cc:210:24:
note: 'result' declared here
auto &[complete, result] = ret;
^
../src/crimson/os/seastore/omap_manager/btree/omap_btree_node_impl.cc:214:6:
error: reference to local binding 'complete' declared in enclosing
lambda expression
complete = biter == eiter;
^
Signed-off-by: Kefu Chai <kchai@redhat.com>
This PR corrects a title so that the title
more accurately describes the content in the
section it names.
Fixes: https://tracker.ceph.com/issues/50517 (partially)
Signed-off-by: Zac Dover <zac.dover@gmail.com>
in C++17, the C++ standard ensures that the return value in this case
can be optimized with copy elision, adding std::move() is not necessary,
and prevents copy elision from happening.
this change also silences the warning of:
../src/rgw/rgw_rest_sts.cc: In member function 'std::unique_ptr<rgw::sal::RGWOIDCProvider> rgw::auth::sts::WebTokenEngine::get_provider(const DoutPrefixProvider*, const string&, const string&) const':
../src/rgw/rgw_rest_sts.cc:92:19: warning: moving a local object in a return statement prevents copy elision [-Wpessimizing-move]
92 | return std::move(provider);
| ~~~~~~~~~^~~~~~~~~~
../src/rgw/rgw_rest_sts.cc:92:19: note: remove 'std::move' call
Signed-off-by: Kefu Chai <kchai@redhat.com>
mgr/cephadm: The command of 'ceph orch daemon restart mgr.xxx' may ca…
Reviewed-by: Sebastian Wagner <swagner@suse.com>
Reviewed-by: Adam King <adking@redhat.com>
If we are placing ceph.conf in /etc/ceph (the default), tell the cluster
to continue doing this going forward to hosts with the '_admin' label.
This doesn't induce the user to add the admin label to other hosts too,
unfortunately--e probably want them to add the admin label to other mons,
for instance--but it is a start.
Signed-off-by: Sage Weil <sage@newdream.net>
crimson/monc: fix use-after-free around Connection::do_auth_single().
Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Kefu Chai <kchai@redhat.com>
This bug caused following failure in teuthology testing [1]:
```
WARN 2021-04-23 07:08:29,449 [shard 0] osd - ms_handle_reset
WARN 2021-04-23 07:08:29,449 [shard 0] monc - active conn reset v2:172.21.15.100:3300/0
INFO 2021-04-23 07:08:29,449 [shard 0] monc - reopen_session to mon.-1
INFO 2021-04-23 07:08:29,449 [shard 0] monc - close
INFO 2021-04-23 07:08:29,449 [shard 0] monc - connecting to mon.0
...
ERROR 2021-04-23 07:08:29,450 [shard 0] none - /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-3454-gddedc2e1/rpm/el8/BUILD/ceph-17.0.0-3454-gddedc2e1/src/crimson/mon/MonClient.cc:228 : In function 'crimson::mon::Connection::do_auth_single(crimson::mon::Connection::request_t)::<lambda(Ref<MAuthReply>)>', ceph_assert(%s)
closed
```
[1]: http://pulpito.front.sepia.ceph.com/rzarzynski-2021-04-22_00:20:19-rados-master-distro-basic-smithi/6063316/
The root cause is in freeing the `active_con` in `Client::reopen_session()`
while there still could be the second, ongoing part of `do_auth_single()`.
This fix rectifies the issue by switching `std::unique_ptr` to `seastar::shared_ptr`
and extending the life-time with the help of `seastar::enable_shared_from_this<T>`.
Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
Teach cephadm to manage keyring files on cluster hosts. These keys must
already exist in the mon auth database--cephadm does not create them if
they don't exist (and will issue warnings to the log if they do not).
A ceph.conf is pushed implicitly along with the keyring file.
Each keyring added will be pushed to the hosts described by the placement
spec with the appropriate ownership and mode. If the ownership, mode, or
path are modified, the files are rewritten or removed as need.
If the client-keyring entry is removed, the keyring files are removed.
Signed-off-by: Sage Weil <sage@newdream.net>
Scene:
The mgr daemon is active. After execing restart command, it may be save "scheduled_daemon_actions": {"mgr.xxx": "restart"}}" to config-key.
So the mgr daemon will restart before call rm_scheduled_daemon_action which case mgr daemon will load restart forever.
Fix mgr infinite restart issue refering to the same solution as 'ceph orch daemon redeploy'.
Signed-off-by: jianglong01 <jianglong01@qianxin.com>