Thread: pgbadger issue

pgbadger issue

From
S Bob
Date:

All;


Apologies if this is the wrong list. I have a log file from a PostgreSQL v10.12 cluster


log_min_duration statement = 0

log_line_prefix = '%t [%p]: [%l-1] '

log_destination = stderr


I see queries in the log, such as this one:

2021-01-14 20:28:20 EST [11486]: [2-1] STATEMENT:  SELECT * FROM BigTab WHERE cast(value ->> 'pending' as bool) = 'false' order by cast(value ->> '
closeTimestamp' as bigint) desc, cast(value ->> 'openTimestamp' as bigint) desc


However when I parse the log I get zero queries:

$ pgbadger -o uat.html -f stderr -p '%t [%p]: [%l-1] '  ./postgresql-Thu.log
[========================>] Parsed 10007997 bytes of 10007997 (100.00%), queries: 0, events: 1
LOG: Ok, generating html report...



Thoughts?


Thanks in advance


Re: pgbadger issue

From
Guillaume Lelarge
Date:
Hi,

Le ven. 15 janv. 2021 à 02:42, S Bob <sbob@quadratum-braccas.com> a écrit :

All;


Apologies if this is the wrong list. I have a log file from a PostgreSQL v10.12 cluster


log_min_duration statement = 0

log_line_prefix = '%t [%p]: [%l-1] '

log_destination = stderr


I see queries in the log, such as this one:

2021-01-14 20:28:20 EST [11486]: [2-1] STATEMENT:  SELECT * FROM BigTab WHERE cast(value ->> 'pending' as bool) = 'false' order by cast(value ->> '
closeTimestamp' as bigint) desc, cast(value ->> 'openTimestamp' as bigint) desc



This log doesn't look like a log_min_duration_statement log. Obviously, it lacks the duration.

However when I parse the log I get zero queries:

$ pgbadger -o uat.html -f stderr -p '%t [%p]: [%l-1] '  ./postgresql-Thu.log
[========================>] Parsed 10007997 bytes of 10007997 (100.00%), queries: 0, events: 1
LOG: Ok, generating html report...



The only log you showed us doesn't look like the pattern pgBadger is searching for, so it isn't surprising that pgBadger doesn't detect queries.


--
Guillaume.