From 63fd12b57031fda6b13e10197f14e3a045374df3 Mon Sep 17 00:00:00 2001 From: Narayan Desai Date: Wed, 19 Jan 2005 03:47:01 +0000 Subject: add log on err (Logical change 1.192) git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@817 ce84e21b-d406-0410-9b95-82705330c041 --- src/lib/Server/Generators/Chiba.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/lib/Server/Generators/Chiba.py b/src/lib/Server/Generators/Chiba.py index 5b7cbbddc..597a30679 100644 --- a/src/lib/Server/Generators/Chiba.py +++ b/src/lib/Server/Generators/Chiba.py @@ -2,6 +2,7 @@ __revision__ = '$Revision$' from socket import gethostbyname, gaierror +from syslog import syslog, LOG_ERR from Bcfg2.Server.Generator import Generator, DirectoryBacked, SingleXMLFileBacked, GeneratorError class ChibaConf(SingleXMLFileBacked): @@ -33,6 +34,7 @@ class Chiba(Generator): try: myriaddr = gethostbyname("%s-myr" % metadata.hostname) except gaierror: + syslog(LOG_ERR, "Failed to resolve %s-myr"% metadata.hostname) raise GeneratorError, ("%s-myr" % metadata.hostname, 'lookup') entry.text = self.repo.entries['interfaces-template'].data % myriaddr -- cgit v1.2.3-1-g7c22