Is there any easy way in a shell script to find out the domid of "the domain I just created" with xm create? ==================================Thanks... for the memory I really could use more / My throughput's on the floor The balloon is flat / My swap disk's fat / I've OOM's in store Overcommitted so much (with apologies to the late great Bob Hope) _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
"Dan Magenheimer" <dan.magenheimer@oracle.com> writes:> Is there any easy way in a shell script to find out the > domid of "the domain I just created" with xm create?xm create domain xm list domain is the best way I know of getting it... you just need to sed it out. But usually I try not to use the numeric domain id for anything; if you set vifname= on the vif= line, to my knowledge there isn''t anything you can''t do with symbolic names that you can do with the numeric id. _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
xenstore-list /local/domain And just get the last line or grep by name -----Original Message----- From: "Dan Magenheimer"<dan.magenheimer@oracle.com> Sent: 31/05/08 1:04:01 PM To: "Xen-Devel (E-mail)"<xen-devel@lists.xensource.com> Subject: [Xen-devel] Domid for just created domain? Is there any easy way in a shell script to find out the domid of "the domain I just created" with xm create? ==================================Thanks... for the memory I really could use more / My throughput''s on the floor The balloon is flat / My swap disk''s fat / I''ve OOM''s in store Overcommitted so much (with apologies to the late great Bob Hope) _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel
Thanks! I hadn't realized that xenstore-ls and xenstore-list were different so I was using: # xenstore-ls | grep domid | tail -1 | \ sed 's/.*\([0-9][0-9]*\).*/\1/' but # xenstore-list | tail -1 is even better!> -----Original Message----- > From: James Harper [mailto:james.harper@bendigoit.com.au] > Sent: Saturday, May 31, 2008 2:25 AM > To: dan.magenheimer@oracle.com; xen-devel@lists.xensource.com > Subject: RE: [Xen-devel] Domid for just created domain? > > > xenstore-list /local/domain > And just get the last line or grep by name > > -----Original Message----- > From: "Dan Magenheimer"<dan.magenheimer@oracle.com> > Sent: 31/05/08 1:04:01 PM > To: "Xen-Devel (E-mail)"<xen-devel@lists.xensource.com> > Subject: [Xen-devel] Domid for just created domain? > > Is there any easy way in a shell script to find out the > domid of "the domain I just created" with xm create? > > ==================================> Thanks... for the memory > I really could use more / My throughput's on the floor > The balloon is flat / My swap disk's fat / I've OOM's in store > Overcommitted so much > (with apologies to the late great Bob Hope) > >_______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel