<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Contributing custom applications for NTP configuration in Tools</title>
    <link>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585206#M3281</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Nice job Craig.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 18 Aug 2016 22:16:32 GMT</pubDate>
    <dc:creator>aradford</dc:creator>
    <dc:date>2016-08-18T22:16:32Z</dc:date>
    <item>
      <title>Contributing custom applications for NTP configuration</title>
      <link>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585205#M3280</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just got my first YDK contribution merged (thanks for the awesome assistance&amp;nbsp; &lt;A href="https://community.cisco.com//people/saalvare"&gt;saalvare&lt;/A&gt; )!&amp;nbsp; We started with a relatively easy target with NTP.&amp;nbsp; Contributed two applications.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;nc-create-config-ip-ntp-20-ydk.py - IPv4 server&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;nc-create-config-ip-ntp-22-ydk.py - IPv4 server with source interface and update-calendar knob&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can view them at:&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-external-small" href="https://git.io/v6KQ2" rel="nofollow" target="_blank"&gt;https://git.io/v6KQ2&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Give them a try and let me know if you have any comments.&amp;nbsp; While we tested them on a lab environment, I also tested them to a VIRL XRv router as well that I am using as a sandbox.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To offer some input, one thing I found useful, is viewing the CLI configuration inside an XML format (using a NETCONF client).&amp;nbsp; This approach provided me a nice visual of the YANG model command hierarchy/tree, including for referencing the YDK API documents.&amp;nbsp; Give this a try.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;One last thing I would add is, I am a 21 year CCIE, so this network programmability is still relatively new (last 18 months or so I have been focusing more), and I would encourage all of the network engineers to start poking around in this stuff, including GitHub.&amp;nbsp; The YDK developers have done an awesome job in making the use of YANG models much easier with these API's that are generated.&amp;nbsp; There is always a learning curve of course, and while it is different than CLI, you can see the power of automation and scalable network element changes with this tool set and NC/YANG.&amp;nbsp; I am hoping to start targeting more YDK contributions that focus on my customer use cases, so this should be one of several applications I plan to contribute.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Aug 2016 21:53:49 GMT</pubDate>
      <guid>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585205#M3280</guid>
      <dc:creator>crhill@cisco.com</dc:creator>
      <dc:date>2016-08-18T21:53:49Z</dc:date>
    </item>
    <item>
      <title>Re: Contributing custom applications for NTP configuration</title>
      <link>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585206#M3281</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Nice job Craig.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Aug 2016 22:16:32 GMT</pubDate>
      <guid>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585206#M3281</guid>
      <dc:creator>aradford</dc:creator>
      <dc:date>2016-08-18T22:16:32Z</dc:date>
    </item>
    <item>
      <title>Re: Contributing custom applications for NTP configuration</title>
      <link>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585207#M3282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the contribution.&amp;nbsp; Very much appreciated.&amp;nbsp; We're getting close to 200 sample apps! &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Aug 2016 22:37:23 GMT</pubDate>
      <guid>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585207#M3282</guid>
      <dc:creator>saalvare</dc:creator>
      <dc:date>2016-08-18T22:37:23Z</dc:date>
    </item>
    <item>
      <title>Re: Contributing custom applications for NTP configuration</title>
      <link>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585208#M3283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am very new to YDK and experimenting with configuration in a lab environment. Let me ask a silly question : how do I know if configuration was successful ? I get no error message, however debugging YFW on router displays the below error - well, actually a warning :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RP/0/0/CPU0:Sep 14 10:42:03.565 : netconf[1113]: WRN: YFW: ctx=1000da90,sysdb_find_data returned an error: 'sysdb' detected the 'warning' condition 'A SysDB client tried to access a nonexistent item or list an empty directory', sysdb_path: 'cfg/gl/ip-ntp/peer/default/ipv4/08080808/'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I understand that the configuration I am trying is not valid, but still, how do I find it out only via YDK app ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Sep 2016 18:33:14 GMT</pubDate>
      <guid>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585208#M3283</guid>
      <dc:creator>franklaszlo</dc:creator>
      <dc:date>2016-09-14T18:33:14Z</dc:date>
    </item>
    <item>
      <title>Re: Contributing custom applications for NTP configuration</title>
      <link>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585209#M3284</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;All apps have a command line option to enable logging (-v | --verbose).&amp;nbsp; You bring up a good point of adding more details on how to debug the app and validate the results.&amp;nbsp; I've created an issue to add more details on that:&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/CiscoDevNet/ydk-py-samples/issues/74" title="https://github.com/CiscoDevNet/ydk-py-samples/issues/74"&gt;Add details on app execution and debugging · Issue #74 · CiscoDevNet/ydk-py-samples · GitHub&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If there's any error in your configuration, YDK will raise an exception.&amp;nbsp; It may do so because local validation of your configuration failed (e.g. your config object is not compliant with the model) or because an error was received form the NETCONF/YANG agent running on the router.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's an example of debugging one of Craig's apps:&lt;/P&gt;&lt;PRE&gt;
&lt;P&gt;$ ./nc-create-config-ip-ntp-20-ydk.py -h&lt;/P&gt;
&lt;P&gt;usage: nc-create-config-ip-ntp-20-ydk.py [-h] [-v] device&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;positional arguments:&lt;/P&gt;
&lt;P&gt;&amp;nbsp; device&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; NETCONF device (ssh://user:password@host:port)&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;optional arguments:&lt;/P&gt;
&lt;P&gt;&amp;nbsp; -h, --help&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; show this help message and exit&lt;/P&gt;
&lt;P&gt;&amp;nbsp; -v, --verbose&amp;nbsp; print debugging messages&lt;/P&gt;
&lt;P&gt;$&lt;/P&gt;
&lt;P&gt;$&lt;/P&gt;
&lt;P&gt;$ ./nc-create-config-ip-ntp-20-ydk.py ssh://xxxx:xxxx@pavarotti -v&lt;/P&gt;
&lt;P&gt;2016-09-14 13:06:04,575 - ydk.providers.netconf_provider - INFO - NetconfServiceProvider connected to pavarotti:None using ssh&lt;/P&gt;
&lt;P&gt;2016-09-14 13:06:04,586 - ydk.providers.NetconfServiceProvider - DEBUG -&lt;/P&gt;
&lt;P&gt;****************************&lt;/P&gt;
&lt;P&gt;&amp;lt;rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:aa9454f8-7ab6-11e6-8c95-081196796e8c"&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;lt;edit-config&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;target&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;candidate/&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/target&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;config xmlns:xc="urn:ietf:params:xml:ns:netconf:base:1.0"&amp;gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ntp xmlns="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://cisco.com/ns/yang/Cisco-IOS-XR-ip-ntp-cfg" rel="nofollow" target="_blank"&gt;http://cisco.com/ns/yang/Cisco-IOS-XR-ip-ntp-cfg&lt;/A&gt;&lt;SPAN&gt;"&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;peer-vrfs&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;peer-vrf&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;vrf-name&amp;gt;default&amp;lt;/vrf-name&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;peer-ipv4s&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;peer-ipv4&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;address-ipv4&amp;gt;10.0.0.1&amp;lt;/address-ipv4&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;peer-type-ipv4&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;peer-type&amp;gt;server&amp;lt;/peer-type&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/peer-type-ipv4&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/peer-ipv4&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/peer-ipv4s&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/peer-vrf&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/peer-vrfs&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/ntp&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/config&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;lt;/edit-config&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;/rpc&amp;gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;2016-09-14 13:06:04,701 - ydk.providers.NetconfServiceProvider - DEBUG -&lt;/P&gt;
&lt;P&gt;&amp;lt;?xml version="1.0"?&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;rpc-reply message-id="urn:uuid:aa9454f8-7ab6-11e6-8c95-081196796e8c" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;ok/&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;/rpc-reply&amp;gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;2016-09-14 13:06:04,701 - ydk.providers.NetconfServiceProvider - DEBUG -&lt;/P&gt;
&lt;P&gt;&amp;lt;rpc xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="101"&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;lt;commit/&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;/rpc&amp;gt;&lt;/P&gt;
&lt;P&gt;2016-09-14 13:06:05,016 - ydk.providers.NetconfServiceProvider - DEBUG -&lt;/P&gt;
&lt;P&gt;&amp;lt;?xml version="1.0"?&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;rpc-reply message-id="urn:uuid:aa9454f8-7ab6-11e6-8c95-081196796e8c" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;ok/&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;/rpc-reply&amp;gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;****************************&lt;/P&gt;
&lt;P&gt;2016-09-14 13:06:05,017 - ydk.services.crud_service - INFO - CREATE operation completed&lt;/P&gt;
&lt;P&gt;2016-09-14 13:06:05,247 - ydk.providers.netconf_provider - INFO -&lt;/P&gt;
&lt;P&gt;NetconfServiceProvider disconnected from pavarotti:None using ssh&lt;/P&gt;
&lt;P&gt;$&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;

&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Sep 2016 20:19:20 GMT</pubDate>
      <guid>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585209#M3284</guid>
      <dc:creator>saalvare</dc:creator>
      <dc:date>2016-09-14T20:19:20Z</dc:date>
    </item>
    <item>
      <title>Re: Contributing custom applications for NTP configuration</title>
      <link>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585210#M3285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks for the answer Santiago.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In fact, the logger shows the below line:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2016-09-15 12:02:14,066 - ydk.services.crud_service - INFO - CREATE operation completed&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And got the answer :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;?xml version="1.0"?&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;rpc-reply message-id="1" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;ok /&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;/rpc-reply&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But in reality the configuration did not complete.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Create request was the following:&lt;/P&gt;&lt;P&gt;&lt;IMG alt="1.png" class="image-1 jive-image" src="https://community.cisco.com/legacyfs/online/fusion/100214_1.png" style="height: 400px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;So actually I am unable to detect configuraiton errors.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Sep 2016 10:21:58 GMT</pubDate>
      <guid>https://community.cisco.com/t5/tools/contributing-custom-applications-for-ntp-configuration/m-p/3585210#M3285</guid>
      <dc:creator>franklaszlo</dc:creator>
      <dc:date>2016-09-15T10:21:58Z</dc:date>
    </item>
  </channel>
</rss>

