On 09/10/19 18:44, Mario Smarduch wrote: > In a large VPC environment we want to log memory error occurrences > and log them with guest name and type - there are few use cases > > > - if VM crashes on AR mce inform the user about the reason and resolve the > case > - if VM hangs notify the user to reboot and resume processing > - if VM continues to run let the user know, he/she maybe able to correlate > to vm internal outage > - Rawhammer attacks - isolate/determine the attacker possible migrating it off > the hypervisor > - In general track memory errors on a hyperviosr over time to determine trends > > Monitoring our fleet we come across quite a few of these and been > able to take action where before there were no clues to the causes. > > When memory error occurs we get a log entry in qemu log: > > Guest [Droplet-12345678] 2019-08-02T05:00:11.940270Z qemu-system-x86_64: > Guest MCE Memory Error at QEMU addr 0x7f3c7622f000 and GUEST 0x78e42f000 > addr of type BUS_MCEERR_AR injected > > with enterprise logging environment we can to take further actions. > > v1 -> v2: > - split into two patches one to get the gustname second to log MCEs > - addressed comments for MCE logging > > Mario Smarduch (2): > util/qemu-error: add guest name helper with -msg options > target/i386: log MCE guest and host addresses > > include/qemu/error-report.h | 1 + > qemu-options.hx | 10 ++++++---- > target/i386/kvm.c | 29 ++++++++++++++++++++++++----- > util/qemu-error.c | 31 +++++++++++++++++++++++++++++++ > vl.c | 5 +++++ > 5 files changed, 67 insertions(+), 9 deletions(-) >
Queued, thanks. Paolo