[Error] Invalid settings UNIT 001d PORT1_SNMP Hikvision Error_in_CMD-3 1 Generic 000029 Driver 00000258 (0x102)

HI,

in the log file I have this error. If I try to read a variable with SNMP, I display #BAD. 

The device is a camera (Hikvision). This camera has not public fields (OID start with '.1.3.6.1.2.1') but has only private field (OID start with '.1.3.6.1.4.1').

HELP ME. I don't understand, In the same project I already read other snmp variables of another device and it works.

Thanks

  • Hi Giancarmine,

    According to the driver Help file:

    0x102 SNMP_ERRORSTATUS_NOSUCHNAME: Requested OID (1) does not exist in supported MIB view or (2) is not accessible or (3) a write operation was attempted on a read only MIB variable.

    The error code suggests there is a problem with the SNMP OID of your tag. Can you compare it to the OIDs of other tags/devices that are working?
    For instance is it starting with a dot ('.')?

    Is it the full OID? Sometimes you have to add an extra level (.n) for an index in an array variable.

    Is it the right data type? Although I would expect a different error code if this were the case.

    Is there a mismatch between variable.dbf and snmpvars.dbf (the dbf name you specified in the 'options' field of ports.dbf)

    Is there a OID mismatch in your Citect tags (because of copy/paste actions)? This is not the .1.3.6.1.4.1.* OID SNMP uses, but Citect's unique tag ID that the compiler generates (OID column in variable.dbf). Apply parameter [OID]Reset=1 to fix this.

    Regards,
    Patrick
  • Hi Patrick,
    this Reset =1, i have to insert in citect.ini?
    The OID I'm sure is correct, because I make the get with MIB Broswer and it works.

    Thanks again,
    Giancarmine
  • Yes, parameter [OID]Reset=1 has to be placed in citect.ini (you can use the Computer Setup Editor for this).

    About the SNMP OIDs:
    I believe Citect is somewhat stricter in naming OIDs. If I'm remembering correct, you can read an entire array/structure in MIB Browser while in Citect sometimes you have to drill down to a deeper level to be able to access it.

    Also, did you test with the same community string in Citect and MIB Browser? Normally this is called 'public'.

  • ok, i placed the parameter but nothing. Yes the community string is the same.
    My doubt is that if I put the mouse on the #BAD(graphic) I see failure device. So i don't think that the problem is the OID. If i cancel the OID in another device, on the #BAD i see an another message. It's possible that the problem is the device?
  • The I/O device configuration could be an issue. I once downloaded a SNMPII example project with multiple I/O devices in it.
    Configuration was like this:

    BOARDS definition: 1 board called 'BOARD1'; type 'SNMPII'; address '0'

    PORTS definition: 1 port per device called 'PORT1', 'PORT2', etc.pointing at BOARD1; port numbers were unique; special options field contained a reference to the dbf with the OIDs and variable addresses: 'SNMPVARS1.DBF', 'SNMPVARS2.DBF', etc.

    I/O device definitions:
    'IODev1': number 1; address '192.168.0.99 public'; port 'PORT1'
    'IODev2': number 2; address '192.168.1.215 public'; port 'PORT2'
    etc.

    Variable addresses were unique across all devices (addresses of IODev1 were not used in IODev2 variables).

    Tag names in Variable.dbf must match the NAME field in SNMPVARS*.DBF
    Tag addresses in Variable.dbf must match the INDEX+SNMPTYPE fields in SNMPVARS*.DBF
    I/O device names in Variable.dbf must match the DEVNAME field in SNMPVARS*.DBF
    Data types in Variable.dbf must match the CTYPE field in SNMPVARS*.DBF

    The SNMPNAME, OID, SNMPTYPE and R/W fields in SNMPVARS*.DBF must match the MIB entry you want to read/write.

    I always fill and edit these DBFs in Excel because I never get the MIB2CIT tool to work. I don't know if it is even supported nowadays.
  • Everything matches. I created a new project with only one device (camera Hikvision) but nothing. I also tried to simulate the same error on another device, to understand what caused it, but nothing. I don't have other ideas; i will try with another camera as soon as possible.
  • Then I'm out op options too I'm afraid. You might want to open a support case for this. They might be able to analyze your project without having access to the camera.
  • Hey Patrick,

    I have solved.
    The SCADA could not communicate with it (such a thing), because the camera does not have the public fields .
    So in the file citect.ini I placed
    [SNMPII]
    PORT1_SNMP1.CamHikvision.TestOIDStr = .1.3.6.1.4.1. *
    (the OID of one of his private fields) and everything works.

    Thanks for your help.
  • Nice find!
    That parameter specifies the OID that the driver will use to test the online status of the device.
    Normally the driver tries to read .1.3.6.1.2.1.1.1.0, but your device doesn't have that OID.

    I'm glad it works now.