# Pastebin c2UXodpc 2016-02-03 20:37:36.786914 [box] Starting 2016-02-03 20:37:36.791304 [discovery|box|pmo-ar01|profile] Checking profile 2016-02-03 20:37:36.791371 [discovery|box|pmo-ar01|profile] Compiling rules 2016-02-03 20:37:56.827376 [discovery|box|pmo-ar01|profile] Cannot find profile 2016-02-03 20:37:56.827502 [discovery|box|pmo-ar01|version] Checking version 2016-02-03 20:38:07.002955 [discovery|box|pmo-ar01|version] UNHANDLED EXCEPTION (2016-02-03 20:38:06.992019) BRANCH: feature/microservices TIP: 3032694d798a PROCESS: ./services/discovery/service.py ERROR FINGERPRINT: 1ee46bb5-0acf-5977-b094-6ac3fe13dcb2 WORKING DIRECTORY: /opt/noc EXCEPTION: Failed: RPC Error: RPC call failed: Failed: Stream is closed START OF TRACEBACK ------------------------------------------------------------------------ File: core/service/client.py (Line: 130) Function: __call__ 123 raise RPCException(why) 124 if not response: 125 raise RPCNoService( 126 "No active service %s found" % service 127 ) 128 data = json.loads(response.body) 129 if data.get("error"): 130 ==> raise RPCRemoteError(data["error"]) 131 t = time.time() - t0 132 logger.debug("[ req = {'params': [3, 'get_version', {}, None], 'id': 21, 'method': 'script'} l = '10.50.64.73:19010' t0 = 1454521076.827538 st = 1.0 headers = {'X-NOC-Calling-Service': 'MTManager'} client = services = ['10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010'] logger = data = {u'error': u'Failed: RPC Error: RPC call failed: Failed: Stream is closed', u'id': 21} response = HTTPResponse(_body='{"id": 21, "error": "Failed: RPC Error: RPC call failed: Failed: Stream is closed"}',buffer=<_io.BytesIO object at 0x7f54f5434590>,code=200,effective_url='http://10.50.64.73:19010/api/sae/',error=None,headers=,reason='OK',request=,request_time=10.163822889328003,time_info={}) ------------------------------------------------------------------------ File: sa/mtmanager.py (Line: 30) Function: run 23 """ 24 Run SA script and wait for result 25 """ 26 if "." in script: 27 # Leave only script name 28 script = script.split(".")[-1] 29 return RPCClient("sae", calling_service="MTManager").script( 30 ==> object.id, script, params, timeout 31 ) 32 33 34 # Run single instance 35 MTManager = MTManagerImplementation() Variables: self = object = params = {} timeout = None script = 'get_version' ------------------------------------------------------------------------ File: sa/models/managedobject.py (Line: 252) Function: __call__ 245 class ScriptsProxy(object): 246 class CallWrapper(object): 247 def __init__(self, obj, name): 248 self.name = name 249 self.object = obj 250 251 def __call__(self, **kwargs): 252 ==> return MTManager.run(self.object, self.name, kwargs) 253 254 def __init__(self, obj): 255 self._object = obj 256 self._cache = {} 257 258 def __getattr__(self, name): Variables: self = kwargs = {} ------------------------------------------------------------------------ File: services/discovery/jobs/box/version.py (Line: 22) Function: handler 15 Version discovery 16 """ 17 name = "version" 18 required_script = "get_version" 19 20 def handler(self): 21 self.logger.info("Checking version") 22 ==> result = self.object.scripts.get_version() 23 r = {} 24 for k in result: 25 v = result[k] 26 if k == "attributes": 27 for kk in v: 28 r[kk] = v[kk] Variables: self = ------------------------------------------------------------------------ File: services/discovery/jobs/base.py (Line: 102) Function: run 95 self.logger.info( 96 "Capability '%s' is disabled. Skipping", 97 cn 98 ) 99 return 100 # Run check 101 try: 102 ==> self.handler() 103 except Exception: 104 error_report(logger=self.logger) 105 106 def handler(self): 107 pass 108 Variables: self = ------------------------------------------------------------------------ END OF TRACEBACK 2016-02-03 20:38:07.003350 [discovery|box|pmo-ar01|caps] Checking capabilities 2016-02-03 20:38:17.070891 [discovery|box|pmo-ar01|caps] UNHANDLED EXCEPTION (2016-02-03 20:38:17.055453) BRANCH: feature/microservices TIP: 3032694d798a PROCESS: ./services/discovery/service.py ERROR FINGERPRINT: 1ee46bb5-0acf-5977-b094-6ac3fe13dcb2 WORKING DIRECTORY: /opt/noc EXCEPTION: Failed: RPC Error: RPC call failed: Failed: Stream is closed START OF TRACEBACK ------------------------------------------------------------------------ File: core/service/client.py (Line: 130) Function: __call__ 123 raise RPCException(why) 124 if not response: 125 raise RPCNoService( 126 "No active service %s found" % service 127 ) 128 data = json.loads(response.body) 129 if data.get("error"): 130 ==> raise RPCRemoteError(data["error"]) 131 t = time.time() - t0 132 logger.debug("[ req = {'id': 22, 'method': 'script', 'params': [3, 'get_capabilities', {}, None]} l = '10.50.64.73:19010' t0 = 1454521087.003396 st = 1.0 headers = {'X-NOC-Calling-Service': 'MTManager'} client = services = ['10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010'] logger = data = {u'error': u'Failed: RPC Error: RPC call failed: Failed: Stream is closed', u'id': 22} response = HTTPResponse(_body='{"id": 22, "error": "Failed: RPC Error: RPC call failed: Failed: Stream is closed"}',buffer=<_io.BytesIO object at 0x7f54f5434590>,code=200,effective_url='http://10.50.64.73:19010/api/sae/',error=None,headers=,reason='OK',request=,request_time=10.051349878311157,time_info={}) ------------------------------------------------------------------------ File: sa/mtmanager.py (Line: 30) Function: run 23 """ 24 Run SA script and wait for result 25 """ 26 if "." in script: 27 # Leave only script name 28 script = script.split(".")[-1] 29 return RPCClient("sae", calling_service="MTManager").script( 30 ==> object.id, script, params, timeout 31 ) 32 33 34 # Run single instance 35 MTManager = MTManagerImplementation() Variables: self = object = params = {} timeout = None script = 'get_capabilities' ------------------------------------------------------------------------ File: sa/models/managedobject.py (Line: 252) Function: __call__ 245 class ScriptsProxy(object): 246 class CallWrapper(object): 247 def __init__(self, obj, name): 248 self.name = name 249 self.object = obj 250 251 def __call__(self, **kwargs): 252 ==> return MTManager.run(self.object, self.name, kwargs) 253 254 def __init__(self, obj): 255 self._object = obj 256 self._cache = {} 257 258 def __getattr__(self, name): Variables: self = kwargs = {} ------------------------------------------------------------------------ File: services/discovery/jobs/box/caps.py (Line: 22) Function: handler 15 Version discovery 16 """ 17 name = "caps" 18 required_script = "get_capabilities" 19 20 def handler(self): 21 self.logger.info("Checking capabilities") 22 ==> result = self.object.scripts.get_capabilities() 23 self.logger.info("Received capabilities: %s", result) 24 self.object.update_caps(result) Variables: self = ------------------------------------------------------------------------ File: services/discovery/jobs/base.py (Line: 102) Function: run 95 self.logger.info( 96 "Capability '%s' is disabled. Skipping", 97 cn 98 ) 99 return 100 # Run check 101 try: 102 ==> self.handler() 103 except Exception: 104 error_report(logger=self.logger) 105 106 def handler(self): 107 pass 108 Variables: self = ------------------------------------------------------------------------ END OF TRACEBACK 2016-02-03 20:38:17.071289 [discovery|box|pmo-ar01|interface] Using noc.solutions.noc.default.discovery.interface.get_interface_profile for interface classification 2016-02-03 20:38:17.071397 [discovery|box|pmo-ar01|interface] Checking interfaces 2016-02-03 20:38:27.140863 [discovery|box|pmo-ar01|interface] UNHANDLED EXCEPTION (2016-02-03 20:38:27.138791) BRANCH: feature/microservices TIP: 3032694d798a PROCESS: ./services/discovery/service.py ERROR FINGERPRINT: 1ee46bb5-0acf-5977-b094-6ac3fe13dcb2 WORKING DIRECTORY: /opt/noc EXCEPTION: Failed: RPC Error: RPC call failed: Failed: Stream is closed START OF TRACEBACK ------------------------------------------------------------------------ File: core/service/client.py (Line: 130) Function: __call__ 123 raise RPCException(why) 124 if not response: 125 raise RPCNoService( 126 "No active service %s found" % service 127 ) 128 data = json.loads(response.body) 129 if data.get("error"): 130 ==> raise RPCRemoteError(data["error"]) 131 t = time.time() - t0 132 logger.debug("[ req = {'id': 23, 'method': 'script', 'params': [3, 'get_interfaces', {}, None]} l = '10.50.64.73:19010' t0 = 1454521097.07143 st = 1.0 headers = {'X-NOC-Calling-Service': 'MTManager'} client = services = ['10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010'] logger = data = {u'error': u'Failed: RPC Error: RPC call failed: Failed: Stream is closed', u'id': 23} response = HTTPResponse(_body='{"id": 23, "error": "Failed: RPC Error: RPC call failed: Failed: Stream is closed"}',buffer=<_io.BytesIO object at 0x7f54f5434590>,code=200,effective_url='http://10.50.64.73:19010/api/sae/',error=None,headers=,reason='OK',request=,request_time=10.066700220108032,time_info={}) ------------------------------------------------------------------------ File: sa/mtmanager.py (Line: 30) Function: run 23 """ 24 Run SA script and wait for result 25 """ 26 if "." in script: 27 # Leave only script name 28 script = script.split(".")[-1] 29 return RPCClient("sae", calling_service="MTManager").script( 30 ==> object.id, script, params, timeout 31 ) 32 33 34 # Run single instance 35 MTManager = MTManagerImplementation() Variables: self = object = params = {} timeout = None script = 'get_interfaces' ------------------------------------------------------------------------ File: sa/models/managedobject.py (Line: 252) Function: __call__ 245 class ScriptsProxy(object): 246 class CallWrapper(object): 247 def __init__(self, obj, name): 248 self.name = name 249 self.object = obj 250 251 def __call__(self, **kwargs): 252 ==> return MTManager.run(self.object, self.name, kwargs) 253 254 def __init__(self, obj): 255 self._object = obj 256 self._cache = {} 257 258 def __getattr__(self, name): Variables: self = kwargs = {} ------------------------------------------------------------------------ File: services/discovery/jobs/box/interface.py (Line: 43) Function: handler 36 self.interface_profile_cache = cachetools.LRUCache( 37 1000, 38 missing=lambda x: InterfaceProfile.objects.filter(name=x).first() 39 ) 40 41 def handler(self): 42 self.logger.info("Checking interfaces") 43 ==> result = self.object.scripts.get_interfaces() 44 self.seen_interfaces = [] 45 # Process forwarding instances 46 for fi in result: 47 # Apply forwarding instance 48 forwarding_instance = self.submit_forwarding_instance( 49 name=fi["forwarding_instance"], Variables: self = ------------------------------------------------------------------------ File: services/discovery/jobs/base.py (Line: 102) Function: run 95 self.logger.info( 96 "Capability '%s' is disabled. Skipping", 97 cn 98 ) 99 return 100 # Run check 101 try: 102 ==> self.handler() 103 except Exception: 104 error_report(logger=self.logger) 105 106 def handler(self): 107 pass 108 Variables: self = ------------------------------------------------------------------------ END OF TRACEBACK 2016-02-03 20:38:27.141219 [discovery|box|pmo-ar01|id] Checking chassis id 2016-02-03 20:38:37.223961 [discovery|box|pmo-ar01|id] UNHANDLED EXCEPTION (2016-02-03 20:38:37.185460) BRANCH: feature/microservices TIP: 3032694d798a PROCESS: ./services/discovery/service.py ERROR FINGERPRINT: 1ee46bb5-0acf-5977-b094-6ac3fe13dcb2 WORKING DIRECTORY: /opt/noc EXCEPTION: Failed: RPC Error: RPC call failed: Failed: Stream is closed START OF TRACEBACK ------------------------------------------------------------------------ File: core/service/client.py (Line: 130) Function: __call__ 123 raise RPCException(why) 124 if not response: 125 raise RPCNoService( 126 "No active service %s found" % service 127 ) 128 data = json.loads(response.body) 129 if data.get("error"): 130 ==> raise RPCRemoteError(data["error"]) 131 t = time.time() - t0 132 logger.debug("[ req = {'id': 25, 'method': 'script', 'params': [3, 'get_discovery_id', {}, None]} l = '10.50.64.73:19010' t0 = 1454521107.141255 st = 1.0 headers = {'X-NOC-Calling-Service': 'MTManager'} client = services = ['10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010'] logger = data = {u'error': u'Failed: RPC Error: RPC call failed: Failed: Stream is closed', u'id': 25} response = HTTPResponse(_body='{"id": 25, "error": "Failed: RPC Error: RPC call failed: Failed: Stream is closed"}',buffer=<_io.BytesIO object at 0x7f54f5434590>,code=200,effective_url='http://10.50.64.73:19010/api/sae/',error=None,headers=,reason='OK',request=,request_time=10.04353404045105,time_info={}) ------------------------------------------------------------------------ File: sa/mtmanager.py (Line: 30) Function: run 23 """ 24 Run SA script and wait for result 25 """ 26 if "." in script: 27 # Leave only script name 28 script = script.split(".")[-1] 29 return RPCClient("sae", calling_service="MTManager").script( 30 ==> object.id, script, params, timeout 31 ) 32 33 34 # Run single instance 35 MTManager = MTManagerImplementation() Variables: self = object = params = {} timeout = None script = 'get_discovery_id' ------------------------------------------------------------------------ File: sa/models/managedobject.py (Line: 252) Function: __call__ 245 class ScriptsProxy(object): 246 class CallWrapper(object): 247 def __init__(self, obj, name): 248 self.name = name 249 self.object = obj 250 251 def __call__(self, **kwargs): 252 ==> return MTManager.run(self.object, self.name, kwargs) 253 254 def __init__(self, obj): 255 self._object = obj 256 self._cache = {} 257 258 def __getattr__(self, name): Variables: self = kwargs = {} ------------------------------------------------------------------------ File: services/discovery/jobs/box/id.py (Line: 23) Function: handler 16 Version discovery 17 """ 18 name = "id" 19 required_script = "get_discovery_id" 20 21 def handler(self): 22 self.logger.info("Checking chassis id") 23 ==> result = self.object.scripts.get_discovery_id() 24 cm = result.get("chassis_mac") 25 if cm: 26 cm = ", ".join( 27 "%s - %s" % (m["first_chassis_mac"], m["last_chassis_mac"]) 28 for m in cm 29 ) Variables: self = ------------------------------------------------------------------------ File: services/discovery/jobs/base.py (Line: 102) Function: run 95 self.logger.info( 96 "Capability '%s' is disabled. Skipping", 97 cn 98 ) 99 return 100 # Run check 101 try: 102 ==> self.handler() 103 except Exception: 104 error_report(logger=self.logger) 105 106 def handler(self): 107 pass 108 Variables: self = ------------------------------------------------------------------------ END OF TRACEBACK 2016-02-03 20:38:37.224347 [discovery|box|pmo-ar01|caps] Checking config 2016-02-03 20:38:37.290379 [discovery|box|pmo-ar01|caps] UNHANDLED EXCEPTION (2016-02-03 20:38:37.274186) BRANCH: feature/microservices TIP: 3032694d798a PROCESS: ./services/discovery/service.py ERROR FINGERPRINT: 1ee46bb5-0acf-5977-b094-6ac3fe13dcb2 WORKING DIRECTORY: /opt/noc EXCEPTION: Failed: RPC Error: RPC call failed: Failed: Stream is closed START OF TRACEBACK ------------------------------------------------------------------------ File: core/service/client.py (Line: 130) Function: __call__ 123 raise RPCException(why) 124 if not response: 125 raise RPCNoService( 126 "No active service %s found" % service 127 ) 128 data = json.loads(response.body) 129 if data.get("error"): 130 ==> raise RPCRemoteError(data["error"]) 131 t = time.time() - t0 132 logger.debug("[ req = {'params': [3, 'get_config', {}, None], 'id': 28, 'method': 'script'} l = '10.50.64.73:19010' t0 = 1454521117.224387 st = 1.0 headers = {'X-NOC-Calling-Service': 'MTManager'} client = services = ['10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010'] logger = data = {u'error': u'Failed: RPC Error: RPC call failed: Failed: Stream is closed', u'id': 28} response = HTTPResponse(_body='{"id": 28, "error": "Failed: RPC Error: RPC call failed: Failed: Stream is closed"}',buffer=<_io.BytesIO object at 0x7f54f5434590>,code=200,effective_url='http://10.50.64.73:19010/api/sae/',error=None,headers=,reason='OK',request=,request_time=0.049067020416259766,time_info={}) ------------------------------------------------------------------------ File: sa/mtmanager.py (Line: 30) Function: run 23 """ 24 Run SA script and wait for result 25 """ 26 if "." in script: 27 # Leave only script name 28 script = script.split(".")[-1] 29 return RPCClient("sae", calling_service="MTManager").script( 30 ==> object.id, script, params, timeout 31 ) 32 33 34 # Run single instance 35 MTManager = MTManagerImplementation() Variables: self = object = params = {} timeout = None script = 'get_config' ------------------------------------------------------------------------ File: sa/models/managedobject.py (Line: 252) Function: __call__ 245 class ScriptsProxy(object): 246 class CallWrapper(object): 247 def __init__(self, obj, name): 248 self.name = name 249 self.object = obj 250 251 def __call__(self, **kwargs): 252 ==> return MTManager.run(self.object, self.name, kwargs) 253 254 def __init__(self, obj): 255 self._object = obj 256 self._cache = {} 257 258 def __getattr__(self, name): Variables: self = kwargs = {} ------------------------------------------------------------------------ File: services/discovery/jobs/box/config.py (Line: 22) Function: handler 15 Version discovery 16 """ 17 name = "caps" 18 required_script = "get_config" 19 20 def handler(self): 21 self.logger.info("Checking config") 22 ==> result = self.object.scripts.get_config() 23 self.object.save_config(result) Variables: self = ------------------------------------------------------------------------ File: services/discovery/jobs/base.py (Line: 102) Function: run 95 self.logger.info( 96 "Capability '%s' is disabled. Skipping", 97 cn 98 ) 99 return 100 # Run check 101 try: 102 ==> self.handler() 103 except Exception: 104 error_report(logger=self.logger) 105 106 def handler(self): 107 pass 108 Variables: self = ------------------------------------------------------------------------ END OF TRACEBACK 2016-02-03 20:38:37.292858 [discovery|box|pmo-ar01|asset] Checking assets 2016-02-03 20:38:47.345830 [discovery|box|pmo-ar01|asset] UNHANDLED EXCEPTION (2016-02-03 20:38:47.325772) BRANCH: feature/microservices TIP: 3032694d798a PROCESS: ./services/discovery/service.py ERROR FINGERPRINT: 1ee46bb5-0acf-5977-b094-6ac3fe13dcb2 WORKING DIRECTORY: /opt/noc EXCEPTION: Failed: RPC Error: RPC call failed: Failed: Stream is closed START OF TRACEBACK ------------------------------------------------------------------------ File: core/service/client.py (Line: 130) Function: __call__ 123 raise RPCException(why) 124 if not response: 125 raise RPCNoService( 126 "No active service %s found" % service 127 ) 128 data = json.loads(response.body) 129 if data.get("error"): 130 ==> raise RPCRemoteError(data["error"]) 131 t = time.time() - t0 132 logger.debug("[ req = {'params': [3, 'get_inventory', {}, None], 'id': 29, 'method': 'script'} l = '10.50.64.73:19010' t0 = 1454521117.292903 st = 1.0 headers = {'X-NOC-Calling-Service': 'MTManager'} client = services = ['10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010', '10.50.64.73:19010'] logger = data = {u'error': u'Failed: RPC Error: RPC call failed: Failed: Stream is closed', u'id': 29} response = HTTPResponse(_body='{"id": 29, "error": "Failed: RPC Error: RPC call failed: Failed: Stream is closed"}',buffer=<_io.BytesIO object at 0x7f54f5434590>,code=200,effective_url='http://10.50.64.73:19010/api/sae/',error=None,headers=,reason='OK',request=,request_time=10.032157182693481,time_info={}) ------------------------------------------------------------------------ File: sa/mtmanager.py (Line: 30) Function: run 23 """ 24 Run SA script and wait for result 25 """ 26 if "." in script: 27 # Leave only script name 28 script = script.split(".")[-1] 29 return RPCClient("sae", calling_service="MTManager").script( 30 ==> object.id, script, params, timeout 31 ) 32 33 34 # Run single instance 35 MTManager = MTManagerImplementation() Variables: self = object = params = {} timeout = None script = 'get_inventory' ------------------------------------------------------------------------ File: sa/models/managedobject.py (Line: 252) Function: __call__ 245 class ScriptsProxy(object): 246 class CallWrapper(object): 247 def __init__(self, obj, name): 248 self.name = name 249 self.object = obj 250 251 def __call__(self, **kwargs): 252 ==> return MTManager.run(self.object, self.name, kwargs) 253 254 def __init__(self, obj): 255 self._object = obj 256 self._cache = {} 257 258 def __getattr__(self, name): Variables: self = kwargs = {} ------------------------------------------------------------------------ File: services/discovery/jobs/box/asset.py (Line: 49) Function: handler 42 self.managed = set() # Object ids 43 self.unk_model = {} # name -> model 44 self.lost_and_found = self.get_lost_and_found(self.object) 45 self.get_name = get_solution_from_config("asset_discovery", "get_name") 46 47 def handler(self): 48 self.logger.info("Checking assets") 49 ==> result = self.object.scripts.get_inventory() 50 self.find_managed() 51 # Submit objects 52 for o in result: 53 self.logger.debug("Submit %s", str_dict(o)) 54 self.submit( 55 type=o["type"], number=o.get("number"), Variables: self = ------------------------------------------------------------------------ File: services/discovery/jobs/base.py (Line: 102) Function: run 95 self.logger.info( 96 "Capability '%s' is disabled. Skipping", 97 cn 98 ) 99 return 100 # Run check 101 try: 102 ==> self.handler() 103 except Exception: 104 error_report(logger=self.logger) 105 106 def handler(self): 107 pass 108 Variables: self = ------------------------------------------------------------------------ END OF TRACEBACK 2016-02-03 20:38:47.346203 [discovery|box|pmo-ar01|vlan] Checking vlans 2016-02-03 20:38:47.346282 [discovery|box|pmo-ar01|vlan] No vc domain. Skipping 2016-02-03 20:38:47.347633 [discovery|box|pmo-ar01|oam] Object hasn't required capability 'Network | OAM'. Skipping 2016-02-03 20:38:47.348472 [discovery|box|pmo-ar01|lldp] Object hasn't required capability 'Network | LLDP'. Skipping 2016-02-03 20:38:47.349329 [discovery|box|pmo-ar01|cdp] Object hasn't required capability 'Network | CDP'. Skipping 2016-02-03 20:38:47.350142 [discovery|box|pmo-ar01|stp] Object hasn't required capability 'Network | STP'. Skipping