From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Fajar A. Nugraha" Subject: Re: How does domain0 export information to guest through xenstore Date: Mon, 9 Aug 2010 11:40:05 +0700 Message-ID: References: <911857.94436.qm@web92403.mail.cnh.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=GB2312 Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: <911857.94436.qm@web92403.mail.cnh.yahoo.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: =?GB2312?B?uvrJ2cH6?= Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On Mon, Aug 9, 2010 at 7:31 AM, =BA=FA=C9=D9=C1=FA wr= ote: > > Hi, > I am tring to write xenstore some information ,so that a guest can re= ad, if i simply xenstore-write /foo "123" in domain 0, guest have not the p= ermission to read this ,and guest domain number are dynamic, so i can not w= rite a program to write /local/domain/X, which X is the domain id i want to= export information to, can i ? > So, is there a path (a static path,without domain number)that i write= to in domain 0, and guests have the permission to read ? You could make use of virsh to convert domU name to id. Something like this= : On dom0: # virsh domid domUname 41 # DOMU_ID=3D`virsh domid domUname` # xenstore-write /local/domain/${DOMU_ID}/my-data "test-data" # xenstore-read /local/domain/${DOMU_ID}/my-data test-data on domU: # xenstore-read my-data test-data --=20 Fajar