Page MenuHomeClusterLabs Projects

crm_verify should distinguish configuration warnings and errors
Closed (Released)Public

Assigned To
Authored By
kgaillot
Jun 12 2024, 10:58 AM
Tags
  • Restricted Project
  • Restricted Project
  • Restricted Project
  • Restricted Project
Referenced Files
None

Description

Regression introduced in 2.1.7

crm_verify sets output_config_issue(), which calls its output object's err() method, as the warning and error handler for pcmk__config_warn() and pcmk__config_err(). This is a change from earlier versions that used logging functions only, and it means there is no longer a "warning:" or "error:" prefix in the text output, and the XML output always uses error elements.

The easiest approach will be to split output_config_issue() into separate error and warning handlers, and add the "warning:" or "error:" prefix to the message. For XML, this means warnings will be displayed like <error>warning: ...</error>, but that's acceptable.