diff options
author | Narayan Desai <desai@mcs.anl.gov> | 2004-11-11 15:49:05 +0000 |
---|---|---|
committer | Narayan Desai <desai@mcs.anl.gov> | 2004-11-11 15:49:05 +0000 |
commit | c6b51b07f669f0012a5dcb199e67a76530a0546b (patch) | |
tree | af96c1e1dce522903c5cf1306606b91a364a590b /src/lib/Server/Generators | |
parent | c3117750b2157a168f794747071b4c1561c95b96 (diff) | |
download | bcfg2-c6b51b07f669f0012a5dcb199e67a76530a0546b.tar.gz bcfg2-c6b51b07f669f0012a5dcb199e67a76530a0546b.tar.bz2 bcfg2-c6b51b07f669f0012a5dcb199e67a76530a0546b.zip |
fix logging
(Logical change 1.151)
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@673 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'src/lib/Server/Generators')
-rw-r--r-- | src/lib/Server/Generators/Cfg.py | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/lib/Server/Generators/Cfg.py b/src/lib/Server/Generators/Cfg.py index ff3677270..066ce99f5 100644 --- a/src/lib/Server/Generators/Cfg.py +++ b/src/lib/Server/Generators/Cfg.py @@ -88,7 +88,6 @@ class ConfigFileEntry(object): specmatch = self.specific.match(name) if specmatch == None: syslog(LOG_ERR, "Failed to match file %s" % (name)) - print "match failed for file name %s" % (name) return data = {} @@ -119,7 +118,7 @@ class ConfigFileEntry(object): elif action == 'deleted': [flist.remove(entry) for flist in [self.basefiles, self.deltas] if entry in flist] else: - print "unhandled action %s" % (action) + syslog(LOG_ERR, "Cfg: Unhandled Action %s for file %s" % (action, event.filename)) def GetConfigFile(self, entry, metadata): '''Fetch config file from repository''' @@ -167,7 +166,7 @@ class ConfigFileRepository(object): try: stat(name) except OSError: - print "Failed to open %s" % (name) + syslog(LOG_ERR, "Failed to open directory %s" % (name)) return reqid = self.fam.AddMonitor(name, self) self.famID[reqid] = name @@ -218,10 +217,10 @@ class ConfigFileRepository(object): elif action == 'deleted': configfile = filename[len(self.name):-(len(event.filename)+1)] self.entries[configfile].HandleEvent(event) - elif action in ['endExist']: + elif action in ['exists', 'endExist']: pass else: - print "Got unknown event %s %s %s" % (event.requestID, event.code2str(), event.filename) + syslog(LOG_ERR, "Got unknown event %s %s:%s" % (action, event.requestID, event.filename)) class Cfg(Generator): '''This generator manages the configuration file repository for bcfg2''' |