Compare commits
3 Commits
5acfd4e657
...
583a5ca594
Author | SHA1 | Date |
---|---|---|
Franzi | 583a5ca594 | |
Franzi | b20e729298 | |
Franzi | c535ce24a4 |
|
@ -38,7 +38,7 @@ try:
|
|||
last_snap = sorted(snaps)[-1]
|
||||
delta = NOW - last_snap
|
||||
|
||||
print('Last backup was on {}'.format(
|
||||
print('Last backup was on {} UTC'.format(
|
||||
datetime.fromtimestamp(last_snap).strftime('%Y-%m-%d %H:%M:%S'),
|
||||
))
|
||||
|
||||
|
|
|
@ -138,7 +138,10 @@ def zfs_datasets_and_snapshots(metadata):
|
|||
def monitoring(metadata):
|
||||
services = {}
|
||||
|
||||
for client in metadata.get('backup-server/clients', {}).keys():
|
||||
for client, config in metadata.get('backup-server/clients', {}).items():
|
||||
if config.get('exclude_from_monitoring', False):
|
||||
continue
|
||||
|
||||
services[f'BACKUPS FOR NODE {client}'] = {
|
||||
'command_on_monitored_host': f'sudo /usr/local/share/icinga/plugins/check_backup_for_node {client}',
|
||||
}
|
||||
|
|
|
@ -35,6 +35,7 @@ nodes['htz-hel.backup-kunsi'] = {
|
|||
'clients': {
|
||||
'kunsi-t470': {
|
||||
'user': 'kunsi-t470',
|
||||
'exclude_from_monitoring': True,
|
||||
'retain': {
|
||||
'daily': 30,
|
||||
'weekly': 6,
|
||||
|
|
Loading…
Reference in New Issue