libnetconf database for configuration

102 views
Skip to first unread message

Adrian Pan

unread,
Apr 14, 2015, 4:12:24 AM4/14/15
to libne...@googlegroups.com
Hi,

I would like to understand that whether the database of libnetconf will store all the configuration in the memory, i.e 100 interfaces have been created, these 100 interfaces will be stored in the configuration file in the disc, whether these 100 interfaces will be stored in the memory in datastore of libnetconf?

thanks
Adrian

Radek Krejčí

unread,
Apr 15, 2015, 1:26:25 AM4/15/15
to Adrian Pan, libne...@googlegroups.com
Hi Adrian,
yes, besides storing data to the disc, libnetconf works with data in a
DOM tree format provided by libxml2 and this tree is loaded in memory.
This is the case of the file datastore implementation, but libnetconf
allows server to have its own, custom implementation. In such a case,
server is supposed to provide callbacs implementing data manipulation
(get-config, edit-config, copy-config etc.) so the server cn implement
the operations without need of having complete DOM tree in memory.

Regards,
Radek

Dne 14.4.2015 v 10:12 Adrian Pan napsal(a):
> --
> You received this message because you are subscribed to the Google
> Groups "libnetconf" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to libnetconf+...@googlegroups.com
> <mailto:libnetconf+...@googlegroups.com>.
> Visit this group at http://groups.google.com/group/libnetconf.
> For more options, visit https://groups.google.com/d/optout.

Adrian Pan

unread,
Apr 15, 2015, 4:27:29 AM4/15/15
to libne...@googlegroups.com, pan...@gmail.com
Hi Radek,

thanks for your quick reply.

I went through the code, I found when libnetconf call getconfig it will load the whole configuration file from the disc only in case the file has been changed.

Now we are testing the libnetconf from the performance and memory consumption point of view, we found if we continue to do the objects creating and deleting, the performance will decrease comparing with the creating and deleting at the first time once the server is bring up.

Do you have any test data about the libnetconf performance and memory usage can be shared?

Thanks
Adrian  

Radek Krejčí

unread,
Apr 15, 2015, 5:20:49 AM4/15/15
to Adrian Pan, libne...@googlegroups.com
Hi Adrian,

we actually don't have any systematic tests for libnetconf, so we will appreciate any help in this area. The increased memory consumption can be caused by some additional needs - e.g. for any edit-config, libnetconf stores the copy (I know, it is stupid, but simple) of previous tree to be able to do rollback. But there should be just one copy (for each datastore) at the time. I run libnetconf (netopeer-server) with valgrind quite regularly, so I believe that memory leaks are not common, but with missing systematic tests, they are possible.

It would be great if you can share the results of your performance tests. Currently, I'm working on design of libnetconf2 and libyang and any feedback from libnetconf and discussion on what is needed and what should be changed from the current state is appreciated.

Regards,
Radek


Dne 15.4.2015 v 10:27 Adrian Pan napsal(a):
To unsubscribe from this group and stop receiving emails from it, send an email to libnetconf+...@googlegroups.com.

Adrian Pan

unread,
Apr 20, 2015, 3:47:29 AM4/20/15
to libne...@googlegroups.com, pan...@gmail.com
Hi Radek,

sorry for late response.

Now the performance and scalability of libnetconf is under the test, we will share with you the detail once we finish the test, also to discuss with you about the possible improvement from our point of view.

thanks
Adrian
Reply all
Reply to author
Forward
0 new messages