Releases: postgrespro/mamonsu
3.4.0
Changelog
- added Server Version metric;
- added Available Memory metric;
- fixed native Zabbix Agent user parameters format;
- added new Mamonsu zabbix tool: 'mamonsu zabbix dashboard upload' for Zabbix 6.0+;
mamonsu zabbix dashboard upload
New Zabbix CLI tool to generate pretty Zabbix 6.0 dashboard and upload it to the mamonsu template by its name.
Usage:
mamonsu zabbix dashboard upload [template_name]
Example:
cuprumtan@station ~/mamonsu$ export OPTIONS=" --url=http://127.0.0.1/ --user=Admin --password=zabbix"
cuprumtan@station ~/mamonsu$ mamonsu zabbix $OPTIONS dashboard upload "Mamonsu PostgreSQL Linux"
True
Can be used only with Zabbix server 6.0 and higher.
3.3.1
3.3.0
Changelog
- fixed auxiliary extension schema search;
- fixed WAL metrics definition for native Zabbix agent;
- upgraded Autovacuum and Connection metrics for PG 10+: now it is evaluating using pg_stat_activity.backend_type which makes the calculation more accurate;
- added new Other Connections metric for PG 10+ to count metrics like auxiliary extension backends;
- added new configuration parameter to the [zabbix] section: timeout (in seconds);
- fixed Plugin Errors metric time interval to fit default '60 seconds' value;
- fixed Slave Replication Lag metric to exclude master server from calculation #180;
pg_stat_activity.backend_type
Using pg_stat_activity.backend_type
we can determine user backends by 'client backend' and 'parallel worker' values. So for PG 10+ current strategy for gathering connection metrics relies on backend_type field.
For example, query for gathering waiting user connection:
SELECT count(*)
FROM pg_catalog.pg_stat_activity
WHERE (backend_type = 'client backend' OR backend_type = 'parallel worker')
AND wait_event_type IS NOT NULL;
Also backend_type is useful to count accurately autovacuum processes in the system using 'autovacuum worker' field value.
'Other Connections' metric
Following the previous statement, we added new Other Connections metric to represent count of connections with additional backend_type
. Additional backend_type usually means that there are background workers registered by extensions.
New 'zabbix.timeout' parameter
We added a new configuration parameter for [zabbix] section to define zabbix server response timeout in seconds:
<...>
[zabbix]
enabled = True
client = pg-master
address = 127.0.0.1
port = 10051
; that's it!
timeout = 15
;
re_send = False
<...>
Default value: 15 seconds.
3.2.1
3.2.0
Changelog
- added new Invalid Indexes metric and trigger to the Databases discovery rule;
- added version number output to log (#175);
- fixed template syntax (#173, #177);
- fixed Archive plugin to fit PostgreSQL 10 or lower;
- fixed Cache Hit Ratio and Sync Duty Zabbix item formula syntax;
Invalid Indexes
Following the PostgreSQL documentation:
If a problem arises while scanning the table, such as a deadlock or a uniqueness violation in a unique index, the CREATE INDEX command will fail but leave behind an “invalid” index. This index will be ignored for querying purposes because it might be incomplete; however it will still consume update overhead.
-- source
Mamonsu now can track invalid indexes using pg_locks
view to ignore indexes are currently being created and alert us about this if there is at least one invalid index in the database:
SELECT count (*)
FROM pg_catalog.pg_index i LEFT JOIN pg_catalog.pg_locks l
ON (i.indexrelid = l.relation)
WHERE NOT (i.indisvalid AND i.indisready) AND l.relation IS NULL;
3.1.2
3.1.1
3.1.0
Mamonsu 3.1.0:
- fixed unknown options check in mamonsu tools;
- fixed item units with Speed Per Second delta;
- fixed #166 (1): Walreceiver Lag items name generation;
- fixed #166 (2): item Total Replication Lag delta evaluation;
- fixed #107: slave replication lag evaluation;
- #172: set 'dbname' bootstrap parameter required, added default value read from config file;
- fixed extension functions calling without special mamonsu user and schema;
- refactoring;
bootstrap update
Added new -c/--config option to bootstrap tool. Usage:
mamonsu bootstrap [-M mamonsu_user] [-x | --create-extensions] [-c | --config] [connection_options]
This option is needed for automatic dbname parameter detection. Now if you have not set the dbname explicitly, parameter will be set as database defined in [postgres] section in mamonsu config file.
3.0.2
3.0.1
Mamonsu 3.0.1:
- fixed 'PostgreSQL: Archive Command archive status' graph y axis;
- fixed bootstrap -x option: now it checks installed extensions;
- fixed 'pgsql.count_files_to_archive' and 'pgsql.size_files_to_archive' items: now their evaluation depending on type of server (master or replica);