Dynamically Populate keywords in config data?

We are trying to populate the keyword dynamically when a user tries to configure. We could see that callpoint does that for operational data, but here we need for config. Is their anyway to dynamically populate parameter when user types a “?” while configuring.


There is a reason why configuration data does not behave as operational data.
The datastore used to store configuration data is a transactional ACID based datastore, while the datastore for operational data is not. The operational datastore does not allow the manager to write to it, and also as you point out, operational data can be read without going through the CDB operational data store through a callpoint.

See for example section “Brief Transaction Theory” and “The Core Engine and CDB Database” here:
Is there a ConfD "Getting Started Guide"? The User Guide is huge!

Thanks I do have the document, I will go through once again. So in short can we conclude that its not possible to dynamically fetch keywords for the config data while configuring ?. If so what would be the better approach to get it working ?.

First let’s make sure we are talking about the same thing. By “keyword” in the CLI I assume you mean node name?
In the example below, is the leaf “id” the keyword you would like to change dynamically?

For example:

container interfaces {
   list traffic {
       key id;
       leaf id { type string; }

Yep you are right, I want this id to be chosen like a leafref from the list of values which I have in my code and would be generated dynamically on different builds. I would like to know what would be the best-way to do the same…

Rereading what you wrote it seems like you refer to the values assigned to the list key node, for example the string value “if0” assigned to the list key node named “id”.

Anyhow, for the values to be changed dynamically when you hit ‘?’ in the CLI (not recommended for programmable networks), you can use a tailf:callpoint on the list and store the list externally in a file for example (outside of ConfD’s CDB database). See ConfD example /examples.confd/intro/6-c_config

Maybe you can also look at completionpoint feature, see ConfD User Guide, chapter 16.12.1. Customizing CLI completion.

Sure Let me check that

2017-03-23T13:12:59.900073-05:00 centos-dev confd[21138]: devel-c bad get_object() return value: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx: counter-name is not a child element

I am getting above error, when I tried to proceed to next element. Now with the config callpoint I am able to dynamically populate for a leaf node to choose, but above is the error when I try to proceed further to config…

my structure

list x {

    tailf-callpoint rcp;
    key name

   leaf name {
     type Name

  leaf id {
    type string...



There is an easier way to do this. Create a list where you want to load the data.

list myRefList {
key name;
leaf name { type string; }

Create a list where you want to refer this.

list myList {
key selectedName;

leaf selectedName { type leafref {
path “/myRefList/name”;

leaf value { type int;}

Now you can load the values of myRefList using init XML files. If you are changing the values of myRefList in new versions, make sure your schema is valid when you upgrade from old version to new.

Regards, Prasanth