Xiubo Li [Fri, 12 Mar 2021 15:39:21 +0000 (23:39 +0800)]
lockdep: fix follows/follows_bt resize() size
Without this the size of follows/follows_bt won't ever change, and
if the total lock number larger than 4094 it will cause crash in
lockdep_will_lock().
Xiubo Li [Fri, 12 Mar 2021 12:49:24 +0000 (20:49 +0800)]
lockdep: switch follows_bt vector member to std::map
Delete the MAX_FOLLOWERS and increase the bitset size to MAX_LOCKS
in 'follows'. The maximum memories of the 'follows' will be 2GB.
But for the 'follows_bt', if we continue use the std::array, the
maximum memories will be 128G, but most of the array spaces are
useless. Switch the std::array to std::man instead.
This doesn't actually make sense for FuturzizedStore implementations other
than BlueStore, and then only in a diagnostic capacity. It also doesn't
have any actual users at the moment.
Doesn't actually have a TransactionManager implementation, and
it needs substantial changes to adapt to changes in Onode.
We can resurrect it in the future if we want to.
Kefu Chai [Wed, 10 Mar 2021 03:08:47 +0000 (11:08 +0800)]
doc/_themes: fine tune styling
* fix the "dl" (definition list) display in manpage. before this
change, if an item in dl is composed of strings with different fonts,
it is cluttered into a single string. after this change, they are
separated with proper spacing as before. see the "WORKLOAD" section in
https://docs.ceph.com/en/latest/man/8/ceph-syn/ and
https://docs.ceph.com/en/octopus/man/8/ceph-syn/
* reduce the spacing in "ul" (unordered list) in table. before
this change, we have large spacing at end of a list in table. after
this change, the spacing is reduced. see
https://docs.ceph.com/en/latest/start/hardware-recommendations/#ram
https://docs.ceph.com/en/octopus/start/hardware-recommendations/#ram
* increase the spacing between two "ul"s in table. see
https://docs.ceph.com/en/latest/start/hardware-recommendations/#Processor
https://docs.ceph.com/en/octopus/start/hardware-recommendations/#ram
* refs/pull/39408/head:
test: add test for validating cephfs-mirror daemon service status
pybind/mirroring: interface to fetch mirror daemon status
cephfs-mirror: register mirror daemon with service manager
cephfs-mirror: remove unneeded json_spirit header
Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
* refs/pull/39687/head:
tools/cephfs-shell: continue file listing even on error
tools/cephfs-shell: refactoring of code related listing
tools/cephfs-shell: fix listing of symbolic links
Reviewed-by: Rishabh Dave <ridave@redhat.com> Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Sage Weil [Tue, 9 Mar 2021 18:15:20 +0000 (12:15 -0600)]
mgr/cephadm: do not prime service cache on reconfig
Ceph daemon reconfig does not need any daemon state refresh since we don't
do a restart--we just rewrite the ceph.conf. This also avoids priming
our cache with a 'starting' state when the daemon wasn't touched.
Fixes: https://tracker.ceph.com/issues/49675 Signed-off-by: Sage Weil <sage@newdream.net>
Kefu Chai [Thu, 4 Mar 2021 10:25:33 +0000 (18:25 +0800)]
cmake: silence "You are in 'detached HEAD' state" warning
git warns us when the repo is in 'detached HEAD' state, like:
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in
this state without impacting any branches by switching back to a branch.
...
Turn off this advice by setting config variable advice.detachedHead to
false
Daniel Pivonka [Mon, 8 Mar 2021 19:04:29 +0000 (14:04 -0500)]
mgr/cephadm: prevent traceback when invalid osd id passed to 'orch osd rm stop'
orch osd rm exepcts a str that can be converted to an int passed to it
if the user passed something that cant be converted it shows a traceback
catching the ValueError prevents this traceback.
Signed-off-by: Daniel Pivonka <dpivonka@redhat.com>
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>
Kefu Chai [Mon, 8 Mar 2021 08:09:34 +0000 (16:09 +0800)]
common/lockdep: increase MAX_LOCKS to 128k
initialize follows and follows_bt with 4k, and resize them when the
size of locks exceeds the initial number, but with the upper bound of
MAX_LOCKS which is fixed at compile time.
this change allows us to use 128k locks in the same time.
Kefu Chai [Mon, 8 Mar 2021 07:34:47 +0000 (15:34 +0800)]
common/lockdep: introduce MAX_FOLLOWERS
before this change we use a matrix for tracking the locks and those
which are locked after acquiring the formers. where follows[a][b]
sigifies that b is acquired after a is acquired, and a and b are both
lock ids allocated in the lock_ids registry.
but since we might need to have a much large set of locks which are
acquired at the same time. but the numbers of their follower of
each of them are always much smaller. because we are not likely
to hold, for instance, 4096 locks when we still holding a lock.
actually, this might be a bug, if we actually do this.
so we can use smaller vectors for tracking the followers. and the
size of those vectors can be one or more orders of magnitude smaller
than the number of locks.
in this change, MAX_FOLLOWERS in introduced for the max number
of followers.
Kefu Chai [Mon, 8 Mar 2021 06:44:14 +0000 (14:44 +0800)]
common/lockdeps: use vector to allocate follows and follows_bt on heap
this allows us to increase MAX_LOCKS without being limited by the size
of .bss segment. as cephfs plans to use a large number of locks for
finer grained inode lock.
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.