Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please add client ID in timeout log message #505

Open
HansBorjes opened this issue May 1, 2024 · 3 comments
Open

Please add client ID in timeout log message #505

HansBorjes opened this issue May 1, 2024 · 3 comments

Comments

@HansBorjes
Copy link

Is your feature request related to a problem? Please describe.
From time to time I find situations like this in my log files.

modbus.0
2024-05-01 09:38:54.986 warn Poll error count: 1 code: {"err":"timeout","timeout":5000}

modbus.0
2024-05-01 09:38:54.981 error Client in error state.

modbus.0
2024-05-01 09:38:54.980 error Request timed out.

modbus.0
2024-05-01 09:38:54.977 warn Error: undefined

Describe the solution you'd like
Please add the ID of the device not responding to the log file.

Describe alternatives you've considered
I have hacked the code myself to add this info. Obviously on the next SW update my patch is gone. :-)

Additional context
I suspect that one device in my network has hardware issues and want to isolate that quickly.

@Apollon77
Copy link
Contributor

Please check version I publish in some minutes

@HansBorjes
Copy link
Author

Thanks a lot for giving it a try! I installed your version. Now it may take some time (1-2 weeks maybe) for the errors to appear again. I will have a look in the log files regularly now.

starting. Version 6.2.3 (non-npm: ioBroker/ioBroker.modbus) in /opt/iobroker/node_modules/iobroker.modbus, node: v18.20.3, js-controller: 5.0.19

@HansBorjes
Copy link
Author

@Apollon77 your version seems to do what it is supposed to do. Thanks!

Can you maybe add a hint like "client ID"?

Interestingly this time it is not caused by a specific client. It seems random. Maybe my bus timing is too challenging.

modbus.0 2024-05-31 16:59:57.200 warn [11] Poll error count: 1 code: {"err":"timeout","timeout":5000}
modbus.0 2024-05-31 16:59:57.197 error Client in error state.
modbus.0 2024-05-31 16:59:57.197 error Request timed out.
modbus.0 2024-05-31 16:59:57.196 warn Error: undefined

GermanBluefox added a commit that referenced this issue Aug 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants