From: Ewan Mellor Subject: Re: Q: How to find own domid or uuid from domU? Date: Tue, 23 May 2006 11:02:55 +0100 Message-ID: <20060523100255.GA16064@leeni.uk.xensource.com> References: <87r72rppv2.fsf@pike.pond.sub.org> <87iro3pj2z.fsf@pike.pond.sub.org> <0cbcc9c018815b56e92521554c2cd585@cl.cam.ac.uk> <446C8488.1030503@us.ibm.com> <8d2b2f0e40dfb24f939a81970a493a7f@cl.cam.ac.uk> <446C910A.50000@us.ibm.com> <3d8eece20605180959i5b06dbd2q3f66ebfeba0be255@mail.gmail.com> <87sln1ch5r.fsf@pike.pond.sub.org> <20060523083121.GO10042@cl.cam.ac.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: <20060523083121.GO10042@cl.cam.ac.uk> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Christian Limpach Cc: xen-devel@lists.xensource.com, Markus Armbruster , "Andrew D. Ball" List-Id: xen-devel@lists.xenproject.org On Tue, May 23, 2006 at 09:31:21AM +0100, Christian Limpach wrote: > On Tue, May 23, 2006 at 09:52:00AM +0200, Markus Armbruster wrote: > > "Christian Limpach" writes: > > > > > There's a uuid node under the vm path. I.e. you'd do: > > > vmpath=$(xenstore-read vm) > > > uuid=$(xenstore-read $vmpath/uuid) > > > > Fails in domU: > > > > # xenstore-read vm > > /vm/947df77a-58b5-4e3d-9b6c-aa0178d8e133 > > # xenstore-read /vm/947df77a-58b5-4e3d-9b6c-aa0178d8e133/uuid > > xenstore-read: couldn't read path /vm/947df77a-58b5-4e3d-9b6c-aa0178d8e133/uuid > > Indeed, it's either broken because we've set the permissions not to > allow domains to have access to the /vm tree or because we don't allow > domains to read outside of their "home" directory. Permissions for doing this are set in Xend. At the moment, for security, we only allow a domain to look at /local/domain/, and /local/domain/0/backend//, IIRC. If it is reasonable to allow a guest to determine its UUID, then we could trivially add that to Xend, by allowing it to read that particular value from the vm directory. Ewan.