Re: timescaledb vs NULL vs pg_timeseries vs partman + pgcron + pg_ivm

2025-04-09 Thread Amitabh Kant
On Wed, Apr 9, 2025 at 11:50 AM Achilleas Mantzios - cloud < a.mantz...@cloud.gatewaynet.com> wrote: > > On 4/9/25 04:50, Amitabh Kant wrote: > > Thank you, I meant the paid/supported service not the community version. >> Which of the two do you use? >> >> >> I use the community version. > > > On

Re: Interesting case of IMMUTABLE significantly hurting performance

2025-04-09 Thread Olleg Samoylov
On 10.04.2025 01:08, Tom Lane wrote: Yeah. The assumption is that you had a reason for marking the function IMMUTABLE and you want the planner to treat it that way even if it isn't really. (There are valid use-cases for that, for instance if you want calls to the function to be constant-fold

Re: FW: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Adrian Klaver
On 4/9/25 12:23, Abraham, Danny wrote: Thanks again. Here is the example: dba-tlv-x6y64k% cat pg_hba.conf # TYPE DATABASEUSERCIDR-ADDRESS METHOD local all all trust hostall all 0.0.0.0/0 scram-s

Re: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread David G. Johnston
On Wed, Apr 9, 2025, 12:21 Abraham, Danny wrote: > Thanks again. > Here is the example: > > dba-tlv-x6y64k% cat pg_hba.conf > # TYPE DATABASEUSERCIDR-ADDRESS METHOD > local all all trust > hostall all 0.0.0

Re: Interesting case of IMMUTABLE significantly hurting performance

2025-04-09 Thread Adrian Klaver
On 4/9/25 14:21, Nico Williams wrote: On Wed, Apr 09, 2025 at 10:50:00PM +0200, Laurenz Albe wrote: The IMMUTABLE function cannot be inlined because to_char() is not IMMUTABLE. Q: Why would to_char() not be IMMUTABLE? A: Because it makes use of locales, and I guess the guc-timezone GUC, w

Re: Interesting case of IMMUTABLE significantly hurting performance

2025-04-09 Thread Tom Lane
"David G. Johnston" writes: > On Wed, Apr 9, 2025 at 1:50 PM Laurenz Albe > wrote: >> The IMMUTABLE function cannot be inlined because to_char() is not >> IMMUTABLE. > So, the punishment for lying about the volatility of one's function is to > prohibit it from being inlined even in a case where

RE: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Abraham, Danny
Thanks a lot. As you mentioned , I have not cleared the environment vars prior to the call. ==> dba-tlv-x6y64k% cat d2 unsetenv PGPORT unsetenv PGSYSCONFDIR unsetenv PGUSER unsetenv PGDATABASE unsetenv PGSERVICE unsetenv PGHOST psql -Upostgres -p5548 -dpostgres dba-tlv-x6y64k% source d2 psql (1

Re: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Adrian Klaver
On 4/9/25 13:40, Abraham, Danny wrote: Thanks again. 1. No other PG instances on this Linux machine. 2. RHEL9 3. Our compiled PG which is embedded within our product/site 4. I am not aware of an env variable that changes the top down matching on pg_hba.conf From here: https://www.post

RE: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Abraham, Danny
Thanks again. 1. No other PG instances on this Linux machine. 2. RHEL9 3. Our compiled PG which is embedded within our product/site 4. I am not aware of an env variable that changes the top down matching on pg_hba.conf Danny From: David G. Johnston Sent: Wednesday, April 9, 2025 1

Re: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Adrian Klaver
On 4/9/25 10:45 AM, Abraham, Danny wrote: Failure eans going down the hba list and asking for the password. In pg_hba.conf first match wins, sounds like you have password auth line before the trust lines. You need to provide the complete pg_hba.conf auth lines you are working with.

Re: Interesting case of IMMUTABLE significantly hurting performance

2025-04-09 Thread Nico Williams
On Wed, Apr 09, 2025 at 10:50:00PM +0200, Laurenz Albe wrote: > The IMMUTABLE function cannot be inlined because to_char() is not IMMUTABLE. Q: Why would to_char() not be IMMUTABLE? A: Because it makes use of locales, and I guess the guc-timezone GUC, which could change if the expression is ul

Re: PgBackRest fails due to filesystem full

2025-04-09 Thread Ron Johnson
Try creating a new stanza, and doing a full backup from it. On Wed, Apr 9, 2025 at 1:49 AM KK CHN wrote: > > > On Tue, Apr 8, 2025 at 10:28 PM Greg Sabino Mullane > wrote: > >> On Mon, Apr 7, 2025 at 5:32 AM KK CHN wrote: >> >>> *ERROR: [082]: WAL segment 000101EB00*4B was not arch

Interesting case of IMMUTABLE significantly hurting performance

2025-04-09 Thread Olleg Samoylov
PostgreSQL 17.4 CREATE OR REPLACE FUNCTION formatted_num_immutable(p_summa bigint) RETURNS text LANGUAGE sql IMMUTABLE STRICT RETURN ltrim(to_char(p_summa, '999 999 999 999 999 999 999 999')); CREATE OR REPLACE FUNCTION formatted_num_stable(p_summa bigint) RETURNS text LANGUAGE sql STABLE

Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Abraham, Danny
Hi, Asking for help with inability to connect local using trust Fail #local all all trust #local all dbauser peer OK #hostall all 127.0.0.1/32 trust

RE: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Abraham, Danny
Thanks again. Here is the example: dba-tlv-x6y64k% cat pg_hba.conf # TYPE DATABASEUSERCIDR-ADDRESS METHOD local all all trust hostall all 0.0.0.0/0 scram-sha-256 dba-tlv-x6y64k% pg_ctl relo

FW: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Abraham, Danny
Thanks again. Here is the example: dba-tlv-x6y64k% cat pg_hba.conf # TYPE DATABASEUSERCIDR-ADDRESS METHOD local all all trust hostall all 0.0.0.0/0 scram-sha-256 dba-tlv-x6y64k% pg_ctl relo

Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread David G. Johnston
On Wed, Apr 9, 2025 at 9:20 AM Abraham, Danny wrote: > Fail > Failures include messages indicating why. You should always share such messages. Showing the command that produced the failure is also advised. David J.

Re: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Adrian Klaver
On 4/9/25 10:44 AM, Abraham, Danny wrote: Thanks for the answers. All the 3 lines are, of course, uncommented for the test. Then provide the actual configuration you are working with. I am using Linux, socket is in /tmp, i see the .s files , but local trust still does not connect. Provid

Re: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Abraham, Danny
Failure eans going down the hba list and asking for the password. Sent from Workspace ONE Boxer On Apr 9, 2025 20:04, Francisco Olarte wrote: On Wed, 9 Apr 2025 at 18:20, Abraham, Danny wrote: > Asking for help with inability to connect local using trust > Fail > #local all all

Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Adrian Klaver
On 4/9/25 09:20, Abraham, Danny wrote: Hi, Asking for help with inability to connect local using trust The # are comments that would 'hide' the lines below from being looked at for authentication purposes. Is this really how the lines are in your pg_hba.conf file? Fail #local all

Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Francisco Olarte
On Wed, 9 Apr 2025 at 18:20, Abraham, Danny wrote: > Asking for help with inability to connect local using trust > Fail > #local all all trust > #local all dbauser peer > OK > #hostall all 127.0.0.1/32 trust How are you c

Re: timescaledb vs NULL vs pg_timeseries vs partman + pgcron + pg_ivm

2025-04-09 Thread Brent Wood
I also use the free community edition on internal servers, but under Ubuntu. No issues and very good performance. Brent Wood... Yahoo Mail: Search, organise, conquer On Wed, 9 Apr 2025 at 13:51, Amitabh Kant wrote: On Tue, Apr 8, 2025 at 11:29 PM Achilleas Mantzios wrote: On 8/4/

Re: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Abraham, Danny
Thanks for the answers. All the 3 lines are, of course, uncommented for the test. I am using Linux, socket is in /tmp, i see the .s files , but local trust still does not connect. Sent from Workspace ONE Boxer On Apr 9, 2025 20:04, Francisco Olarte wrote: On Wed, 9 Apr 2025 at 18:20, Abraham, D

Re: [EXTERNAL] Re: Cannot connect local with ttrust (pg_upgrade assumes it)

2025-04-09 Thread Adrian Klaver
On 4/9/25 13:40, Abraham, Danny wrote: Thanks again. 4. I am not aware of an env variable that changes the top down matching on pg_hba.conf Should have added to previous post: From here: https://www.postgresql.org/docs/current/runtime-config-logging.html#RUNTIME-CONFIG-LOGGING-WHAT a

Re: Interesting case of IMMUTABLE significantly hurting performance

2025-04-09 Thread Laurenz Albe
On Wed, 2025-04-09 at 19:12 +0300, Olleg Samoylov wrote: > PostgreSQL 17.4 > > CREATE OR REPLACE FUNCTION formatted_num_immutable(p_summa bigint) > RETURNS text > LANGUAGE sql > IMMUTABLE STRICT > RETURN ltrim(to_char(p_summa, '999 999 999 999 999 999 999 999')); > > CREATE OR REPLACE FUNCT

Re: Interesting case of IMMUTABLE significantly hurting performance

2025-04-09 Thread David G. Johnston
On Wed, Apr 9, 2025 at 1:50 PM Laurenz Albe wrote: > If you use EXPLAIN (VERBOSE), you will see that the function gets inlined > in the fast case. > > That saves the overhead of a function call. > > The IMMUTABLE function cannot be inlined because to_char() is not > IMMUTABLE. > So, the punishme

Re: PgBackRest fails due to filesystem full

2025-04-09 Thread KK CHN
On Tue, Apr 8, 2025 at 10:28 PM Greg Sabino Mullane wrote: > On Mon, Apr 7, 2025 at 5:32 AM KK CHN wrote: > >> *ERROR: [082]: WAL segment 000101EB00*4B was not archived >> before the 6ms timeout >> > > This is the part you need to focus on. Look at your Postgres logs and find > o

Re: Is pg_basebackup Performance Limited by Files Page Cache?

2025-04-09 Thread Alexandru Lazarev
I'll answer my own question here: Looks like it is a bug in Oracle Linux (OL) 9.2 RHCK Kernel "kernel-5.14.0-284.11.1" (see table: https://docs.oracle.com/en/operating-systems/oracle-linux/9/boot/oracle_linux9_kernel_version_matrix.html) Switching to UEK Kernel of the same OL version (9.2) fixed t