Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oamYm-0001Xa-Dh for pgsql-general@arkaria.postgresql.org; Tue, 20 Sep 2022 23:21:48 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oamYl-00078s-66 for pgsql-general@arkaria.postgresql.org; Tue, 20 Sep 2022 23:21:47 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oamYk-00078j-RD for pgsql-general@lists.postgresql.org; Tue, 20 Sep 2022 23:21:46 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oamYi-0003mk-Ml for pgsql-general@lists.postgresql.org; Tue, 20 Sep 2022 23:21:45 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 28KNLhvF934613; Tue, 20 Sep 2022 19:21:43 -0400 From: Tom Lane To: Rob Sargent cc: "pgsql-generallists.postgresql.org" Subject: Re: tcp settings In-reply-to: <58e221af-b764-61ae-6337-a2aa2fead8a2@gmail.com> References: <58e221af-b764-61ae-6337-a2aa2fead8a2@gmail.com> Comments: In-reply-to Rob Sargent message dated "Tue, 20 Sep 2022 14:05:46 -0600" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <934611.1663716103.1@sss.pgh.pa.us> Date: Tue, 20 Sep 2022 19:21:43 -0400 Message-ID: <934612.1663716103@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Rob Sargent writes: > I'm wondering if there's a disconnect between my servers postgresql.conf > and the system tcp settings? Are the config names supposed to match a > file in /proc/sys/net/ipv4? Probably not --- we certainly didn't pick them with the intention of matching any specific system's naming of the options. On my Linux box it looks like the related files are named /proc/sys/net/ipv4/tcp_keepalive_XXX But in any case, if this is your problem: > My issue is that psql is timing out with "SSL SYSCALL error: Connection > timed out". then keepalives aren't necessarily the solution anyway. When is this failure occurring ... is it while trying to establish the database connection in the first place? Or does it only happen if you've left the psql session sit idle for a long while? regards, tom lane