Jump to content

YoLink Node server taking 10X resources of other node servers


sjenkins
Go to solution Solved by Panda88,

Recommended Posts

First, I really love this node server, but I just did an HTOP on my Polisy and wow there seems to be something going on here in this node server that isn't right.  Attached are two runs of HTOP with the YoLink Node server running and stopped ( I think you can figure out which is which).  Anyone else having this issue?

 

Screenshot 2022-12-11 at 5.34.56 PM.png

Screenshot 2022-12-11 at 5.34.00 PM.png

Link to comment
21 minutes ago, Panda88 said:

I'll take a look

How many devices have you installed?  

Do you know if Memory increases over time?

 

 

17 devices for 18 nodes total.

don't think I'm seeing memory build over time as the Polisy is stable but it is slowing down the whole ISY. 

 

Link to comment
2 minutes ago, Panda88 said:

Each device is really a node server by itself - I'll see if there is something obvious wrong but it may take some time to get to the bottom of it 

Appreciate that. I am assuming you are not seeing this kind of cpu usage though?

Link to comment

I did not study the CPU usage in great detail - I am in the progress of changing the message handling approach - It used to be every device was waiting for input from a queue - I am changing that to start a thread when a message arrives - I think that will lower the CPU usage

I cannot think of anything else causing a lot of CPU usage - unless you are using the delay timers 

Link to comment
13 hours ago, Panda88 said:

I did not study the CPU usage in great detail - I am in the progress of changing the message handling approach - It used to be every device was waiting for input from a queue - I am changing that to start a thread when a message arrives - I think that will lower the CPU usage

I cannot think of anything else causing a lot of CPU usage - unless you are using the delay timers 

agree I have not looked at cpu usage much at all ; I pulled up HTOP as it seemed like my ISY was a bit laggy.  Which is when I found this issue.

  I am not using the delay timers.  Any thoughts on short poll long poll as a mitigation until you do your change  to the message handling approach?

 

Link to comment

Polls are not truly needed - MQTT updates when actions happen - short poll is mostly to send a heart beat

there are cases where an update takes longer so the state has not changed when the display updates on the Admin Console - in this special case the poll causes the display to update - Not if using programs this does not matter 

  • Like 1
Link to comment

I see the same issue - not sure what causes it (yet)

My new release in testing does not see the issue, but I have far fewer devices on my test platform 

Polls are not truly needed - MQTT updates when actions happen - short poll is mostly to send a heartbeat

there are cases where an update sometimes takes longer so the state has not changed when the display updates on the Admin Console - in this special case the poll causes the display to update - Not if using programs this does not matter 

 

Link to comment

Just a quick update - I checked my latest code and it does not show this behavior. 

I'll work towards releasing that - and maybe figure out what is causing the strange behavior - there must be an infinite loop somewhere but not easy to debug on the  Polisy platform as I have no development tools there

 

Edited by Panda88
  • Like 2
Link to comment

ok, so the reinstall will work from the store page but not from the purchase page ; not sure if that is particular to your NS or a PG3 issue.  The auto update with a node reset would not work even after I did a PG3 reset (did NOT try a full POLISY reboot)

anyway the YoLink NS is back up and running doing a re-install and I did check HTOP ; all is well.

I will mark as solved and leave these other issues as they were not part of the high CPU usage issue.

Thanks so much @Panda88!! 

Link to comment
15 hours ago, sjenkins said:

ok, so the reinstall will work from the store page but not from the purchase page ; not sure if that is particular to your NS or a PG3 issue.  The auto update with a node reset would not work even after I did a PG3 reset (did NOT try a full POLISY reboot)

anyway the YoLink NS is back up and running doing a re-install and I did check HTOP ; all is well.

I will mark as solved and leave these other issues as they were not part of the high CPU usage issue.

Thanks so much @Panda88!! 

Are you PG3 3.1.16 or something a little older?  Starting with 3.1.16, the re-install from the purchase page and the store should work exactly the same.  Prior versions would fail from the purchase page if it didn't know which purchase option you had originally made.

When the ability to support multiple versions of a node server was introduced, it made it difficult for PG3 to determine which  version had been installed previously.  The result is that things like auto-update can't always figure out what version should be used to update.  When you do a re-install, you have to manually select which version to install so there's no guesswork on PG3's part.

In your case, it looks like the auto update failed because something was modified in the node server directory that cause the deploy method to fail.  That's probably a node server issue if it is modifying files that shouldn't be modified.

Link to comment
19 hours ago, bpwwer said:

Are you PG3 3.1.16 or something a little older?  Starting with 3.1.16, the re-install from the purchase page and the store should work exactly the same.  Prior versions would fail from the purchase page if it didn't know which purchase option you had originally made.

When the ability to support multiple versions of a node server was introduced, it made it difficult for PG3 to determine which  version had been installed previously.  The result is that things like auto-update can't always figure out what version should be used to update.  When you do a re-install, you have to manually select which version to install so there's no guesswork on PG3's part.

In your case, it looks like the auto update failed because something was modified in the node server directory that cause the deploy method to fail.  That's probably a node server issue if it is modifying files that shouldn't be modified.

@bpwwer I'm on 3.1.15 with ISY 5.4.5 as well.  Have been holding a couple days on my POLISY update until the firmware stabilised with the new board.  So sounds like from your description that will be the issue, appreciate the explanation.  I will likely hit the button today once I get read up on the current Matter board procedure. 

Link to comment

@sjenkinsYou should be able to do re-installs via the node server store, select the node server, select install for the purchase option and then you have the option to re-install to the same slot it is currently installed in.

From the purchases page, it tries to guess what you would select in the last step above and will fail a lot of time.  3.1.16 changes the re-install on the purchases page to follow the same steps as the process from the node server store.

  • Thanks 1
Link to comment
Guest
This topic is now closed to further replies.

  • Recently Browsing

    • No registered users viewing this page.
  • Who's Online (See full list)

    • There are no registered users currently online
  • Forum Statistics

    • Total Topics
      36.5k
    • Total Posts
      367.6k
×
×
  • Create New...