Skip to content

[kernel] Prevent net_kernel from being blocked on connection setup #10029

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

Conversation

rickard-green
Copy link
Contributor

@rickard-green rickard-green commented Jul 5, 2025

net_kernel could be blocked for a very long time when selecting distribution module for a connection if the DNS service was slow. This prevented any new connections to be set up during that time.

@rickard-green rickard-green added team:VM Assigned to OTP team VM fix testing currently being tested, tag is used by OTP internal CI labels Jul 5, 2025
Copy link
Contributor

github-actions bot commented Jul 5, 2025

CT Test Results

    2 files     71 suites   1h 7m 21s ⏱️
1 595 tests 1 337 ✅ 258 💤 0 ❌
1 847 runs  1 531 ✅ 316 💤 0 ❌

Results for commit 838d263.

♻️ This comment has been updated with latest results.

To speed up review, make sure that you have read Contributing to Erlang/OTP and that all checks pass.

See the TESTING and DEVELOPMENT HowTo guides for details about how to run test locally.

Artifacts

// Erlang/OTP Github Action Bot

@rickard-green rickard-green force-pushed the rickard/net-kernel-connect-fix/ERIERL-1241/OTP-19702 branch 2 times, most recently from 75a0a2a to 622df04 Compare July 5, 2025 17:52
@rickard-green rickard-green removed the testing currently being tested, tag is used by OTP internal CI label Jul 6, 2025
@rickard-green rickard-green force-pushed the rickard/net-kernel-connect-fix/ERIERL-1241/OTP-19702 branch from 622df04 to 888600b Compare July 7, 2025 14:41
@rickard-green rickard-green added the testing currently being tested, tag is used by OTP internal CI label Jul 7, 2025
@rickard-green rickard-green force-pushed the rickard/net-kernel-connect-fix/ERIERL-1241/OTP-19702 branch 3 times, most recently from 6df5690 to e27a43d Compare July 8, 2025 19:24
@rickard-green rickard-green requested a review from jhogberg July 8, 2025 21:00
@rickard-green rickard-green force-pushed the rickard/net-kernel-connect-fix/ERIERL-1241/OTP-19702 branch 2 times, most recently from 89d7a9f to 68a6083 Compare July 9, 2025 10:28
jhogberg
jhogberg previously approved these changes Jul 9, 2025
…' into rickard/net-kernel-connect-fix/ERIERL-1241/OTP-19702

* rickard/net-kernel-connect-fix/25/ERIERL-1241/OTP-19702:
  [kernel] Prevent net_kernel from being blocked on connection setup
@rickard-green rickard-green force-pushed the rickard/net-kernel-connect-fix/ERIERL-1241/OTP-19702 branch from 68a6083 to 838d263 Compare July 9, 2025 12:57
@rickard-green rickard-green requested a review from jhogberg July 9, 2025 13:52
rickard-green added a commit to rickard-green/otp that referenced this pull request Jul 11, 2025
FD_SETSIZE increased from 64 to 1024.

The change in erlang#10029 (OTP-19702) caused maximum amount of open connections
for epmd to be reached for some test cases connecting a large amount of nodes
at the same time. This since selection of dist module was parallelized
which caused more "port please" requests to be issued in parallel to epmd.
@rickard-green rickard-green force-pushed the rickard/net-kernel-connect-fix/ERIERL-1241/OTP-19702 branch from f6679d9 to 838d263 Compare July 11, 2025 09:51
@nyczol
Copy link

nyczol commented Jul 14, 2025

Hello,

Could we add this fix to OTP-27.3.4.X also?

Regards
Aleksander Nycz

@rickard-green
Copy link
Contributor Author

@nyczol Yes most likely, unless some unexpected issues pop up in testing.

@rickard-green rickard-green merged commit b6625e9 into erlang:maint Jul 17, 2025
43 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix team:VM Assigned to OTP team VM testing currently being tested, tag is used by OTP internal CI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants