ConfD User Community

Is there a netconf request to get all status (operation) data from confd?


#1

Based on rfc6241, will get the configuration data while is used to get both the configuration and status (operation) data.

Is there a netconf request which can get all status (operation) data of the device from the confd ?


#2

<get-data> is a candidate for being implemented with ConfD NETCONF NMDA (RFC 8526) support. Perhaps in a late this year release I hear.

For now, you can, for example, do your own makeshift implementation of a NETCONF <get-data> RPC that takes an XPath expression and returns the output of a maapi_save_config() as anyxml.

maapi_save_config() example using the confd_load tool that you will find the source code for in the ConfD release.

$ pwd
/Users/tailf/confd/examples.confd/webui/basic
$ make all start
...
$ confd_load -dd -F p -O  -p /chassis
TRACE Connected (maapi) to ConfD
starting user session ctxt=system user=system groups=[system]
TRACE MAAPI_START_USER_SESSION  --> CONFD_OK
TRACE MAAPI_START_TRANS  --> CONFD_OK
TRACE MAAPI_SAVE_CONFIG  --> CONFD_OK
TRACE Connected (stream) to ConfD
<config xmlns="http://tail-f.com/ns/config/1.0">
  <chassis xmlns="http://tail-f.com/ns/example/config">
    <slot>
      <id>1</id>
      <interface>
        <name>eth0</name>
        <tx>17696</tx>
        <rx>7071</rx>
      </interface>
      <interface>
        <name>eth1</name>
        <tx>16122</tx>
        <rx>37209</rx>
      </interface>
    </slot>
    <slot>
      <id>2</id>
      <interface>
        <name>vsid1</name>
        <tx>20294</tx>
        <rx>41238</rx>
      </interface>
      <interface>
        <name>vsid2</name>
        <tx>21030</tx>
        <rx>32700</rx>
      </interface>
    </slot>
  </chassis>
TRACE MAAPI_SAVE_CONFIG_RESULT  --> CONFD_OK
</config>
TRACE MAAPI_END_USER_SESSION  --> CONFD_OK

#3

Thank you very much. I will check that.