<div dir="ltr">Thanks!!! Just what I needed!<br></div><div class="gmail_extra"><br><div class="gmail_quote">2015-01-07 14:19 GMT+01:00 Juan Hernández <span dir="ltr"><<a href="mailto:jhernand@redhat.com" target="_blank">jhernand@redhat.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 01/07/2015 02:05 PM, Koen Vanoppen wrote:<br>
> Thanks. But, is there no other way, besides screwing around in the database?<br>
><br>
<br>
</span>You can use the Python SDK:<br>
<br>
#!/usr/bin/python<br>
<br>
import ovirtsdk.api<br>
import ovirtsdk.xml<br>
<br>
api = ovirtsdk.api.API(<br>
url="<a href="https://engine.example.com/ovirt-engine/api" target="_blank">https://engine.example.com/ovirt-engine/api</a>",<br>
username="admin@internal",<br>
password="******",<br>
ca_file="/etc/pki/ovirt-engine/ca.pem"<br>
)<br>
<br>
alerts = api.events.list(query="severity=alert")<br>
for alert in alerts:<br>
alert.delete()<br>
<br>
api.disconnect()<br>
<span class=""><br>
<br>
> 2015-01-07 13:07 GMT+01:00 Eli Mesika <<a href="mailto:emesika@redhat.com">emesika@redhat.com</a><br>
</span>> <mailto:<a href="mailto:emesika@redhat.com">emesika@redhat.com</a>>>:<br>
<span class="">><br>
><br>
><br>
> ----- Original Message -----<br>
> > From: "Koen Vanoppen" <<a href="mailto:vanoppen.koen@gmail.com">vanoppen.koen@gmail.com</a><br>
</span><span class="">> <mailto:<a href="mailto:vanoppen.koen@gmail.com">vanoppen.koen@gmail.com</a>>><br>
> > To: <a href="mailto:users@ovirt.org">users@ovirt.org</a> <mailto:<a href="mailto:users@ovirt.org">users@ovirt.org</a>><br>
> > Sent: Wednesday, January 7, 2015 7:42:25 AM<br>
> > Subject: [ovirt-users] Alerts<br>
> ><br>
> > Hi All,<br>
> ><br>
> > We recently had a major crash on our ovirt environment due a<br>
> strange bug (has<br>
> > been reported in the meanwhile).<br>
> ><br>
> > But now we are left we a bunch of aerts (+100) that are still standing<br>
> > there... Is there a way I can flush them manually from command<br>
> line or so?<br>
> > Because the right click+clear all, doesn't seem to work that<br>
> good... :-).<br>
><br>
> If you want to remove ALL alerts run from command line<br>
><br>
> psql -U engine -c "delete from audit_log where severity = 10;" engine<br>
><br>
> NOTE:<br>
> Keep in mind that before any manual operation on your database you<br>
> should backup it first.<br>
><br>
> ><br>
> > Kind regards,<br>
> ><br>
> > Koen<br>
> ><br>
> > _______________________________________________<br>
> > Users mailing list<br>
</span>> > <a href="mailto:Users@ovirt.org">Users@ovirt.org</a> <mailto:<a href="mailto:Users@ovirt.org">Users@ovirt.org</a>><br>
> > <a href="http://lists.ovirt.org/mailman/listinfo/users" target="_blank">http://lists.ovirt.org/mailman/listinfo/users</a><br>
<div class="HOEnZb"><div class="h5">> ><br>
><br>
><br>
><br>
><br>
> _______________________________________________<br>
> Users mailing list<br>
> <a href="mailto:Users@ovirt.org">Users@ovirt.org</a><br>
> <a href="http://lists.ovirt.org/mailman/listinfo/users" target="_blank">http://lists.ovirt.org/mailman/listinfo/users</a><br>
><br>
<br>
<br>
</div></div><span class="HOEnZb"><font color="#888888">--<br>
Dirección Comercial: C/Jose Bardasano Baos, 9, Edif. Gorbea 3, planta<br>
3ºD, 28016 Madrid, Spain<br>
Inscrita en el Reg. Mercantil de Madrid – C.I.F. B82657941 - Red Hat S.L.<br>
</font></span></blockquote></div><br></div>