expect_failure $TEMP_DIR "Option --osd_op_history_duration requires an argument" \
ceph tell osd.0 injectargs -- '--osd_op_history_duration'
+ ceph tell osd.0 injectargs -- '--osd_deep_scrub_interval 2419200' >& $TMPFILE || return 1
+ check_response "osd_deep_scrub_interval = '2419200.000000' (not observed, change may require restart)"
+
+ ceph tell osd.0 injectargs -- '--mon_probe_timeout 2' >& $TMPFILE || return 1
+ check_response "mon_probe_timeout = '2.000000' (not observed, change may require restart)"
+
ceph tell osd.0 injectargs -- '--mon-lease 6' >& $TMPFILE || return 1
- check_response "mon_lease = '6' (not observed, change may require restart)"
+ check_response "mon_lease = '6.000000' (not observed, change may require restart)"
# osd-scrub-auto-repair-num-errors is an OPT_U32, so -1 is not a valid setting
- expect_false ceph tell osd.0 injectargs --osd-scrub-auto-repair-num-errors -1
+ expect_false ceph tell osd.0 injectargs --osd-scrub-auto-repair-num-errors -1 >& $TMPFILE || return 1
+ check_response "Error EINVAL: Parse error setting osd_scrub_auto_repair_num_errors to '-1' using injectargs"
}
function test_mon_injectargs_SI()
check_response "Error EINVAL: Failed crushmap test: TEST FAIL"
local mon_lease=`ceph-conf --show-config-value mon_lease`
+ mon_lease=`echo ${mon_lease} | awk '{ printf $1 + 0 }'`
test "${mon_lease}" -gt 0
ostringstream oss;
if (bool *flag = boost::get<bool>(&config_value)) {
oss << (*flag ? "true" : "false");
+ } else if (float *fp = boost::get<float>(&config_value)) {
+ oss << std::fixed << *fp ;
+ } else if (double *dp = boost::get<double>(&config_value)) {
+ oss << std::fixed << *dp ;
} else {
oss << config_value;
}