From: Genevieve Bastien <gbastien@versatic.net>
To: kvm@vger.kernel.org
Subject: Shared value between host and guests
Date: Fri, 19 Jan 2018 15:03:25 -0500 [thread overview]
Message-ID: <5A624F0D.7010603@versatic.net> (raw)
Hi,
I'm tracing kvm guests and their host and an issue we have is to
identify which host process corresponds to which guest trace so we can
follow the state of the virtual cpu on the host.
For our needs, we fixed this problem by adding a kernel module on host
and guest where hosts and guests make an hypercall received by the other
and sending a UID between them. By tracing those hypercalls and tracking
the uid value, we can know which thread on the host corresponds to which
guest machine.
But we would like to achieve this without having to add an additional
module for tracing purposes. I'm wondering if there's already a value
somewhere in the kernel that is uniquely shared between the host
process/threads and the corresponding guest. And if not, would it be
possible/desirable to add one? For instance, the bootid of the guest
could be sent to the host process at the start and stored in some system
file. The trace could then retrieve it and the analysis can figure out
who's who all the traces.
Fyi, this is the kind of virtual machine analyses we can obtain by
tracing guest and host:
http://archive.eclipse.org/tracecompass.incubator/doc/org.eclipse.tracecompass.incubator.virtual.machine.analysis.doc.user/Virtual-Machine-Analysis-User-Documentation.html
We have more, but it is not yet documented unfortunately.
Thanks,
Geneviève
next reply other threads:[~2018-01-19 20:17 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-19 20:03 Genevieve Bastien [this message]
2018-01-23 17:21 ` Shared value between host and guests Stefan Hajnoczi
2018-01-24 15:56 ` Geneviève Bastien
2018-01-25 9:29 ` Stefan Hajnoczi
2018-01-25 15:44 ` Geneviève Bastien
2018-01-26 14:03 ` Stefan Hajnoczi
2018-01-29 0:59 ` Wanpeng Li
2018-01-29 10:18 ` Stefan Hajnoczi
2018-01-29 17:45 ` Geneviève Bastien
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5A624F0D.7010603@versatic.net \
--to=gbastien@versatic.net \
--cc=kvm@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).