]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/munin/files/default/plugins/postgres_replication
Make replication delay monitoring more reliable
[chef.git] / cookbooks / munin / files / default / plugins / postgres_replication
index 4a04d0b0e9ecf2f4286e724e1f391b9acf2a471a..56ee16371213d0eab28725936513aaefe8bdb2ca 100755 (executable)
@@ -11,8 +11,9 @@ my $pg = Munin::Plugin::Pgsql->new(
     vlabel    => 'Seconds',
     basequery => "SELECT (extract(epoch FROM now()) - extract(epoch FROM pg_last_xact_replay_timestamp()))::int AS delay",
     pivotquery => 1,
-    configquery =>
-        "VALUES ('delay','Replication delay')"
+    configquery => "VALUES ('delay','Replication delay')",
+    extraconfig => "delay.warning 300\ndelay.critical 3600",
+    graphmin  => 0
 );
 
 $pg->Process();