-
Notifications
You must be signed in to change notification settings - Fork 18
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
exporter panics at irregular intervals due to rand.NewSource not being safe for concurrent use #22
Comments
Thanks for letting us know, please send in a PR once all the upstream has the fix. |
@brian-brazil - this is not going very well :( The owner of https://github.com/envimate/nrpe no longer wishes to maintain the repo and has tried to hand it off to someone, but it has been 22 days and no response. Also I suspect that aperume may have noticed this conversation because some time in the last 22 days https://github.com/aperum/nrpe was deleted. Would anyone from RobustPerception be interested in taking this on? I would love to but I am an absolute beginner at Go and I suspect I would not do a very good job. |
That's not good news. If @aperum upstream has disappeared, then we either need a new upstream or to copy the code in here. We don't actively use this code ourselves, but can provide code review. |
Actually i wasn't aware that anyone is using this. I haven't used it in ages and so "garbage collected" it a few weeks ago. |
Sorry for intruding on this repo's issue, but does anyone have a link to a fork of that nrpe repo? I use it in a small go program and using go mods without a corresponding repo isn't terribly ideal :) |
I am using the nrpe_exporter (https://github.com/RobustPerception/nrpe_exporter) to make about 4500 nrpe client requests every 70s. A few times a day at irregular intervals (typically hours, but sometimes minutes) the nrpe_exporter crashes with the following error:
Note the line numbers may be a little off, because we have applied a couple of patches to suit our local environment.
I believe we see this error because rand.NewSource is not safe for concurrent use, which I found documented at https://pkg.go.dev/math/rand. I have opened a PR to address this issue upstream here envimate/nrpe#3. I think in an ideal world I will get this fixed there and then after merge get that pulled into https://github.com/aperum/nrpe and then finally here.
I am opening this issue so that anyone else that runs into this problem whilst using the nrpe_exporter can benefit from what I have found out so far. Also because both nrpe projects have had no activity for over four years. So perhaps we will find that in order to get this fix into nrpe_exporter we need a new fork off aperum/nrpe.
The text was updated successfully, but these errors were encountered: