From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58471) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZpiY5-0005T8-Vs for qemu-devel@nongnu.org; Fri, 23 Oct 2015 16:02:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZpiY2-0002mT-QZ for qemu-devel@nongnu.org; Fri, 23 Oct 2015 16:02:49 -0400 Received: from mail-qg0-x22e.google.com ([2607:f8b0:400d:c04::22e]:35997) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZpiY2-0002mN-Ne for qemu-devel@nongnu.org; Fri, 23 Oct 2015 16:02:46 -0400 Received: by qgad10 with SMTP id d10so75477511qga.3 for ; Fri, 23 Oct 2015 13:02:46 -0700 (PDT) Sender: Richard Henderson References: <1444952643-5033-1-git-send-email-valerio@aimale.com> <87h9lrkz56.fsf@blackfin.pond.sub.org> <56210A17.6080401@aimale.com> <87io63xpke.fsf@blackfin.pond.sub.org> <56250035.40805@aimale.com> <87twpkqyow.fsf@blackfin.pond.sub.org> <20151022191203.GC3736@thinpad.lan.raisama.net> <877fmeqeho.fsf@blackfin.pond.sub.org> <20151023192427.GK3736@thinpad.lan.raisama.net> From: Richard Henderson Message-ID: <562A925E.7020806@twiddle.net> Date: Fri, 23 Oct 2015 10:02:38 -1000 MIME-Version: 1.0 In-Reply-To: <20151023192427.GK3736@thinpad.lan.raisama.net> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] QEMU patch to allow VM introspection via libvmi List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eduardo Habkost , Markus Armbruster Cc: Paolo Bonzini , qemu-devel@nongnu.org, Valerio Aimale , lcapitulino@redhat.com On 10/23/2015 09:24 AM, Eduardo Habkost wrote: > On Fri, Oct 23, 2015 at 08:35:15AM +0200, Markus Armbruster wrote: >> Eduardo Habkost writes: >> >>> On Wed, Oct 21, 2015 at 12:54:23PM +0200, Markus Armbruster wrote: >>>> Valerio Aimale writes: >>> [...] >>>>> There's also a similar patch, floating around the internet, the uses >>>>> shared memory, instead of sockets, as inter-process communication >>>>> between libvmi and QEMU. I've never used that. >>>> >>>> By the time you built a working IPC mechanism on top of shared memory, >>>> you're often no better off than with AF_LOCAL sockets. >>>> >>>> Crazy idea: can we allocate guest memory in a way that support sharing >>>> it with another process? Eduardo, can -mem-path do such wild things? >>> >>> It can't today, but just because it creates a temporary file inside >>> mem-path and unlinks it immediately after opening a file descriptor. We >>> could make memory-backend-file also accept a full filename as argument, >>> or add a mechanism to let QEMU send the open file descriptor to a QMP >>> client. >> >> Valerio, would an command line option to share guest memory suffice, or >> does it have to be a monitor command? If the latter, why? >> >> Eduardo, I'm not sure writing to guest memory behind TCG's back will >> work. Do you know? > > I don't know. I guess it may possibly surprise TCG depending on how some > operations are implemented, but it sounds unlikely. CCing Richard. Writing to guest memory will work, in that the guest will see the changes. The harder part is synchronization. Here you'll face all the same problems that are currently being addressed in the multi-threaded tcg patch sets. r~