crimson/osd: write the 'osd_key' meta on OSD::mkfs().
Reviewed-by: Chunmei Liu <chunmei.liu@intel.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
Reviewed-by: Kefu Chai <tchaikov@gmail.com>
`PG::request_{local,remote}_recovery_reservation()` dynamically allocates
up to 2 instances of `LambdaContext<T>` and transfers their ownership to
the `AsyncReserver<T, F>`. This is expressed in raw pointers (`new` and
`delete`) notion. Further analysis shows the only place where `delete`
for these objects is called is the `AsyncReserver::cancel_reservation()`.
In contrast to the classical OSD, crimson doesn't invoke the method when
stopping a PG during the shutdown sequence. This would explain the
following ASan issue observed at Sepia:
```
Direct leak of 576 byte(s) in 24 object(s) allocated from:
#0 0x7fa108fc57b0 in operator new(unsigned long) (/lib64/libasan.so.5+0xf17b0)
#1 0x55723d8b0b56 in non-virtual thunk to crimson::osd::PG::request_local_background_io_reservation(unsigned int, std::unique_ptr<PGPeeringEvent, std::default_delete<PGPeeringEvent> >, std::unique_ptr<PGPeeringEvent, std::default_delete<PGPeeringEvent> >) (/usr/bin/ceph-osd+0x24d95b56)
#2 0x55723f1f66ef in PeeringState::WaitDeleteReserved::WaitDeleteReserved(boost::statechart::state<PeeringState::WaitDeleteReserved, PeeringState::ToDelete, boost::mpl::list<mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na, mpl_::na>, (boost::statechart::history_mode)0>::my_context) (/usr/bin/ceph-osd+0x266db6ef)
```
Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
before this change the note on "apply" command is embedded in the note
on "_no_schedule". and they are not related. so let's move the former
out. also, highlight the yaml file sample in YAML.
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
This is for the compliance with the classical OSD. No problem
with lack of this file has been identified yet.
Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
This commit fixes an issue identified during the Rook-crimson effort.
Missing the `write_meta()` on `osd_key` made the CephX inoperational
because of imposibility to load the keyring. Disabling CephX in turn
caused the auth method negotation to fail when reaching out to a monitor.
```
ERROR 2021-09-28 21:19:46,598 [shard 0] none - auth: unable to find a keyring on /var/lib/ceph/osd/ceph-0/keyring: (2) No such file or directory
ERROR 2021-09-28 21:19:46,598 [shard 0] none - AuthRegistry(0x7fa38c322b68) no keyring found at /var/lib/ceph/osd/ceph-0/keyring, disabling cephx
...
INFO 2021-09-28 21:19:46,601 [shard 0] monc - get_auth_request(con=[client.?(temp_mon_client) 172.17.0.1:0/2910147961@63138 >> mon.? v2:10.108.187.31:3300/0], auth_method=0)
INFO 2021-09-28 21:19:46,601 [shard 0] monc - get_auth_request no methods is supported
...
WARN 2021-09-28 21:20:06,612 [shard 0] monc - cannot establish the active_con with any mon
```
Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
* refs/pull/43287/head:
mgr/rook, qa/tasks/rook: change rgw daemon service name
mgr/rook: fix placement_spec_to_node_selector
mgr/rook: orch rm no longer uses rook api delete
qa/tasks/rook: fix cluster deletion hanging due to CephObjectStore CR
mgr/rook: use default replication size in orch apply rgw
mgr/rook: add placement specs to apply rgw
Reviewed-by: Sage Weil <sage@redhat.com>
qa/mgr/dashboard: add extra wait to test
Reviewed-by: Alfonso Martínez <almartin@redhat.com>
Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
Reviewed-by: Deepika Upadhyay <dupadhya@redhat.com>
Reviewed-by: Nizamudeen A <nia@redhat.com>
os/bluestore: list obj which equals to pend
Reviewed-by: Mykola Golub <mgolub@suse.com>
Reviewed-by: Xinze Chi <xinze@xsky.com>
Reviewed-by: xie xingguo <xie.xingguo@zte.com.cn>
mgr/dashboard: Move force maintenance test to the workflow test suite
Reviewed-by: Avan Thakkar <athakkar@redhat.com>
Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
Reviewed-by: Nizamudeen A <nia@redhat.com>
Reviewed-by: Pere Diaz Bou <pdiazbou@redhat.com>
mgr/cephadm: populate trusted_ip_list in iscsi-gateway.cfg with mgr ips
Reviewed-by: Adam King <adking@redhat.com>
Reviewed-by: Michael Fritch <mfritch@suse.com>
Adds an exclusive stage for obtaining projected usage as well as an
unordered one for submitting ool writes. This should allow for a
straightforward wait-list when io is blocked while still allowing
concurrent submission of ool writes otherwise.
Fixes: https://tracker.ceph.com/issues/52698
Signed-off-by: Samuel Just <sjust@redhat.com>
We're going to want to permit multiple transactions to be writing
concurrently. Replace await_hard_limits() with a mechanism that
remembers bytes that will be used by in-progress operations.
Signed-off-by: Samuel Just <sjust@redhat.com>
* refs/pull/43177/head:
osd/PrimaryLogPG: drop ops when pool has EIO flag
osdc/Objecter: set SUPPORTSPOOLEIO flag on all ops
ceph_test_rados_api_aio: test pool EIO flag
osdc/Objecter: return EIO for new linger ops
osdc/Objecter: return EIO for existing ops and linger ops
osdc/Objecter: return EIO for new ops
osd,mon: add EIO pool flag
Reviewed-by: Josh Durgin <jdurgin@redhat.com>
Reviewed-by: Neha Ojha <nojha@redhat.com>
Reviewed-by: Samuel Just <sjust@redhat.com>
otherwise we could have failures like
scrub : stat mismatch, got 3/4 objects, 1/2 clones, 3/4 dirty, 3/4 omap, 0/0 pinned, 0/0 hit_set_archive, 0/0 whiteouts, 49/56 bytes, 0/0 manifest objects, 0/0 hit_set_archive bytes."
where the numbers of scrubbed object, clones, dirty and omap are always
less than the total number of corresponding numbers, if the PG contains
object(s) whose hash happens to be 0xffffffff.
in this change, if the calculated hash of the upper bound is greater
than the maximum possible number represented by uint32_t, in addition to
setting the hash of the upper bound hobj to 0xffffffff, we also set the
nspace of hobj of the upper bound to "\xff", so that the upper bound
is greater than an hobj whose hash happens to be 0xfffffff. please note,
the nspace of "\xff" is not an ascii string, so it's not likely to be
less than a real-world nspace of an hobj.
with this new *greater* upper bound, we are able to include the previous
missing hobj when listing the objects in a PG. so the scrub won't be
annoyed when the number of objects does not match.
Fixes: https://tracker.ceph.com/issues/52705
Signed-off-by: Mykola Golub <mykola.golub@clyso.com>
Signed-off-by: Kefu Chai <tchaikov@gmail.com>
* The number of ool records written;
* Write overhead from journal/ool records;
* Wasted writes from invalided ool records;
* Wasted writes from erased inline extents;
* Distinguish ool and inline extents from metrics;
Signed-off-by: Yingxin Cheng <yingxin.cheng@intel.com>