question regarding skipping configure-view string in konfd

22 views
Skip to first unread message

Roland Chang

unread,
Nov 9, 2020, 6:54:46 PM11/9/20
to klish
Sorry I think I should post in here not the other group.

Hello, 
For CONFIG tag to write into konfd, I understood that if there are some sub-commands(sub-views) under "configure-view", these sub-command string won't be successfully written into running-config if the "configure terminal" string does not exist there since it is based on depth and build running-config hierarchically.  
ex:
console# configure terminal
console(config)# mirror-session m1 //-> here using <CONFIG> to write the string into kinfd.
//when show running-config:
configure terminal 
    mirrors-ession-m1
       ....
!

My question is :
Since we load the startup-config starting from "configure-view",  we'd like to get rid of "configure terminal" string from the file. Obviously most commands are under configure-view, but during user configuration, if we don't first write "configure terminal" string into konfd, the subsequent command strings won't be able to successfully written into konfd.
Is there a way to  we can manipulate the CONFIG tag or depth attribute or something else to achieve this goal ?
!
mirror-session m1 
  destination erspan....
 mirror-session m2
  destiontion ...
!

kindly advise !
Thank you for your response in advance.
Reply all
Reply to author
Forward

Serj Kalichev

unread,
Nov 10, 2020, 4:24:52 AM11/10/20
to kl...@googlegroups.com
Hi.

You can use appropriate depth="<num>" within VIEW tag. For example we have configure-view with no depth specified (it means 0 by default). Nested VIEWs have depth="1" etc.

We use one instance of klish for "enable-view" and while "configure terminal" we execute new klish instance where configure-view is a "root" view. So there is no "configure terminal" within konfd. This command has no CONFIG tag at all.


10.11.2020 02:54, Roland Chang пишет:
--
You received this message because you are subscribed to the Google Groups "klish" group.
To unsubscribe from this group and stop receiving emails from it, send an email to klish+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/klish/4c0ba91e-e085-454e-bfc1-1e69775c22den%40googlegroups.com.


Roland Chang

unread,
Nov 18, 2020, 5:20:45 PM11/18/20
to klish
Thank you!
Reply all
Reply to author
Forward
0 new messages