For Linux

To display the timeout value, enter:

/sbin/sysctl -e net.ipv4.tcp_keepalive_time

To reduce the timeout period to 15 minutes (900 seconds,) enter:

/sbin/sysctl -w net.ipv4tcp_keepalive_time=900