virDomainGetMessages: Introduce VIR_DOMAIN_MESSAGE_IOERRORS

Report any stored I/O error messages reported by the hypervisor when
reporting messages of a domain. As the I/O error may be already stale we
report also the timestamp when it was recorded.

Example message:

 I/O error: disk='vda', index='1', path='/dev/mapper/errdev0', timestamp='2025-01-28 15:47:52.776+0000', message='Input/output error'

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
This commit is contained in:
Peter Krempa
2025-02-04 14:40:55 +01:00
parent 1a02760cc6
commit 666219f5f1
7 changed files with 78 additions and 3 deletions
+3
View File
@@ -6520,6 +6520,9 @@ int virDomainAuthorizedSSHKeysSet(virDomainPtr domain,
typedef enum {
VIR_DOMAIN_MESSAGE_DEPRECATION = (1 << 0), /* (Since: 7.1.0) */
VIR_DOMAIN_MESSAGE_TAINTING = (1 << 1), /* (Since: 7.1.0) */
VIR_DOMAIN_MESSAGE_IOERRORS = (1 << 2), /* Report available stored I/O
errors messages for disk images
(Since: 11.1.0) */
} virDomainMessageType;
int virDomainGetMessages(virDomainPtr domain,