Patching Status Automated Report

(imported comment written by tscott91)

Yea, that’s what I was thinking too… Filter out the “completed” and show everything else… Possible?

(imported comment written by Lee Wei)

In the report, you will find only one session relevance statement.

You can change “results” to:

results whose (status of it = bes action status fixed)

Other possible statuses are shown below.

bes action status constrained: bes action status

bes action status download failed: bes action status

bes action status error: bes action status

bes action status evaluating: bes action status

bes action status expired: bes action status

bes action status failed: bes action status

bes action status fixed: bes action status

bes action status invalid signature: bes action status

bes action status irrelevant: bes action status

bes action status locked: bes action status

bes action status offers disabled: bes action status

bes action status pending downloads: bes action status

bes action status pending login: bes action status

bes action status pending message: bes action status

bes action status pending offer: bes action status

bes action status pending restart: bes action status

bes action status postponed: bes action status

bes action status running: bes action status

bes action status unreported: bes action status

bes action status user cancelled: bes action status

bes action status waiting: bes action status

(imported comment written by tscott91)

Lee Wei

In the report, you will find only one session relevance statement.
You can change “results” to:

results whose (status of it = bes action status fixed)

Other possible statuses are shown below.

bes action status constrained: bes action status
bes action status download failed: bes action status
bes action status error: bes action status
bes action status evaluating: bes action status
bes action status expired: bes action status
bes action status failed: bes action status
bes action status fixed: bes action status
bes action status invalid signature: bes action status
bes action status irrelevant: bes action status
bes action status locked: bes action status
bes action status offers disabled: bes action status
bes action status pending downloads: bes action status
bes action status pending login: bes action status
bes action status pending message: bes action status
bes action status pending offer: bes action status
bes action status pending restart: bes action status
bes action status postponed: bes action status
bes action status running: bes action status
bes action status unreported: bes action status
bes action status user cancelled: bes action status
bes action status waiting: bes action status

So if I wanted to show all but “Completed” what would my statement be? I don’t even see “completed” in your list.

Thanks

(imported comment written by Lee Wei)

It would be the same statement for Fixed.

The Console shows Completed for successful Tasks, and

Fixed for successful Fixlets.

(imported comment written by tscott91)

Ok cool but I want to get emailed all BUT the “Fixed” / “completed” so would I use:

results whose (status of it bes action status fixed) or results whose (status of it not = bes action status fixed)

Sorry, I know this is simpleton…

(imported comment written by Lee Wei)

The syntax is:

results whose (status of it != bes action status fixed)

or

results whose (status of it is not bes action status fixed)

(imported comment written by cstoneba)

I need a little help. I removed the “action starts with MS” code, and our cache refresh is 5 minutes, so I changed the code in the report to “5*minute.” However, I am still seeing actions that are ‘constrained’, and also are ‘fixed’, even though the end time of the action isn’t within the last 5 minutes. Also, because of the amount of results this report will return, I will need to make a seperate report for each of our groups. Can the action results be filtered by the value of a managed property so that I only see the actions towards specific groups of assets that I want to see?

server1 42941 BASELINE_ACTION_name Open Fixed 2011-04-14 08:17:33 2011-04-16 20:00:00 2011-04-23 23:59:20 operator

(imported comment written by Lee Wei)

cstoneba

I need a little help. I removed the “action starts with MS” code, and our cache refresh is 5 minutes, so I changed the code in the report to “5*minute.” However, I am still seeing actions that are ‘constrained’, and also are ‘fixed’, even though the end time of the action isn’t within the last 5 minutes.

Please post the sessions relevance that is returning incorrect results.

Also, because of the amount of results this report will return, I will need to make a seperate report for each of our groups. Can the action results be filtered by the value of a managed property so that I only see the actions towards specific groups of assets that I want to see?

The creation method we use to return the BES Action Results is:

results of : bes action result

We can use a different form that will return only results from a set of computers:

result from of : bes action result

So we can add an statements in place of that returns a set of bes computers.

(imported comment written by cstoneba)

… of results of bes actions whose (exists end date of it and now - ((end date of it as string & " " & end time_of_day of it as string & " " & local time zone as string) as time) < 5*minute) ?>

Restrict results:

great, I’ll play around with only showing results from bes computers that contains a specific value of a managed property

(imported comment written by Lee Wei)

Your relevance looks good. I have no idea why the data would be incorrect.

You will need to play with it a little I guess.

(imported comment written by cstoneba)

so let me see if I am understanding this properly. This code will show all actions that have an end time AND now - that endtime is less than 5 minutes. Is that correct?

if so, I have no idea why I am seeing so many action results from this report.

(imported comment written by Lee Wei)

On additional thoughts, the end time comparison does not work well.

The Action End Time is meant for local time zones. So an Action that is intended to end at 10:00PM will actually end at the 10:00PM for different time zones.

Sorry that I did not think this through in the first place.

(imported comment written by cstoneba)

makes sense, but I don’t think mine is a tz issue.

so right now for me it is 4/21/11 at 8:40am, however this is my first result in the report, and now that I think about it, has been there for quite some time (along with hundreds and hundreds of others). I can’t think of any reason why this action would show if my relevance is only suppose to be showing actions with an end time and now-end time < 5minutes

STATE STATUS ISSUED START END

Open Fixed 2011-04-14 08:17:33 2011-04-16 20:00:00 2011-04-23 23:59:20

(imported comment written by Lee Wei)

Chris,

Try this statement instead:

… of results of bes actions whose (
exists end date of it and
now > ((end date of it as string & " " & end time_of_day of it as string & " " & local time zone as string) as time) and
now - ((end date of it as string & " " & end time_of_day of it as string & " " & local time zone as string) as time) < 5*minute
)

(imported comment written by cstoneba)

that looks much better. I did a test action and had it stop 3 minutes out, and it was the only action that showed up in the report, so that’s good. Would the schedule trigger relevance be the same as your original code, or would it be modified too?

(imported comment written by Lee Wei)

Yes, we need to use the same constrains for the trigger statement as well.

(imported comment written by cstoneba)

thanks for your help Lee.

(imported comment written by Lee Wei)

I have updated the download file with the latest and correct filter statements. Thanks for being persistent in tracking this down.

(imported comment written by tscott91)

Lee Wei

The syntax is:

results whose (status of it != bes action status fixed)

or

results whose (status of it is not bes action status fixed)Lee, just now getting around to editing this… So I’m guessing the code I need to edit is below but not sure what I need to change… I’d like to filter OUT: Fixed and Not Relevant and then display the rest. I don’t want to jack the report so was hoping you can edit the code below for me. Thanks

results of bes actions whose (exists end date of it and name of source fixlet of it starts with “MS” and now > ((end date of it as string & " " & end time_of_day of it as string & " " & local time zone as string) as time) and now - ((end date of it as string & " " & end time_of_day of it as string & " " & local time zone as string) as time) < 7*day) ?>

(imported comment written by Lee Wei)

Please try this:

results

color=red

whose (status of it !=bes action status fixed and relevant flag of results (computer of it , source fixlet of action of it))[/color] of bes actions whose (exists end date of it and name of source fixlet of it starts with “MS” and now > ((end date of it as string & " " & end time_of_day of it as string & " " & local time zone as string) as time) and now - ((end date of it as string & " " & end time_of_day of it as string & " " & local time zone as string) as time) < 7 * day)