You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There seems to be some issues using pg_monz with PostgreSQL 9.6 databases. Some calls (such as for pg_stat_activity have changed enough that they no longer work properly with pg_monz. I found and fixed that issue locally (by modifying line 34 in pgsql_server_funcs.sh), but there seem to be other functions that do not work (such as cache hit ratio, deadlocks, committed/rolledback transaction, etc).
I've started troubleshooting them and will contribute back any fixes I find, but I am also not sure how the project would like to handle the changes (few people are using pg96 since it is fairly new, but what would be the preferred method to handle different versions of the same functions depending on the pg version)?
The text was updated successfully, but these errors were encountered:
for anyone looking to fix pgsql_server_funcs.sh to work in 9.6:
--- pg_monz/pgsql_server_funcs.sh+++ pg_monz/pgsql_server_funcs.sh@@ -32,7 +32,7 @@ case "$APP_NAME" in
union all \
select '\"$HOST_NAME\"', 'psql.idle_tx_connections', $TIMESTAMP_QUERY, (select count(*) from pg_stat_activity where state = 'idle in transaction') \
union all \
- select '\"$HOST_NAME\"', 'psql.locks_waiting', $TIMESTAMP_QUERY, (select count(*) from pg_stat_activity where waiting = 'true') \+ select '\"$HOST_NAME\"', 'psql.locks_waiting', $TIMESTAMP_QUERY, (select count(*) from pg_stat_activity where wait_event IS NOT NULL) \
union all \
select '\"$HOST_NAME\"', 'psql.server_maxcon', $TIMESTAMP_QUERY, (select setting::int from pg_settings where name = 'max_connections')" 2>&1
)
Hello,
There seems to be some issues using pg_monz with PostgreSQL 9.6 databases. Some calls (such as for pg_stat_activity have changed enough that they no longer work properly with pg_monz. I found and fixed that issue locally (by modifying line 34 in pgsql_server_funcs.sh), but there seem to be other functions that do not work (such as cache hit ratio, deadlocks, committed/rolledback transaction, etc).
I've started troubleshooting them and will contribute back any fixes I find, but I am also not sure how the project would like to handle the changes (few people are using pg96 since it is fairly new, but what would be the preferred method to handle different versions of the same functions depending on the pg version)?
The text was updated successfully, but these errors were encountered: