[ovirt-users] problems with events.list

Fabrice Bacchella fabrice.bacchella at orange.fr
Wed May 3 11:22:15 UTC 2017


Ok, got it. The good syntax is host.name=ng319 and type=885 or type=839 or type=886 or type=887. 

Using the search bar (thanks Ondra), it easier to test.


> Le 3 mai 2017 à 13:06, Fabrice Bacchella <fabrice.bacchella at orange.fr> a écrit :
> 
> I'm looking for some specific events with the following code:
> 
>    last_event = int(events_service.list(max=1)[0].id)
>    print "last_event %d" % last_event
>    ....
>    start an check upgrade
>    ....
> 
>    print "search %s" % search
>    while True:
>        founds = events_service.list(
>            from_= last_event + 1,
>            search=search,
>        )
>        if len(founds) > 0:
>            break
>        time.sleep(wait)
> 
> 
> If search is host.name=..., it works.
> With search host.id=..., it can't find any events.
> 
> I was unable to find a filter for the events :
> host.name=XXX and (type=885 or type=839 or type=886 or type=887)
> host.name=XXX and (code=885 or code=839 or code=886 or code=887)
> host.name=XXX and type=885 or type=839 or type=886 or type=887
> host.name=XXX and code=885 or code=839 or code=886 or code=887
> 
> What should be the right search string ?
> 
> _______________________________________________
> Users mailing list
> Users at ovirt.org
> http://lists.ovirt.org/mailman/listinfo/users



More information about the Users mailing list