This triggers with the new larger mon_globalid_prealloc value. It didn't
trigger on the existing cluster I tested on because it already had a very
large max.
Signed-off-by: Sage Weil <sage@redhat.com>
Glance has not completely moved to 'store' yet so we need to configure
the store in the DEFAULT section as well.
Fixes: #10478
Signed-off-by: Sébastien Han <sebastien.han@enovance.com>
100 ids (session 100 authentications) can be consumed quite quickly if
the monitor is being queried by the CLI via scripts or on a large cluster,
especially if the propose interval is long (many seconds). These live in
a 64-bit value and are only "lost" if we have a mon election before they
are consumed, so there's no real risk here.
Backport: giant, firefly
Reviewed-by: Joao Eduardo Luis <joao@redhat.com>
Signed-off-by: Sage Weil <sage@redhat.com>
This mirrors 0a49db8e6fa141a36ca964e68017d02b81ae7a3c but was not captured
by 9fff0c53bdc7bb332df1a710da3de71e3c41bec7.
Signed-off-by: Sage Weil <sage@redhat.com>
We don't know the full width until we get all table entries. Do not do
any padding before that. In particular, setw may left-pad on a column
that is left-justified.
Signed-off-by: Sage Weil <sage@redhat.com>
Fix the way we parse the marker. Instead of specifying whether it's a
sharded or not sharded bucket, we pass a shard_id. If string itself
points to a singe shard, we'll use the passed shard_id, otherwise we'll
parse the string and determine the shard id by that. In this way when
referencing a single shard we can get the marker with either shard id
specified or not. This works with the non-shard case too.
Adjust the bilog listing function, set it to work with the new
interface. It was broken before, and there are multiple fixes to it.
Signed-off-by: Yehuda Sadeh <yehuda@redhat.com>
Prior to this patch find_cmd_target() would perform the following
parsing for any given command:
- check if it's a "tell" to a parseable CephName
(i.e., ceph tell <type.id> ...)
- if so, return <type>, <id>
- check if it's a "tell" to a parseable PG id
(e.g., ceph tell 0.4a)
- if so, return 'pg', <pgid>
- check if it's a "pg" command to a parseable PG id
(e.g., ceph pg 0.4a)
- if so, return 'pg', <pgid>
- otherwise return 'mon', ''
However, parsing of CephName and CephPgid is performed in a relaxed
fashion, and tightening those checks requirements end up having
nefarious effects on properly formed commands, whereas keeping them
relaxed ends up having us returning 'mon','' in the end for a clearly
malformed target (e.g., 'ceph tell foo ...').
This patch fixes this behavior by adding a new check:
- if command is a "tell" and we were not able to parse either a CephName
nor a PG id, then explicitely validate the target as a CephName (given
we would be sending to a monitor anyway, we can just as well validate
a 'tell' as a CephName).
- if validation fails, we will propagate exceptions referring to the
cause of the validation failure.
Fixes: #10439
Signed-off-by: Joao Eduardo Luis <joao@redhat.com>
We were returning 'quorum_features' instead. This would lead to funny
and weird behavior. I hate funny.
Backport: emperor,firefly,giant
Signed-off-by: Joao Eduardo Luis <joao@redhat.com>
When we create a monitor we set a given number of compat features on
disk to clearly state the features a given monitor supports -- mostly to
break backward compatibility when such compatibility cannot be
guaranteed.
However, we may wish to toggle some features during runtime; e.g., wait
for all the monitors in the quorum to support a given feature before
flipping a switch and state that all monitors now require feature X.
We are already flipping those switches during runtime, but we weren't
allowing the monitor to set a subset of those features during mkfs.
While the initial approach worked fine with clusters being upgraded and
fresh clusters, it could become weird in a mixed-version environment.
Backport: emperor,firefly,giant
Signed-off-by: Joao Eduardo Luis <joao@redhat.com>
Some test case use tmp file to test.But they used same file and create
in the same directory. If we do in parallel, it will cause error.
So different test case use own their tmp file.
Signed-off-by: Jianpeng Ma <jianpeng.ma@intel.com>