You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The issue #538 introduced a warning in the README about the Docker Swarm IPVS LB that timeouts TCP connections after 900 secs, which is lower than tcp_keepalive_time, so idle connections might become unavailable (cut by IPVS) while still being needed later, and that warning have since been removed (docker-library/docs@5e28015), probably due to the link being broken.
Could it be possible to reintroduce a warning about this, and/or to propose a default -ctcp_keepalives_idle=870 value (for example; and maybe tcp_keepalives_interval+tcp_keepalives_count)?
connect to postgres without the LB using tasks.<service_name>
client must resolve on each connection in case the IP changed
use endpoint_mode: dnsrr to prevent using the LB
client must resolve on each connection in case the IP changed
use net.ipv4.tcp_keepalive_time: 870 (<900)
use -ctcp_keepalives_idle=870 (<900)
Example of all solutions (only one needed):
services:
postgres:
command:
- postgres
- -ctcp_keepalives_idle=300 # < 900# Maybe this too ?# - -ctcp_keepalives_interval=30# - -ctcp_keepalives_count=5sysctls:
net.ipv4.tcp_keepalive_time: 720# < 900deploy:
endpoint_mode: dnsrr # The client should resolve on each connection in case the task (IP) changedmy_other_service:
environment:
POSTGRES_HOST: tasks.postgres # The client should resolve on each connection in case the task (IP) changed
The text was updated successfully, but these errors were encountered:
The issue #538 introduced a warning in the README about the Docker Swarm IPVS LB that timeouts TCP connections after 900 secs, which is lower than
tcp_keepalive_time
, so idle connections might become unavailable (cut byIPVS
) while still being needed later, and that warning have since been removed (docker-library/docs@5e28015), probably due to the link being broken.Could it be possible to reintroduce a warning about this, and/or to propose a default
-ctcp_keepalives_idle=870
value (for example; and maybetcp_keepalives_interval
+tcp_keepalives_count
)?The old "success" documentation is visible at https://web.archive.org/web/20200611114911/https://success.docker.com/article/ipvs-connection-timeout-issue.
Possible solutions are:
tasks.<service_name>
endpoint_mode: dnsrr
to prevent using the LBnet.ipv4.tcp_keepalive_time: 870
(<900
)-ctcp_keepalives_idle=870
(<900
)Example of all solutions (only one needed):
The text was updated successfully, but these errors were encountered: