Advertisement
Guest User

Untitled

a guest
Jul 31st, 2015
277
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.17 KB | None | 0 0
  1. noc@noc:/opt/noc$ ./noc debug-script get_version asw2-72-eng
  2. 2015-07-31 09:22:04,538 Using JSON library: cjson
  3. 2015-07-31 09:22:04,551 SSH: Using gmpy
  4. 2015-07-31 09:22:04,664 Connecting to MongoDB {'username': 'noc', 'password': '********', 'db': 'noc'}
  5. 2015-07-31 09:22:04,759 Connecting to MongoDB {'username': 'noc', 'password': '********', 'db': 'noc'}
  6. 2015-07-31 09:22:04,768 Loading PeriodicRegistry
  7. 2015-07-31 09:22:04,780 Registering MetricType
  8. 2015-07-31 09:22:04,788 Loading compiled MIBs
  9. 2015-07-31 09:22:04,788 Loading compiled MIBs from 'cmibs'
  10. 2015-07-31 09:22:04,788 Loading MIB: CISCO-PPPOE-MIB
  11. 2015-07-31 09:22:04,789 Loading MIB: SNMPv2-MIB
  12. 2015-07-31 09:22:04,789 Loading MIB: IP-MIB
  13. 2015-07-31 09:22:04,789 Loading MIB: RFC1213-MIB
  14. 2015-07-31 09:22:04,790 Loading MIB: IF-MIB
  15. 2015-07-31 09:22:04,790 Loading MIB: CISCO-VPDN-MGMT-MIB
  16. 2015-07-31 09:22:04,799 Configuring metric mappings sa.managedobject -> object.{{object.name|qm}}.{{metric_type|qm}}
  17. 2015-07-31 09:22:04,800 Configuring metric mappings inv.interface -> object.{{object.managed_object.name|qm}}.interface.{{object.name|qm}}.{{metric_type|qm}}
  18. 2015-07-31 09:22:04,802 Loading DownloaderRegistry
  19. 2015-07-31 09:22:04,832 Loading ProfileRegistry
  20. 2015-07-31 09:22:06,546 Loading ScriptRegistry
  21. 2015-07-31 09:22:06,657 Adding FTS index for sa.managedobject
  22. 2015-07-31 09:22:06,678 Registering ConnectionType
  23. 2015-07-31 09:22:06,683 Registering ObjectModel
  24. 2015-07-31 09:22:06,686 Registering Capability
  25. 2015-07-31 09:22:06,696 Adding FTS index for vc.vc
  26. 2015-07-31 09:22:06,719 Adding FTS index for ip.vrf
  27. 2015-07-31 09:22:06,722 Adding FTS index for ip.prefix
  28. 2015-07-31 09:22:06,725 Adding FTS index for ip.address
  29. Error: Object not found: asw2-72-eng
  30.  
  31. -----------
  32. noc@noc:/opt/noc$ ./noc debug-script commands sx8-pu76 'commands=["show ver","show module","show int brief"]'
  33. 2015-07-31 09:22:39,221 Using JSON library: cjson
  34. 2015-07-31 09:22:39,226 SSH: Using gmpy
  35. 2015-07-31 09:22:39,283 Connecting to MongoDB {'username': 'noc', 'password': '********', 'db': 'noc'}
  36. 2015-07-31 09:22:39,335 Connecting to MongoDB {'username': 'noc', 'password': '********', 'db': 'noc'}
  37. 2015-07-31 09:22:39,340 Loading PeriodicRegistry
  38. 2015-07-31 09:22:39,349 Registering MetricType
  39. 2015-07-31 09:22:39,352 Loading compiled MIBs
  40. 2015-07-31 09:22:39,352 Loading compiled MIBs from 'cmibs'
  41. 2015-07-31 09:22:39,352 Loading MIB: CISCO-PPPOE-MIB
  42. 2015-07-31 09:22:39,353 Loading MIB: SNMPv2-MIB
  43. 2015-07-31 09:22:39,353 Loading MIB: IP-MIB
  44. 2015-07-31 09:22:39,353 Loading MIB: RFC1213-MIB
  45. 2015-07-31 09:22:39,353 Loading MIB: IF-MIB
  46. 2015-07-31 09:22:39,353 Loading MIB: CISCO-VPDN-MGMT-MIB
  47. 2015-07-31 09:22:39,358 Configuring metric mappings sa.managedobject -> object.{{object.name|qm}}.{{metric_type|qm}}
  48. 2015-07-31 09:22:39,358 Configuring metric mappings inv.interface -> object.{{object.managed_object.name|qm}}.interface.{{object.name|qm}}.{{metric_type|qm}}
  49. 2015-07-31 09:22:39,359 Loading DownloaderRegistry
  50. 2015-07-31 09:22:39,375 Loading ProfileRegistry
  51. 2015-07-31 09:22:40,541 Loading ScriptRegistry
  52. 2015-07-31 09:22:40,676 Adding FTS index for sa.managedobject
  53. 2015-07-31 09:22:40,704 Registering ConnectionType
  54. 2015-07-31 09:22:40,712 Registering ObjectModel
  55. 2015-07-31 09:22:40,714 Registering Capability
  56. 2015-07-31 09:22:40,731 Adding FTS index for vc.vc
  57. 2015-07-31 09:22:40,751 Adding FTS index for ip.vrf
  58. 2015-07-31 09:22:40,754 Adding FTS index for ip.prefix
  59. 2015-07-31 09:22:40,756 Adding FTS index for ip.address
  60. Error: Object not found: sx8-pu76
  61.  
  62.  
  63. ----------
  64. noc@noc:/opt/noc$ ./noc debug-script add_vlan vlan_id=111 name="test" tagged_ports=['1','2'] 10.0.0.1./noc
  65. 2015-07-31 09:23:11,017 Using JSON library: cjson
  66. 2015-07-31 09:23:11,036 SSH: Using gmpy
  67. 2015-07-31 09:23:11,191 Connecting to MongoDB {'username': 'noc', 'password': '********', 'db': 'noc'}
  68. 2015-07-31 09:23:11,330 Connecting to MongoDB {'username': 'noc', 'password': '********', 'db': 'noc'}
  69. 2015-07-31 09:23:11,354 Loading PeriodicRegistry
  70. 2015-07-31 09:23:11,370 Registering MetricType
  71. 2015-07-31 09:23:11,380 Loading compiled MIBs
  72. 2015-07-31 09:23:11,380 Loading compiled MIBs from 'cmibs'
  73. 2015-07-31 09:23:11,382 Loading MIB: CISCO-PPPOE-MIB
  74. 2015-07-31 09:23:11,383 Loading MIB: SNMPv2-MIB
  75. 2015-07-31 09:23:11,383 Loading MIB: IP-MIB
  76. 2015-07-31 09:23:11,384 Loading MIB: RFC1213-MIB
  77. 2015-07-31 09:23:11,384 Loading MIB: IF-MIB
  78. 2015-07-31 09:23:11,384 Loading MIB: CISCO-VPDN-MGMT-MIB
  79. 2015-07-31 09:23:11,390 Configuring metric mappings sa.managedobject -> object.{{object.name|qm}}.{{metric_type|qm}}
  80. 2015-07-31 09:23:11,391 Configuring metric mappings inv.interface -> object.{{object.managed_object.name|qm}}.interface.{{object.name|qm}}.{{metric_type|qm}}
  81. 2015-07-31 09:23:11,395 Loading DownloaderRegistry
  82. 2015-07-31 09:23:11,449 Loading ProfileRegistry
  83. 2015-07-31 09:23:13,410 Loading ScriptRegistry
  84. 2015-07-31 09:23:13,509 Adding FTS index for sa.managedobject
  85. 2015-07-31 09:23:13,521 Registering ConnectionType
  86. 2015-07-31 09:23:13,524 Registering ObjectModel
  87. 2015-07-31 09:23:13,525 Registering Capability
  88. 2015-07-31 09:23:13,528 Adding FTS index for vc.vc
  89. 2015-07-31 09:23:13,538 Adding FTS index for ip.vrf
  90. 2015-07-31 09:23:13,540 Adding FTS index for ip.prefix
  91. 2015-07-31 09:23:13,541 Adding FTS index for ip.address
  92. Traceback (most recent call last):
  93. File "manage.py", line 45, in <module>
  94. execute_from_command_line(sys.argv)
  95. File "/opt/noc/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 443, in execute_from_command_line
  96. utility.execute()
  97. File "/opt/noc/local/lib/python2.7/site-packages/django/core/management/__init__.py", line 382, in execute
  98. self.fetch_command(subcommand).run_from_argv(self.argv)
  99. File "/opt/noc/local/lib/python2.7/site-packages/django/core/management/base.py", line 196, in run_from_argv
  100. self.execute(*args, **options.__dict__)
  101. File "/opt/noc/local/lib/python2.7/site-packages/django/core/management/base.py", line 232, in execute
  102. output = self.handle(*args, **options)
  103. File "/opt/noc/sa/management/commands/debug-script.py", line 429, in handle
  104. v = cPickle.dumps(eval(v, {}, {}))
  105. File "<string>", line 1, in <module>
  106. NameError: name 'test' is not defined
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement