X-Git-Url: https://code.grnet.gr/git/ganeti-local/blobdiff_plain/f4bc1f2cadcdf1ccba63cc72eb9eaa336fe07950..0d0c1b4a16ae3edaebe231b67e657d148c8c3c8b:/daemons/ganeti-watcher diff --git a/daemons/ganeti-watcher b/daemons/ganeti-watcher index 215628b..8b2b183 100755 --- a/daemons/ganeti-watcher +++ b/daemons/ganeti-watcher @@ -349,6 +349,7 @@ class Watcher(object): notepad = WatcherState() self.CheckInstances(notepad) self.CheckDisks(notepad) + self.VerifyDisks() notepad.Save() def CheckDisks(self, notepad): @@ -417,6 +418,14 @@ class Watcher(object): msg = Message(NOTICE, "Restart of %s succeeded." % instance.name) self.messages.append(msg) + def VerifyDisks(self): + """Run gnt-cluster verify-disks. + + """ + result = DoCmd(['gnt-cluster', 'verify-disks', '--lock-retries=15']) + if result.output: + self.messages.append(Message(NOTICE, result.output)) + def WriteReport(self, logfile): """Log all messages to file.