3 Replies Latest reply on Jan 31, 2017 5:16 PM by HerrDoktor

    adding/removing/updating Nodes via SDK - SNMPv3 issues

    HerrDoktor

      Hi Guys,

      I created an Import script for a client that is using a csv file as an Import source for an NCM-only installation.

      A while ago we updated to NCM 7.5 and now the client is complaining that the script is causing errors. Since I try to log everything and I count the errors and display them in the log, it seems that the script never runs without producing errors.

       

      I did some research and analyzed the error and found that the issue is only with node modification and always related to SNMPv3 properties.

       

      Here is a snippet how I define my Properties and the CMDlet that fails afterwards:

       

      #Set Modified Node Properties
                    $ModNodeProps = @{
                          EntityType="Orion.Nodes";
                          IPAddress=$($entry.IP_ADRESSE);
                          IPAddressGUID= $GUID.ToString()
                          Caption=$($entry.KOMPONENTE);
                          DynamicIP=$False;
                          NodeDescription="";
                          EngineID=$EngineID;
                          Status=1;
                          UnManaged=$False;
                          Allow64BitCounters='True';                                      
                          SysObjectID='';   
                          ObjectSubType="SNMP";
                          SNMPVersion=$SNMPVersion;
                          Community=$Community;
                          RediscoveryInterval="5";
                          #NextRediscovery=$NextRediscovery;
                          BufferNoMemThisHour='-2';
                          BufferNoMemToday='-2';
                          BufferSmMissThisHour='-2';
                          BufferSmMissToday='-2';
                          BufferMdMissThisHour='-2';
                          BufferMdMissToday='-2';
                          BufferBgMissThisHour='-2';
                          BufferBgMissToday='-2';
                          BufferLgMissThisHour='-2';
                          BufferLgMissToday='-2';
                          BufferHgMissThisHour='-2';
                          BufferHgMissToday='-2';
                          IOSImage = '';
                          IOSVersion = '';
                          #SNMPV2Only = '0'; bei NCM Modifikation nicht mehr vorhanden
                          CPULoad = '-2';
                          TotalMemory = '-2';
                          MemoryUsed = '-2';
                          PercentMemoryUsed = '-2';                   
                          PollInterval = '3600';
                          StatCollection = '60';
                          #SNMPv3AuthKeyIsPwd  = '1';
                          #SNMPV3AuthKey  = '';
                          #SNMPv3AuthMethod  = '';
                          #SNMPV3Context  = 'None';
                          #SNMPv3PrivKeyIsPwd  = '1';
                          #SNMPv3PrivKey  = '';
                          #SNMPv3PrivMethod = '';
                          #SNMPV3Username  = '';                  
                                             
                       }     
      
      
                     Set-SwisObject $target $targetNodeUri -Properties $ModNodeProps
      

       

      as you can See I am already "playing" around with the SNMPv3 attributes I marked them as comment but they were already being set. (however I do not need those at all -> we use SNMPv2)

       

      I checked the article here Using Orion Credential Set for SNMPv3 when Adding Node through SDK and here Add node with snmpv3 credentials (this seems to be very similar to my issue)

      so it looks like there is a Bug here. However as stated we do not need SNMPv3. So I want to avoid dealing with another script or adding "Discovery Lines" to the existing Script.

      As it only affects Nodes that are being modified can I initialize the SNMPv3 properties in any way that I can update them?

       

      Thanks and kind regards,

      Holger