Skip to content

RequestFailedError: EndOfMibView: for session.table() against Agent with MIB with a single table #245

@sanielfishawy

Description

@sanielfishawy

To reproduce:

Create an Agent with MIB containing a single table.
Populate the table with rows.

Call session.table against that Agent with the OID of the table.

The final varbinds is an EndOfMibView as follows:

[
  {
    oid: '1.3.6.1.4.53387.0.5.6.112.115.73.100.95.49.801.15.98.97.116.116.101.114.121.95.118.111.108.116.97.103.101',
    type: 4,
    value: <Buffer 76 6f 6c 74 61 67 65 5f 76 61 6c 75 65 5f 30>
  }
]

[
  {
    oid: '1.3.6.1.4.53387.0.5.6.112.115.73.100.95.49.801.15.98.97.116.116.101.114.121.95.118.111.108.116.97.103.101',
    type: 130,
    value: null
  }
]

In the function tableFeedCb (index.js line 2425) this EndOfMibView is interpreted as an error and rather than returning the table the session.table() method returns a RequestFailedError: EndOfMibView:

RequestFailedError: EndOfMibView: 1.3.6.1.4.53387.0.5.6.112.115.73.100.95.49.801.15.98.97.116.116.101.114.121.95.118.111.108.116.97.103.101
      at Session.tableFeedCb (node_modules/net-snmp/index.js:2426:16)
      at Session.subtreeCb (node_modules/net-snmp/index.js:2306:11)
      at Session.walkCb (node_modules/net-snmp/index.js:2622:12)
      at Req.feedCb (node_modules/net-snmp/index.js:1986:8)
      at Session.onSimpleGetResponse [as onResponse] (node_modules/net-snmp/index.js:2179:7)
      at Session.onMsg (node_modules/net-snmp/index.js:2154:7)
      at Socket.emit (node:events:513:28)
      at UDP.onMessage [as onmessage] (node:dgram:933:8)

Metadata

Metadata

Assignees

No one assigned

    Labels

    insufficient informationNeeds submitter to provide more information as per CONTRIBUTING.md guidelines

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions