8 Replies Latest reply on Apr 4, 2019 12:16 PM by Andrew Waters

    Discovery doesn't attempt an SNMP access

    Ana Lorite
      Share:|

      Hi all,

       

      An ILO Management Controller has the UDP 161 port opened:

       

      [root@SRVMLPRODISCOL02 ~]# sudo nmap -sU ipAddress

      Starting Nmap 7.50 ( https://nmap.org ) at 2019-04-03 10:58 CEST

      Nmap scan report for ipAddress

      Host is up (0.00050s latency).

      Not shown: 998 closed ports

      PORT    STATE SERVICE

      161/udp open  snmp

      623/udp open  asf-rmcp

      MAC Address: A0:B3:CC:EE:5B:88 (Hewlett Packard)

      Nmap done: 1 IP address (1 host up) scanned in 100.68 seconds

       

      A SNMP query from SRVMLPRODISCOL02 works:

       

      [root@SRVMLPRODISCOL02 ~]# /usr/tideway/snmp++/bin/snmpWalk ipAddress -v2c -cpublic

      SNMP++ snmpWalk to ipAddress SNMPV2 Retries=1 Timeout=1000ms Community=public

      1.3.6.1.2.1.1.1.0 = Integrated Lights-Out 4 1.13 Nov 08 2012

      1.3.6.1.2.1.1.2.0 = 1.3.6.1.4.1.232.9.4.10

      1.3.6.1.2.1.1.3.0 = 93 days, 16:11:03.44

      1.3.6.1.2.1.1.4.0 =

      1.3.6.1.2.1.1.5.0 = SRJCEPROVM11.

      1.3.6.1.2.1.1.6.0 = unknown

      1.3.6.1.2.1.2.1.0 = 8

      1.3.6.1.2.1.2.2.1.1.1 = 1

      1.3.6.1.2.1.2.2.1.1.2 = 2

      1.3.6.1.2.1.2.2.1.1.3 = 3

      1.3.6.1.2.1.2.2.1.1.4 = 4

      1.3.6.1.2.1.2.2.1.1.5 = 5

      1.3.6.1.2.1.2.2.1.1.6 = 6

      1.3.6.1.2.1.2.2.1.1.7 = 7

      1.3.6.1.2.1.2.2.1.1.8 = 8

      1.3.6.1.2.1.2.2.1.2.1 = HP Ethernet 1Gb 4-port 331FLR Adapter

      ... and so on...

       

      The credential test works:

       

       

      But when discovering the IP:

      • the result is success using GET /xmldata
      • the session result list is the following and it doesn't try SNMP.

       

      This is weird. Don't you think? Can you help me?

       

      Regards, Ana.

        • 1. Re: Discovery doesn't attempt an SNMP access
          Andrew Waters

          Change the discovery log level to debug, scan the device and look in tw_svc_discovery.log.

          1 of 1 people found this helpful
          • 2. Re: Discovery doesn't attempt an SNMP access
            Ana Lorite

            Hi Andrew,

             

            Thank you very much.

             

            I've already changed the discovery log level to debug to take a look before my post.

             

            I share with you the result:

             

            INFO: Main_i::getDevice() for A.B.C.D

            DEBUG: Main_i::getDevice() - try cache lookup for A.B.C.D

            DEBUG: Main_i::getDevice() - get new device for A.B.C.D

            INFO: A.B.C.D: Try to get device

            DEBUG: A.B.C.D: device hints = {}

            INFO: A.B.C.D: Try pool heuristic

            DEBUG: Pool Heuristic: A.B.C.D: Checking pool state

            DEBUG: Pool Heuristic: :A.B.C.D: Pool state OK to continue

            INFO: A.B.C.D: Try lastvsphere heuristic

            DEBUG: Last vSphere Heuristic: A.B.C.D: Last vSphere not available (no last_access_method)

            INFO: A.B.C.D: Try lastvcenter heuristic

            DEBUG: Last vCenter Heuristic: A.B.C.D: Last vCenter not available (no last_access_method)

            INFO: A.B.C.D: Try lastlogin heuristic

            DEBUG: Last Login Heuristic: A.B.C.D: Last Login not available (no last_access_method)

            INFO: A.B.C.D: Try lastslave heuristic

            DEBUG: Last Windows Proxy Heuristic: A.B.C.D: not available: no last_access_method

            INFO: A.B.C.D: Try lastwebapi heuristic

            DEBUG: Last Web API Heuristic: A.B.C.D: Last Web API not available (no last_access_method)

            INFO: A.B.C.D: Try last_rest_api heuristic

            DEBUG: Last REST API heuristic: A.B.C.D: Last REST API not available (no last_access_method)

            INFO: A.B.C.D: Try lastsnmp heuristic

            DEBUG: Last SNMP Heuristic: A.B.C.D: Last SNMP not available (no last_access_method)

            INFO: A.B.C.D: Try lastmainview heuristic

            DEBUG: Last Mainview Heuristic: A.B.C.D: Last Mainview not available (no last_access_method)

            INFO: A.B.C.D: Try portscan heuristic

            DEBUG: Port Scan Heuristic: A.B.C.D: Try simple port scan

            DEBUG: nmap opts are ['-sT', '-sU', '-T4', '-PE'], args ['-p', 'T:513,3940,5989,902,135,80,21,22,23,5988,443,U:161']

            DEBUG: run() - looking for pool data ...

            DEBUG: A.B.C.D: No directory /usr/tideway/var/pool/A.B.C.D therefore no data in pool

            DEBUG: A.B.C.D: nmap.run(): scanning

            DEBUG: Adding process 28377 to timeout thread, timeout = 900

            DEBUG: Removing process 28377 from timeout thread

            DEBUG: Starting XML parse ...

            DEBUG: OS selection strategy: HIGHEST ACCURACY

            DEBUG: OS selection strategy: final accuracy = 0%

            DEBUG: OS selection strategy: 0 results

            DEBUG: classify(): processing ''

            INFO: OS Classifier: No identities from OS matching ''

            DEBUG: classify(): Strongest match is {'kind': 'Device', 'weight': 0.0}

            DEBUG: XML parse complete

            DEBUG: A.B.C.D: nmap.run(): Complete status = SUCCESS

            DEBUG: Port Scan Heuristic: A.B.C.D: complete

            INFO: A.B.C.D: Try vsphere heuristic

            DEBUG: vSphere Heuristic: A.B.C.D: No VM auth daemon ports open

            INFO: A.B.C.D: Try vcenter heuristic

            INFO: A.B.C.D: Try unixlogin heuristic

            INFO: A.B.C.D: Try windows heuristic

            INFO: A.B.C.D: Try webapi heuristic

            INFO: Web API Heuristic: A.B.C.D: Try Web API Heuristic

            DEBUG: HP iLO RIBCL: A.B.C.D: getSession: Checking protocol

            DEBUG: HP iLO RIBCL: A.B.C.D: Check credential-less access

            DEBUG: HP iLO RIBCL: A.B.C.D:443: trying xmldata

            DEBUG: HP iLO RIBCL: A.B.C.D: getSession: Identified {'hsi': {'uuid': '686792CZ23030NXW', 'nics': [{'macaddr': 'ac:16:2d:7b:13:4c', 'port': 1}, {'macaddr': 'ac:16:2d:7b:13:4d', 'port': 2}, {'macaddr': 'ac:16:2d:7b:13:4e', 'port': 3}, {'macaddr': 'ac:16:2d:7b:13:4f', 'port': 4}], 'sp': 1, 'sbsn': 'CZ23030NXW      ', 'virtual': {'state': 'Inactive', 'vid': {'bsn': None, 'cuuid': None}}, 'spn': 'ProLiant DL560 Gen8', 'productid': ' 686792-B21      ', 'cuuid': '37363836-3239-5A43-3233-3033304E5857'}, 'mp': {'uuid': 'ILO686792CZ23030NXW', 'ers': 0, 'pwrm': '3.0', 'bblk': '04/11/2012', 'hwri': 'ASIC: 12', 'sso': 0, 'ipm': 1, 'sn': 'ILOCZ23030NXW      ', 'ealert': 1, 'fwri': '1.13', 'st': 1, 'pn': 'Integrated Lights-Out 4 (iLO 4)'}, 'spatial': {'rack_description': 0, 'uoffset': 0, 'rack_cuuid': 0, 'uheight': 200, 'rack_id_pn': 0, 'uposition': 0, 'rack_uheight': 0, 'ulocation': 0, 'discovery_rack': 'Not Supported', 'discovery_data': 'Server does not detect Discovery Services', 'rack_id': 0, 'tag_version': 0, 'cuuid': '37363836-3239-5A43-3233-3033304E5857'}}

            DEBUG: HP iLO RIBCL: A.B.C.D: no credentials found

            DEBUG: HP iLO RIBCL: A.B.C.D: getSession: No credentials

            DEBUG: Web API Heuristic: A.B.C.D: Identified HP iLO RIBCL

            DEBUG: classify(): processing 'Integrated Lights-Out 4 (iLO 4)'

            DEBUG: classify(): Add result from OS HP iLO

            DEBUG: classify(): Strongest match is {'kind': 'ManagementController', 'weight': 0.9, 'os_class': 'Embedded', 'device_type': 'Remote Access Controller', 'os_type': 'HP iLO', 'os_vendor': 'HP'}

            140575120455424: 2019-04-03 13:50:05,481: discovery.heuristics.webapi: DEBUG: Web API Heuristic: A.B.C.D: No session for HP iLO RIBCL, result {'kind': 'ManagementController', 'branch': 'ilo', 'module': 'hp', 'os_class': 'Embedded', 'device_type': 'Remote Access Controller', 'os_type': 'HP iLO', 'os': 'Integrated Lights-Out 4 (iLO 4)', 'os_vendor': 'HP'}

            INFO: A.B.C.D: Got data via webapi heuristic: device kind = ManagementController

            DEBUG: Setting Web API session for device A.B.C.D

            INFO: A.B.C.D: Device klass is <class 'discovery.device.ManagementController_i'>

            DEBUG: Create new validator for 'discovery/host/access'

            DEBUG: 1164: register delay 10.000000, (<bound method Scavenger.scavenge of <common.scavenger.Scavenger object at 0x7fda495c6d10>>, (), {})

            DEBUG: Main_i::_updateDeviceCache() - using new device; total devices now 1

            INFO: finished Main_i::getDevice() for A.B.C.D

            INFO: ManagementController_i::getDeviceInfo() for A.B.C.D

            DEBUG: A.B.C.D: HpIlo::getDeviceInfo()

            DEBUG: A.B.C.D: getDeviceInfo(): Try pool

            DEBUG: A.B.C.D: No directory /usr/tideway/var/pool/A.B.C.D therefore no data in pool

            DEBUG: classify(): processing 'Integrated Lights-Out 4 (iLO 4)'

            DEBUG: classify(): Add result from OS HP iLO

            DEBUG: classify(): Strongest match is {'kind': 'ManagementController', 'weight': 0.9, 'os_class': 'Embedded', 'device_type': 'Remote Access Controller', 'os_type': 'HP iLO', 'os_vendor': 'HP'}

            INFO: finished ManagementController_i::getDeviceInfo() for A.B.C.D

            DEBUG: waiting for 9.952187

            INFO: ManagementController_i::getMACAddresses() for A.B.C.D

            DEBUG: A.B.C.D: HpIlo::getMACAddresses()

            DEBUG: A.B.C.D: getMACAddresses(): Try pool

            DEBUG: A.B.C.D: No directory /usr/tideway/var/pool/A.B.C.D therefore no data in pool

            INFO: finished ManagementController_i::getMACAddresses() for A.B.C.D

            INFO: ManagementController_i::getNetworkInterfaces() for A.B.C.D

            DEBUG: A.B.C.D: HpIlo::getNetworkInterfaces()

            DEBUG: A.B.C.D: getNetworkInterfaces(): Try pool

            DEBUG: A.B.C.D: No directory /usr/tideway/var/pool/A.B.C.D therefore no data in pool

            DEBUG: ManagementController_i::getNetworkInterfaces() for A.B.C.D - Expected exception raised (this is for tracing purposes only)

            Traceback (most recent call last):

              File "./device.py", line 145, in callProxy

              File "/var/tmp/tw-build-32363/tmp/tideway-devices-buildroot/usr/tideway/python/discovery/devices/hp/ilo/__init__.py", line 565, in getNetworkInterfaces

            NoAccessMethod: DiscoveryCORBA.NoAccessMethod(meta=DiscoveryCORBA.MetaData(data=[ModelCORBA.KeyValuePair(key='method_failure_list', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any)), [[CORBA.Any(CORBA.TC_string, 'GET_NETWORK_SETTINGS'), CORBA.Any(CORBA.TC_string, 'No session'), CORBA.Any(CORBA.TC_string, 'HP iLO RIBCL'), CORBA.Any(CORBA.TC_null, None), CORBA.Any(CORBA.TC_null, None), CORBA.Any(CORBA.TC_null, None)]])), ModelCORBA.KeyValuePair(key='method_info_GET_NETWORK_SETTINGS', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any), [CORBA.Any(CORBA.TC_string, 'HP iLO RIBCL'), CORBA.Any(CORBA.TC_null, None), CORBA.Any(CORBA.TC_boolean, False)])), ModelCORBA.KeyValuePair(key='access_results', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any), [])), ModelCORBA.KeyValuePair(key='processing_messages', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any), [])), ModelCORBA.KeyValuePair(key='cmd_status', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any), []))]))

            INFO: finished ManagementController_i::getNetworkInterfaces() for A.B.C.D

            INFO: ManagementController_i::getIPAddresses() for A.B.C.D

            DEBUG: A.B.C.D: HpIlo::getIPAddresses()

            DEBUG: A.B.C.D: getIPAddresses(): Try pool

            DEBUG: A.B.C.D: No directory /usr/tideway/var/pool/A.B.C.D therefore no data in pool

            DEBUG: ManagementController_i::getIPAddresses() for A.B.C.D - Expected exception raised (this is for tracing purposes only)

            Traceback (most recent call last):

              File "./device.py", line 145, in callProxy

              File "/var/tmp/tw-build-32363/tmp/tideway-devices-buildroot/usr/tideway/python/discovery/devices/hp/ilo/__init__.py", line 456, in getIPAddresses

            NoAccessMethod: DiscoveryCORBA.NoAccessMethod(meta=DiscoveryCORBA.MetaData(data=[ModelCORBA.KeyValuePair(key='method_failure_list', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any)), [[CORBA.Any(CORBA.TC_string, 'GET_NETWORK_SETTINGS'), CORBA.Any(CORBA.TC_string, 'No session'), CORBA.Any(CORBA.TC_string, 'HP iLO RIBCL'), CORBA.Any(CORBA.TC_null, None), CORBA.Any(CORBA.TC_null, None), CORBA.Any(CORBA.TC_null, None)]])), ModelCORBA.KeyValuePair(key='method_info_GET_NETWORK_SETTINGS', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any), [CORBA.Any(CORBA.TC_string, 'HP iLO RIBCL'), CORBA.Any(CORBA.TC_null, None), CORBA.Any(CORBA.TC_boolean, False)])), ModelCORBA.KeyValuePair(key='access_results', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any), [])), ModelCORBA.KeyValuePair(key='processing_messages', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any), [])), ModelCORBA.KeyValuePair(key='cmd_status', value=CORBA.Any(orb.create_sequence_tc(bound=0, element_type=CORBA.TC_any), []))]))

            INFO: finished ManagementController_i::getIPAddresses() for A.B.C.D

            DEBUG: Device::clearCache() for A.B.C.D

            DEBUG: Main_i::_removeDevice() for A.B.C.D

            DEBUG: 1164:unregister

            DEBUG: Main_i::_removeDevice() - total devices now 0

            • 3. Re: Discovery doesn't attempt an SNMP access
              Andrew Waters

              Ok - so it has found an HP iLO. Three are not discovered by SNMP because SNMP passes through and delivers results based on the managed host.

              • 4. Re: Discovery doesn't attempt an SNMP access
                Ana Lorite

                Thank you, Andrew. But the truth is I don't know if i understand it.

                 

                Why is the reason for SNMP passing through if the port 161 is opened in the device and Discovery has a SNMP Credential?

                 

                What do you mean with "pass through"? Time out?

                 

                Thank you very much!!

                • 5. Re: Discovery doesn't attempt an SNMP access
                  Andrew Waters

                  I mean that if you ask the HP iLO for interface information using SNMP you can get back the interface information of the Host that it is managing rather than the iLO itself.

                  3 of 3 people found this helpful
                  • 6. Re: Discovery doesn't attempt an SNMP access
                    Bob Anderson

                    Perhpas you need to add an HP iLO Web API credential:

                    1 of 1 people found this helpful
                    • 7. Re: Discovery doesn't attempt an SNMP access
                      Ana Lorite

                      Hi again Andrew,

                       

                      I'm still trying to understand.

                       

                      I had a look here https://docs.bmc.com/docs/display/Configipedia/Supported+SNMP+Devices and I could see this:

                      XML API vs SNMP means that a device can be discovered using XML API or SNMP but not both, right?

                       

                      So, for a HP iLO device, although the 161 UDP port is opened, Discovery will discover this device using XML Api, right? So, I understand that Discovery doesn't need a credential to discover a HP iLO device.

                       

                      In my case, the discovered data is very poor:

                       

                       

                      So, i have to create a HP iLO Web API credential (thanks Bob Anderson) to enhance data enrinchment

                       

                      Am i right?

                       

                      Thank you for your patience.

                       

                      Ana.

                      • 8. Re: Discovery doesn't attempt an SNMP access
                        Andrew Waters

                        As I said previously the SNMP access van provide information from the Host rather than details of the iLO itself hence it wlil not be discovered by SNMP.

                         

                        What information is available from an iLO will depend upon the firmware version and security settings of the iLO.

                         

                        Depending upon the version of Discovery you need a credential which appears in the UI as either a HP iLO Web API or (on older versions) HP iLO RIBCL credential.

                        1 of 1 people found this helpful