Netconf & SNMP client implementation in Elixir

I am looking for a Netconf client & SNMP client in Elixir. Please suggest me.

For SNMP, I found one old post that dates back to 2019, SNMP Agent Implementation in Elixir. The community suggested using Erlang module and calling it from Elixir. Is there any SNMP client implementation in Elixir itself?

I heard that the Elixir ecosystem is vibrant (community, conferences, etc). My query seems to have not drawn the required attention of the community to be answered. May I request the community to respond?

I mean, the community is quite active indeed but maybe people haven’t engaged with your post because your problem seems to be as easy to answer as visiting hex.pm and searching for “snmp”. :person_shrugging:

2 Likes

There is an snmp agent implementation in OTP, you can read here the general functions and look at guides here.

2 Likes

Thanks @dimitarvp. hex.pm lists 2 SNMP modules. Let me check them. But, it does not list any Netconf modules. I am looking for 2 types of clients - Netconf client and SNMP client.

Thanks @D4no0. Let me explore it further. Do you suggest any example code using this module? How does Elixir code calling Erlang module perform compared to Elixir code directly implementing a functionality?

The tutorials are more than enough to get you started, there is not much you need to know about using erlang libraries in elixir:

  1. Calling an erlang function is as simple as :snmp.bits_to_octet_string();
  2. Be careful about differences between charlist and binaries that are used in elixir as strings, you can easily convert between them by using List.to_string/1 and String.to_charlist/1;
  3. There is absolutely no overhead when calling erlang code in elixir, as elixir by itself gets compiled to erlang.

I would strongly recommend you to use this library as it is years more advanced and better maintained than any equivalent libraries in elixir, as erlang was designed and used extensively in telecom, all OTP libraries are battle tested and implemented by the standards.

3 Likes

Thanks @D4no0. Please share the tutorial link. Let me explore as you suggested.

I am looking for SNMP and Netconf Managers (aka Clients). For SNMP Manager, I found that Erlang has a module snmpm and an example manager snmp_ex2_manager.erl

However, I do not find any Netconf Manager implemented in Erlang. It has a Common-test module ct_netconfc which consists of common-test aspect and Netconf protocol aspect. I am exploring the possibilities of extracting the Netconf protocol aspect from ct_netconfc to arrive at a Netconf Manager. Any thoughts on this?

The guides provided should cover your needs. As for netconf, I have no idea since I never used it, you could try to extract it, however it might require a good amount of time.

1 Like

Thanks @D4no0. Let me check SNMP Manager in the SNMP User Guide