Network Disconnects Due to Perceived Inactivity¶
When running a SQL statement that takes a long time to finish (when doing a data load through copy/external table or running a query that is taking a long time to return results), you receive an “idle connection” message or notice that your connection seems to have hung.
You must keep your TCP connection alive by increasing the TCP keepalive length.
Actian clients such as the Actian SQL CLI or applications that use the ODBC/JDBC driver establish a connection to the Actian Data Platform using standard TCP/IP. When you run some SQL commands that could take a long time, especially commands related to data loading such as CREATE TABLE
TCP provides a mechanism to address this called “TCP keepalive.” It involves sending benign keepalive probes at predefined intervals to signal that the connection is alive and waiting for a response from the server. This is usually enabled by default on most system, but the interval is typically about two hours, which is usually very high for most NAT proxies/firewalls.
For , we recommend that you lower this value to 60 seconds. This is done differently for various operating systems as follows.
Windows
Set or update the following Windows registry key:
This is a REG_DWORD that expects time in milliseconds.
Set it to 60000 (Decimal) or ea60 (Hexadecimal).
You must reboot your machine for the change to take effect.
Linux
In /etc/sysctl.conf as root, set the following:
No reboot is necessary. Run the following command to enact the changes:
macOS
Note
Changing the keepalive setting does not work on macOS Catalina (10.15) for a version that is less than 10.15.4.
As root, run the following to change values immediately:
To make the values persistent across reboots, edit /etc/sysctl.conf and add:
No reboot is necessary.