-
-
Notifications
You must be signed in to change notification settings - Fork 362
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
Segmentation fault in stats.c:404 #782
Comments
yes, now i'm shure that's problem with socket who has num 1024 and more. A litle bit "why" about it i found here https://stackoverflow.com/a/20997117 |
select() has limit for 1024 file descriptors and it's affect big installation. More information in issue NLnetLabs#782
The fix has the suggested code, with some changes. The change allows the function to continue to ignore EINTR and EAGAIN while waiting for the file descriptor. Also, the function pollit is fixed for the same issue of an fd larger than 1024, it seems to not cause a problem for you, but it has the same issue with fd_set. Thanks for the detailed report and suggested fix! The previously referenced commit is fine, it causes the problem to show up, because it calls the tube functions, but the fix in the tube wait function is the right fix to have. |
* nlnet/master: - Updates for NLnetLabs#461 (Add max-query-restarts option). - Expose 'max-sent-count' as a configuration option; the default value retains Unbound's behavior. - Expose 'statistics-inhibit-zero' as a configuration option; the default value retains Unbound's behavior. - Fix to wrap Makefile scripts directory in quotes for uninstall. Changelog note for NLnetLabs#808 - Merge NLnetLabs#808: Wrap Makefile script's directory variables in quotes. wrap directory variables in quotes Fix date. - Fix NLnetLabs#773: When used with systemd-networkd, unbound does not start until systemd-networkd-wait-online.service times out. - Clear documentation for interactivity between the subnet module and the serve-expired and prefetch configuration options. - Add SVCB and HTTPS to the types removed by 'unbound-control flush'. - Fix NLnetLabs#782: Segmentation fault in stats.c:404. Changelog entry for NLnetLabs#720 Document max-query-restarts option Use max-query-restarts in iterative resolver Add max-query-restarts to grammar and lexer Add max-query-restarts config parameter
Describe the bug
Hello ✋
After this commit 57230d7 my unbound installation began to fall with Segmentation fault. After debug with gdb i get place with segfault
I caught problem with new function which uses select for wait responce from socket. I read that this method has limit on how many description may have been selected and one more limit that method(
FD_SET
structure) can't work withfd
description which has num more 1024 (it's something historicaly, i don't know why). And on my installation i have this problem. I wrote simple function on poll:and changed old function in this line on new function.
And it's working fine for me. I haven't expirence and testing with Windows for change this place and therefore it's not PR
To reproduce
Steps to reproduce the behavior:
interface:
multiple time on different ip (i have 7)num-threads:
in something big (i set 64)System:
unbound -V
output:The text was updated successfully, but these errors were encountered: