Module: check_mk
Branch: master
Commit: 736ef415552ccb4fef22f3967bc8b5a52a89727b
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=736ef415552ccb…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Thu Sep 19 09:25:36 2013 +0200
snapshot removal: only try to remove snapshot files
---
ChangeLog | 6 ++++--
web/htdocs/wato.py | 3 ++-
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index d8b89fd..95702e9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -188,6 +188,8 @@
Host/Service/Contact Groups, Timeperiods and Roles
* Removed "do not connect" option from site socket editor. Use the
checkbox "Disable" to disable the site for multisite.
+ * ADD: Rule to check state of physical switch (currently used by etherbox check)
+ * ADD: new ruleset cisco_wlc: Allows to configure handling of missing AP
* FIX: do validation of check items in rule editor
* FIX: More consistent handling of folderpath select in rule editor
* FIX: Now correctly handling depends_on_tags on page rendering for
@@ -196,10 +198,10 @@
large" error messages during submitting forms
* FIX: automation snmp scan now adhere rules for shoddy snmp devices
which have no sys description
- * ADD: Rule to check state of physical switch (currently used by etherbox check)
* FIX: Cisco ruleset "Cisco WLC WiFi client connections" has been
generalized to
"WLC WiFi client connections"
- * ADD: new ruleset cisco_wlc: Allows to configure handling of missing AP
+ * FIX: Snapshot handling is a little more robust agains manually created
+ files in snapshot directory now
Notifications:
* Flexible Notification can now filter service levels
diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index d3f409a..40aba20 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -5292,7 +5292,8 @@ def create_snapshot():
# Maintenance, remove old snapshots
snapshots = []
for f in os.listdir(snapshot_dir):
- snapshots.append(f)
+ if f.startswith('wato-snapshot-') and f.endswith('.tar.gz'):
+ snapshots.append(f)
snapshots.sort(reverse=True)
while len(snapshots) > config.wato_max_snapshots:
log_audit(None, "snapshot-removed", _("Removed snapshot %s")
% snapshots[-1])