<p dir="ltr"><br>
Il 09/ott/2013 15:39 "Gianluca Cecchi" <<a href="mailto:gianluca.cecchi@gmail.com">gianluca.cecchi@gmail.com</a>> ha scritto:<br>
><br>
><br>
> Il 09/ott/2013 15:35 "Dan Kenigsberg" <<a href="mailto:danken@redhat.com">danken@redhat.com</a>> ha scritto:<br>
><br>
> ><br>
> > On Wed, Oct 09, 2013 at 02:27:16PM +0200, Gianluca Cecchi wrote:<br>
> > > On Tue, Oct 8, 2013 at 12:27 PM, Omer Frenkel wrote:<br>
> > ><br>
> > > >> ><br>
> > > >> > so now I'm able to start VM without having to select run once and<br>
> > > >> > attaching a cd iso<br>
> > > >> > (note that is only valid for newly created VMs though)<br>
> > > >><br>
> > > >> Yes. Old VMs are trashed with the bogus address reproted by the buggy<br>
> > > >> Vdsm. Can someone from engine supply a script to clear all device<br>
> > > >> addresses from the VM database table?<br>
> > > >><br>
> > > ><br>
> > > ><br>
> > > > you can use this line (assuming engine as db and user), make sure only 'bad' vms return:<br>
> > > > psql -U engine -d engine -c "select distinct vm_name from vm_static, vm_device where vm_guid=vm_id and device='cdrom' and address ilike '%pci%';"<br>
> > > ><br>
> > > > if so, you can run this to clear the address field for them, so they could run again:<br>
> > > > psql -U engine -d engine -c "update vm_device set address='' where device='cdrom' and address ilike '%pci%';"<br>
> > > ><br>
> > ><br>
> > > I wanted to test this but for some reason it seems actually it solved itself.<br>
> > > I first ran the query and already had no value:<br>
> > > engine=# select distinct vm_name from vm_static, vm_device where<br>
> > > vm_guid=vm_id and device='cdrom' and address ilike '%pci%';<br>
> > > vm_name<br>
> > > ---------<br>
> > > (0 rows)<br>
> > ><br>
> > > (overall my VMs are<br>
> > > engine=# select distinct vm_name from vm_static;<br>
> > > vm_name<br>
> > > -----------<br>
> > > Blank<br>
> > > c6s<br>
> > > c8again32<br>
> > > (3 rows)<br>
> ><br>
> > Which of these 3 is the one that was started up with an empty cdrom on a<br>
> > vanilla ovirt-3.3.0 vdsm? The script is expect to show only those.<br>
><br>
> It is c6s </p>
<p dir="ltr">Note that the query suggested by Omer had 0 rows. <br>
My further query with 3 results was to show you all rows from vm_static at the moment </p>