I am aware that the names of the CLI nodes and parameters are tied corresponding to the yang container, lists and leaves.
In CLI: – Lin(config)# dhcp defaultLeaseTime PT100S –
Understood that defaultLeaseTime is associated with the dhcpd yang file.
Now, my query is, whether the names and parameters can be modified without any name changes in yang file. If modifiable, where the name mapping needs to be done.
Shall we change the parameter name “defaultLeaseTime” to our own name like “Def_Lease_Time” or something else. and i need to configure defaultLeaseTime like below:
Lin(config)# dhcp Def_Lease_Time PT100S
Actually Def_Lease_Time is the one which am expecting to map exactly to the defaultLeaseTime actually found in dhcpd yang file.
Edit. Experts hinted to me that with the ConfD CLI you can use the tailf:alt-name YANG extension. See reply below.
Another, much more complicated way is to add a second YANG module in which you with a different namespace make it identical to dhcpd.yang module where you just change the names you want to expose over the cli. Then add transform callpoints to the new YANG module and in code register the callpoints and using MAAPI map to the original module.
Now you can export the original module to be visible over NETCONF and the new one over CLI.
This property is used to specify an alternative name for the node in the CLI. It is used instead of the node
name in the CLI, both for input and output.
The alt-name statement can be used in: rpc, leaf, leaf-list, list, container, and refine.