`ping` node error. Can someone make sense of it?

Oh, you scoller! :wink:

I think I did that, and I lost information. Can't be sure. But it had me spinning for a while and then I realised (bad use of words I know) that I had to make it as I have it so it is compatible with the code I had already written for the advanced-ping node. Though had to change msg.host to msg.payload for the new ping node.

That had me stumped for a while too.

When I was not getting anything out of the ping node, I looked at the messages and saw they were sending it as msg.host.

I changed it to msg.payload and things started to work, but then other wheels fell off with missing message parts - which lead to me asking.

I may have to try it again tomorrow and see what I get.
Push coming to shove, if I get enough of the right data out, I will modify the other code. Obviously.

Thanks.

I'll report back with results when I get into it in the next session.

I have just made the test flow as shown.

Now the only problem is I can't resolve the actual ping result.
Usually the PING time or false if not contactable.

Where is that part?
(I need to go to spec' savers!)

Isn't it the msg.payload?

I was editing the reply. (Didn't think I'd get a reply that quick.)

No. Alas in my code it was addr. I changed it to payload that didn't work.

But looking at what @Steve-Mcl said: It has to be host.
I'll confirm that beyond belief but that seems a bit inconsistent with how the node expects inputs.
Changing from payload to hosts.

In the returned msg.payload I just get (got) false to everything.

I just checked.

Yes, if sending an array it must be host to get a ping reply.

ARGH!

It is payload but it is payload.host I think.

I have it working now.

Thanks.
I originally didn't have the host part in the message I was sending.

Not really. It can be a string or an object in the array. but if you send an object, then the node needs to know what you want to ping. It just so happens to want you to put the host name or IP in the property host

1 Like

Yeah... (You know.....) Silly me.

I am now rolling that out to the 4 machines I have online now and shall get around to rolling it out to all machines soon.

I just want to get that other problem I have fixed first. (That's another story)

Thanks though. I really need to learn to read everything and actually understand it.
There are times when I can look but not see.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.