GrepBoard/Manuals
605 manuals ·

Fix Ceph unrecognized config option osd_repair_during_recovery

·Tested on Ceph Tentacle 20.2.4 · Squid 19.2.3 official docs and source · 2026-10·Test scope ↓·6 steps

Tentacle 20.2.0 removed osd_repair_during_recovery, so ceph config set fails. Drop it from automation and clear old values with ceph config rm.

output
unrecognized config option 'osd_repair_during_recovery'

If a deployment script or configuration management tool stops at ceph config set … osd_repair_during_recovery … with this message after moving to Ceph Tentacle (20.2), the option was removed in 20.2.0. Operator-initiated scrubs and repairs are no longer blocked during recovery, so the setting has nothing left to do. Remove the line from your automation and clear any old value left in the config database with ceph config rm. The block above is not captured output; it is the string in the source ([ConfigMonitor.cc L549-L558, v20.2.4](https://github.com/ceph/ceph/blob/v20.2.4/src/mon/ConfigMonitor.cc#L549-L558)).

[1] Confirm what was removed. The 20.2.0 RADOS entry of the Tentacle release notes says the option controlled whether an operator-initiated "repair scrub" could start on an OSD performing recovery, and that in this version operator-initiated scrubs and repair scrubs are never blocked. 20.2.3 adds "Scrub: “repairing” scrubs are now allowed at all times."

Versionosd_repair_during_recovery
Squid 19.2.3Present: bool, default false, "Allow requested repairing when PGs on the OSD are undergoing recovery" ([osd.yaml.in L258-L263](https://github.com/ceph/ceph/blob/v19.2.3/src/common/options/osd.yaml.in#L258-L263))
Tentacle 20.2.4Not in the option definitions [osd.yaml.in](https://github.com/ceph/ceph/blob/v20.2.4/src/common/options/osd.yaml.in)

The similarly named osd_scrub_during_recovery still exists in both versions. It is not what this article is about, so leave it alone.

[2] See which commands break and how. The monitor checks whether the option exists only for config set.

CommandTentacle response
ceph config set osd osd_repair_during_recovery trueunrecognized config option 'osd_repair_during_recovery' (EINVAL)
ceph config get osd osd_repair_during_recoveryunrecognized key 'osd_repair_during_recovery' (ENOENT, L332-L339)
ceph config rm osd osd_repair_during_recoveryRemoves it without checking the option exists

Adding --force to config set skips the check and stores the value, but that only leaves another value for an option that is no longer defined. Do not use it.

[3] Find old values left in the config database. Values you set before the upgrade survive it: when the monitor loads an option it does not know, it keeps it as an unknown "stray" option instead of dropping it ([ConfigMap.cc L261-L275, v20.2.4](https://github.com/ceph/ceph/blob/v20.2.4/src/mon/ConfigMap.cc#L261-L275)).

console
$ ceph config dump | grep osd_repair_during_recovery

[4] Remove the leftover value. The target comes from two columns of the dump line, WHO and MASK. If MASK is empty, use WHO as is (for example osd, osd.3 or global). If MASK has a value (for example class:ssd), join the two with a slash, as in osd/class:ssd. The display splits them into separate columns, but commands take them joined by a slash (sections and masks), and the monitor deletes only the single key built from both ([ConfigMonitor.cc L575-L600, v20.2.4](https://github.com/ceph/ceph/blob/v20.2.4/src/mon/ConfigMonitor.cc#L575-L600)), so WHO alone leaves a masked value in place. Save the dump line first. There is no way back to Squid, so you will not restore it, but it helps trace who set it and why.

console
$ ceph config rm osd osd_repair_during_recovery$ ceph config rm osd/class:ssd osd_repair_during_recovery$ ceph config dump | grep osd_repair_during_recovery

The second command is the example for a dump line whose MASK is class:ssd. Run one config rm per line the dump shows.

When the last command prints nothing, you are done. config rm is registered in the monitor command table as "Clear a configuration option for one or more entities".

[5] Remove the line from automation and config files. Search playbooks, templates and each node's /etc/ceph/ceph.conf for the name.

console
$ grep -rn osd_repair_during_recovery /etc/ceph/

How daemons treat a leftover line in ceph.conf (for example, whether they log a warning) could not be confirmed. Removing it is the safe choice.

[6] If you need a repair during recovery, there is no option to turn on anymore. That only means it is not blocked; it does not make ceph pg repair safe. A repair is not a read: it changes data state, and there is no general command to undo it. According to the PG troubleshooting docs, repair overwrites the digest of the inconsistent copy with that of the authoritative copy, and in a replicated pool it marks the inconsistent copy as missing. Without a checksum it favors the primary's data, which might not be the uncorrupted replica, so the docs say human intervention is needed when an inconsistency is found.

So work in this order. Find the target PG in ceph health detail and look at which shard has which error first. If a shard's errors lists read_error, the cause is likely a physical storage error, so check dmesg and smartctl on that OSD's node before anything else. Once you know the cause, repair only that PG; do not script repairs across many PGs at once.

console
$ ceph health detail$ rados list-inconsistent-obj <pgid> --format=json-pretty$ ceph pg repair <pgid>

For other changes to check around the upgrade, see Squid to Tentacle upgrade pre-check.

#ceph#osd#scrub#config#tentacle