cancel
Showing results for 
Search instead for 
Did you mean: 
hiwai
Level 7
Report Inappropriate Content
Message 1 of 8

"failed" return value of system.wakeupAgent

Hi all,

I test system.wakeupAgent API. PC1 is awake, PC2 is just added from ePO system tree by "new system" action. PC3 is Offline. PC4 is not existing on system tree.

I send wakeup agent command through this API to PC1 and PC2,PC3,PC4.

password https://localhost:8443/remote/system.wakeupAgent?names=PC1,PC2,PC3,PC4

OK:

completed: 1

failed: 0

expired: 2

It seems that PC1 is succeeded,

PC2 and PC3 are return Error 0 and "Fail to wakeup agent", PC4 is returned OK and "cannot find the system".

Why the report does not count up "failed" value?

What situation is the result of "failed"?

Thanks,

Hiroshi

7 Replies
hiwai
Level 7
Report Inappropriate Content
Message 2 of 8

Re: "failed" return value of system.wakeupAgent

Does anyone help me?

Re: "failed" return value of system.wakeupAgent

If I am reading your post correctly, it looks like PC1 completed fine, PC2 / 3 timed out (expired) and PC4 did nothing because it wasn't found in ePO. You can always test this by running them individually against the webAPI.

So instead of: https://localhost:8443/remote/system.wakeupAgent?names=PC1,PC2,PC3,PC4

You might try:

https://localhost:8443/remote/system.wakeupAgent?names=PC1

https://localhost:8443/remote/system.wakeupAgent?names=PC2

https://localhost:8443/remote/system.wakeupAgent?names=PC3

https://localhost:8443/remote/system.wakeupAgent?names=PC4

Then see how what the outcome is. I would expect that by now PC2 may respond. I'm not certain but I believe it will still take a while for ePO to recognize the new machine that has been added. Especially if you are adding manually and not letting the agent send the props packets.

Try that and let us know.

hiwai
Level 7
Report Inappropriate Content
Message 4 of 8

Re: "failed" return value of system.wakeupAgent

Thank you for your reply.

I try to access the following URLs and the results are below. Unfortunately the error messages are all Japanese and I tried to change the locale by using option ":locale=en" but I could not. I translate the Japanese messages to English.

https://localhost:8443/remote/system.wakeupAgent?names=PC1

OK:

completed: 1

failed: 0

expired: 0

https://localhost:8443/remote/system.wakeupAgent?names=PC2

Error 0:

Failed to wake up agent

https://localhost:8443/remote/system.wakeupAgent?names=PC3

Error 0:

Failed to wake up agent

https://localhost:8443/remote/system.wakeupAgent?names=PC4

OK:

Could not find the system to wake up. Please input valid computer ID or name.

I feel PC4 case should be returned "Error" and the status should be "failed".

Do you know any other situation to show "fail" status on the wake up agent?

Thanks,

Hiroshi

Re: "failed" return value of system.wakeupAgent

So with PC1 this is the behavior we expect. The command was successful in waking up PC1.

PC2 / PC3 this is also expected behavior. The result that you received it typical. Since the webAPI call could not be completed that is were the "Error 0:" came from.

     The 'failed to wake up agent' portion is the actual response given by the command and not Call function being used to access the site.

Now, PC4 is unique. The command completed. It was returned as "OK:" because the actuall call executed properly.

     The "Could not find the system to wake up. Please input valid computer ID or name." Is what we would expect if the machine does not exist in ePO.

I know it seems a little backwards for PC4 to error out and yet still return OK. But this is expected behavior.

I was able to replicate your results and I am using Powershell with the .Net System.Net.WebClient functions.

Hopefully that helped to alleviate some of the confusion. If not, I will see if I can explain it better.

hiwai
Level 7
Report Inappropriate Content
Message 6 of 8

Re: "failed" return value of system.wakeupAgent

I understand the case of PC4, but 

https://localhost:8443/remote/system.wakeupAgent?names=PC1,PC2,PC3,PC4

OK:

completed: 1

failed: 0

expired: 2

tt should be "completed: 2", I think.

And I have no idea of the status "failed" case. I think "tailed" status may be the error code "Error" except time out. Is there any example situation?

Re: "failed" return value of system.wakeupAgent

Completed will still only show 1 because even though PC4 returns "OK:" it is not actually completing the call.

Since the machine does not exist it cannot complete. It is not a failed call either for the same reason...there is nothing there to fail except the actuall call.

An example of a failed wakeup call would be if the machine exists in ePO more than once... or if more than one machine shares an Agent GUID.

hiwai
Level 7
Report Inappropriate Content
Message 8 of 8

Re: "failed" return value of system.wakeupAgent

Thank you, I understand.

I will try to do your example situation.

Thanks,

Hiroshi