Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 2012-04-19 11:29:44,436 Loading GeneratorRegistry
- 2012-04-19 11:29:44,468 Loading MacroRegistry
- 2012-04-19 11:29:44,499 Loading ParserRegistry
- 2012-04-19 11:29:44,532 Invalid state map expression: ''
- 2012-04-19 11:29:44,549 UNHANDLED EXCEPTION (2012-04-19 11:29:44.532722)
- Working directory: /opt/noc
- <type 'exceptions.SystemExit'>
- 1
- START OF TRACEBACK
- ------------------------------------------------------------------------
- File: /opt/noc/lib/daemon.py (Line: 183)
- Function: die
- 176 sys.exit(1)
- 177 else:
- 178 logging.basicConfig(level=logging.DEBUG,
- 179 format='%(asctime)s %(message)s')
- 180
- 181 def die(self, msg):
- 182 logging.error(msg)
- 183 ==> sys.exit(1)
- 184
- 185 def on_load_config(self):
- 186 """
- 187 Called after config has been reloaded on SIGHUP
- 188 :return:
- 189 """
- Variables:
- msg = "Invalid state map expression: ''"
- self = <noc.inv.discovery.daemon.DiscoveryDaemon object at 0xa28550c>
- ------------------------------------------------------------------------
- File: /opt/noc/inv/discovery/daemon.py (Line: 113)
- Function: get_state_map
- 106 except ResourceState.DoesNotExist:
- 107 self.die("Unknown resource state: '%s'" % name)
- 108
- 109 m = {}
- 110 for x in s.split(";"):
- 111 x = x.strip()
- 112 if "->" not in x:
- 113 ==> self.die("Invalid state map expression: '%s'" % x)
- 114 f, t = [get_state(y.strip()) for y in x.split("->")]
- 115 m[f.id] = t
- 116 return m
- 117
- 118 def run(self):
- 119 last_i_check = 0
- Variables:
- x = ''
- s = ''
- m = {}
- self = <noc.inv.discovery.daemon.DiscoveryDaemon object at 0xa28550c>
- get_state = <function get_state at 0xa55bd84>
- ------------------------------------------------------------------------
- File: /opt/noc/inv/discovery/daemon.py (Line: 69)
- Function: load_config
- 62 self.p_enabled = self.config.getboolean("prefix_discovery",
- 63 "enabled")
- 64 self.asn = AS.default_as()
- 65 self.p_save = (self.p_enabled and
- 66 self.config.getboolean("prefix_discovery",
- 67 "save"))
- 68 self.p_state_map = self.get_state_map(self.config.get("prefix_discovery",
- 69 ==> "change_state"))
- 70 self.ip_enabled = self.config.getboolean("ip_discovery",
- 71 "enabled")
- 72 self.asn = AS.default_as()
- 73 self.ip_save = (self.ip_enabled and
- 74 self.config.getboolean("ip_discovery",
- 75 "save"))
- Variables:
- self = <noc.inv.discovery.daemon.DiscoveryDaemon object at 0xa28550c>
- ------------------------------------------------------------------------
- File: /opt/noc/lib/daemon.py (Line: 82)
- Function: __init__
- 75 "stop", "refresh"]:
- 76 self.opt_parser.error(
- 77 "You must supply one of start|launch|stop|refresh commands")
- 78 # Read config
- 79 self.pidfile = None
- 80 self.config = None
- 81 self.instance_id = self.options.instance_id
- 82 ==> self.load_config()
- 83 # Register signal handlers if any
- 84 for s in [s for s in dir(self) if s.startswith("SIG")]:
- 85 try:
- 86 sig = getattr(signal, s)
- 87 except AttributeError:
- 88 logging.error(
- Variables:
- self = <noc.inv.discovery.daemon.DiscoveryDaemon object at 0xa28550c>
- ------------------------------------------------------------------------
- File: /opt/noc/inv/discovery/daemon.py (Line: 37)
- Function: __init__
- 30
- 31 class DiscoveryDaemon(Daemon):
- 32 daemon_name = "noc-discovery"
- 33
- 34 rx_address = re.compile("[^0-9a-z\-]+")
- 35
- 36 def __init__(self, *args, **kwargs):
- 37 ==> super(DiscoveryDaemon, self).__init__(*args, **kwargs)
- 38 self.pmap_interfaces = [p for p in profile_registry.classes
- 39 if "get_interfaces" in profile_registry.classes[p].scripts]
- 40 self.pmap_ip = [p for p in profile_registry.classes
- 41 if "get_ip_discovery" in profile_registry.classes[p].scripts]
- 42 self.new_prefixes = []
- 43 self.new_addresses = []
- Variables:
- self = <noc.inv.discovery.daemon.DiscoveryDaemon object at 0xa28550c>
- args = ()
- kwargs = {}
- ------------------------------------------------------------------------
- File: ./scripts/noc-discovery.py (Line: 20)
- Function: <module>
- 13 set_env.setup(use_django=True)
- 14
- 15 if __name__ == "__main__":
- 16 from noc.inv.discovery.daemon import DiscoveryDaemon
- 17 from noc.lib.debug import error_report
- 18
- 19 try:
- 20 ==> DiscoveryDaemon().process_command()
- 21 except:
- 22 error_report()
- Variables:
- set_env = <module 'set_env' from '/opt/noc/scripts/set_env.pyc'>
- __builtins__ = <module '__builtin__' (built-in)>
- __file__ = './scripts/noc-discovery.py'
- DiscoveryDaemon = <class 'noc.inv.discovery.daemon.DiscoveryDaemon'>
- __package__ = None
- __name__ = '__main__'
- error_report = <function error_report at 0x95efb54>
- __doc__ = None
- ------------------------------------------------------------------------
- END OF TRACEBACK
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement