[ovirt-users] problems with events.list

Fabrice Bacchella fabrice.bacchella at orange.fr
Wed May 3 11:06:54 UTC 2017


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 ?



More information about the Users mailing list