Linking actions to completion of other actions

(imported topic written by MartinZ91)

Hi everyone

We have several actions which run for hours (mostly waiting for something external on the target computer). We do not want to have more then one target computer in a group running this action due to ressource limits. This could be done of course by just activating the action on one target and wait for its completion and than activate the next action and so on. Or activate several of them with start time constraints in “advanced task options”.

Is there a chance to link an action to the completion (or failure) of another action? This would avoid the potentially long idle time between 2 actions, if the first action stops early, before the start time constraint of the next action is not jet reached.

I tried to write an action with a parameter query asking for the ID of the action to wait for and substituting the user response to some relevance in this action. But, it didn’t work.

Here is the action part of the task, which is not working as expected (it returns “failed” all the time):

===

action parameter query “link_action” with description “wait for action with ID=”

if {constrained of action of {parameter “link_action” of action}}

// do not do the action, just wait

else

// do the action

endif

===

any help appriciated

regards, Martin

(imported comment written by BenKus)

Hi Martin,

Is your question regarding waiting for actions on the same computer or on multiple computers?

If you mean on the same computer, the easiest thing to do is put all the Fixlets in a Baseline, which will create an ordered action.

If you mean on multiple computers, this is very hard to do because the BES Agents are in charge of starting the action and they don’t have any data about the other BES Agents. There really isn’t an easy way to do this without a fair amount of work writing files to shared locations and then inspecting the files.

Ben

(imported comment written by MartinZ91)

Ben,

Thanks for this answer. My question really was about linking actions on different computers. Ok, the BESClients don’t have knowledge of each other, so they cannot find out the state of another action/operation. Is the purpose of the constrained <…> inspector to link actions on the same computer? I think a baseline would be a better solution to this.

The BESconsole get’s notified with client status reports about completion of actions, so in principal it could be possible to trigger some kind of “action” on reception of this state change - but I agree that’s be beyond the scope of a patch management system.

I’ll check if I can used shared filesystems somewhere in our deployment to get the required behavior of linked actions

regards, Martin

(imported comment written by jessewk)

Hi Martin,

BigFix is really much more than just a patch management system and your goal is not outside the scope of possibilities. It’s simply that our architecture is a top-down tree while what you are trying to accomplish is peer-to-peer, which is slightly unnatural for us.

That said, we have done a number of custom implementations that enable clients to send notification of action completion and thus trigger subsequent actions on different computers. The details of the implementation really depend on your network architecture and the specifics of your project. We could certainly help you accomplish your goals through professional services. If you don’t mind posting specific details of your project and network, than we can also try to help out here.

I’ll start with a few questions:

  1. What is the network relationship between these machines? Are they geographically dispersed or are they in the same subnet? Do they use the same relay?

  2. What operating system are the clients?

  3. Is there a defined order or do you care only that one machine at a time is running the action?

  4. Does any data need to transfer between the machines other than triggering the action to start on the next machine?

-Jesse