From: mike@flyn.org (W. Michael Petullo)
To: kernelnewbies@lists.kernelnewbies.org
Subject: Question about uprobes
Date: Thu, 6 Apr 2017 12:47:39 -0400 [thread overview]
Message-ID: <20170406164739.GA4154@imp.flyn.org> (raw)
In-Reply-To: <CAGdaadZ=nJuMuaYbuRrMyAmxVBFAvt88FM6E0bTWkuGyTAR2pg@mail.gmail.com>
>> I am writing some software that monitors a guest VM using virtual-machine
>> introspection and "hijacks" system calls under certain conditions. For
>> example, the program might inject an int3/breakpoint into the guest
>> kernel at the entry point to sys_open. When the breakpoint is hit, the
>> program might set the guest instruction pointer to the address to which
>> sys_open would have itself returned and set register RAX to some desired
>> error-code return value.
>>
>> The problem I am encountering is that for some reason the process is
>> triggering a "uprobe ... failed to handle uretprobe" message from the
>> guest kernel. I do not yet know enough about uprobes to understand what
>> might be causing this. Is there something in procedures such as sys_open
>> which must execute to prevent the error which causes the kernel to print
>> this message?
>> What vm hypervisor do you use?
We are using Xen + libvmi.
I have continued to read the kernel sources, and as best as I can
understand it the kernel installs uprobe instrumentation if it detects
a software breakpoint. Our program does not reinject the software
breakpoints it services back into the guest, so I am still trying to
figure out why uprobes seems to get triggered.
--
Mike
:wq
next prev parent reply other threads:[~2017-04-06 16:47 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-06 0:40 Question about uprobes W. Michael Petullo
2017-04-06 15:22 ` Mulyadi Santosa
2017-04-06 16:47 ` W. Michael Petullo [this message]
2017-04-07 11:51 ` Mulyadi Santosa
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=20170406164739.GA4154@imp.flyn.org \
--to=mike@flyn.org \
--cc=kernelnewbies@lists.kernelnewbies.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).