-
Notifications
You must be signed in to change notification settings - Fork 23.7k
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
Improve error checking of the bind() call on ipv6 sockets #4108
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jaromil
force-pushed
the
unstable
branch
2 times, most recently
from
July 7, 2017 08:09
feec660
to
8a251cc
Compare
Extend the error check to EPROTONOSUPPORT to which errno is set in certain contexts (especially some containers) and to other error codes which may be reported in more situations, adopting the same list used in the ISC DHCP implementation upon socket() and bind() calls.
lamby
added a commit
to lamby/redis
that referenced
this pull request
Nov 23, 2018
If we encounter an unsupported protocol in the "bind" list, don't ipso-facto consider it a fatal error. We continue to abort startup if there are no listening sockets at all. This ensures that the lack of IPv6 support does not prevent Redis from starting on Debian where we try to bind to the ::1 interface by default (via "bind 127.0.0.1 ::1"). A machine with IPv6 disabled (such as some container systems) would simply fail to start Redis after the initiall call to apt(8). This is similar to the case for where "bind" is not specified: redis#3894 ... and was based on the corresponding PR: redis#4108 ... but also adds EADDRNOTAVAIL to the list of errors to catch which I believe is missing from there. This issue was raised in Debian as both <https://bugs.debian.org/900284> & <https://bugs.debian.org/914354>.
antirez
pushed a commit
that referenced
this pull request
Dec 11, 2018
If we encounter an unsupported protocol in the "bind" list, don't ipso-facto consider it a fatal error. We continue to abort startup if there are no listening sockets at all. This ensures that the lack of IPv6 support does not prevent Redis from starting on Debian where we try to bind to the ::1 interface by default (via "bind 127.0.0.1 ::1"). A machine with IPv6 disabled (such as some container systems) would simply fail to start Redis after the initiall call to apt(8). This is similar to the case for where "bind" is not specified: #3894 ... and was based on the corresponding PR: #4108 ... but also adds EADDRNOTAVAIL to the list of errors to catch which I believe is missing from there. This issue was raised in Debian as both <https://bugs.debian.org/900284> & <https://bugs.debian.org/914354>.
JackieXie168
pushed a commit
to JackieXie168/redis
that referenced
this pull request
Dec 17, 2018
If we encounter an unsupported protocol in the "bind" list, don't ipso-facto consider it a fatal error. We continue to abort startup if there are no listening sockets at all. This ensures that the lack of IPv6 support does not prevent Redis from starting on Debian where we try to bind to the ::1 interface by default (via "bind 127.0.0.1 ::1"). A machine with IPv6 disabled (such as some container systems) would simply fail to start Redis after the initiall call to apt(8). This is similar to the case for where "bind" is not specified: redis#3894 ... and was based on the corresponding PR: redis#4108 ... but also adds EADDRNOTAVAIL to the list of errors to catch which I believe is missing from there. This issue was raised in Debian as both <https://bugs.debian.org/900284> & <https://bugs.debian.org/914354>.
antirez
pushed a commit
that referenced
this pull request
Dec 21, 2018
If we encounter an unsupported protocol in the "bind" list, don't ipso-facto consider it a fatal error. We continue to abort startup if there are no listening sockets at all. This ensures that the lack of IPv6 support does not prevent Redis from starting on Debian where we try to bind to the ::1 interface by default (via "bind 127.0.0.1 ::1"). A machine with IPv6 disabled (such as some container systems) would simply fail to start Redis after the initiall call to apt(8). This is similar to the case for where "bind" is not specified: #3894 ... and was based on the corresponding PR: #4108 ... but also adds EADDRNOTAVAIL to the list of errors to catch which I believe is missing from there. This issue was raised in Debian as both <https://bugs.debian.org/900284> & <https://bugs.debian.org/914354>.
JohnSully
pushed a commit
to Snapchat/KeyDB
that referenced
this pull request
Feb 23, 2019
If we encounter an unsupported protocol in the "bind" list, don't ipso-facto consider it a fatal error. We continue to abort startup if there are no listening sockets at all. This ensures that the lack of IPv6 support does not prevent Redis from starting on Debian where we try to bind to the ::1 interface by default (via "bind 127.0.0.1 ::1"). A machine with IPv6 disabled (such as some container systems) would simply fail to start Redis after the initiall call to apt(8). This is similar to the case for where "bind" is not specified: redis/redis#3894 ... and was based on the corresponding PR: redis/redis#4108 ... but also adds EADDRNOTAVAIL to the list of errors to catch which I believe is missing from there. This issue was raised in Debian as both <https://bugs.debian.org/900284> & <https://bugs.debian.org/914354>.
pulllock
pushed a commit
to pulllock/redis
that referenced
this pull request
Jun 28, 2023
If we encounter an unsupported protocol in the "bind" list, don't ipso-facto consider it a fatal error. We continue to abort startup if there are no listening sockets at all. This ensures that the lack of IPv6 support does not prevent Redis from starting on Debian where we try to bind to the ::1 interface by default (via "bind 127.0.0.1 ::1"). A machine with IPv6 disabled (such as some container systems) would simply fail to start Redis after the initiall call to apt(8). This is similar to the case for where "bind" is not specified: redis#3894 ... and was based on the corresponding PR: redis#4108 ... but also adds EADDRNOTAVAIL to the list of errors to catch which I believe is missing from there. This issue was raised in Debian as both <https://bugs.debian.org/900284> & <https://bugs.debian.org/914354>.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Extend the error check to EPROTONOSUPPORT to which errno is set in
certain contexts (especially some containers) and to other error codes
which may be reported in more situations, adopting the same list used
in the ISC DHCP implementation upon socket() and bind() calls.
Solves issue #3894