<?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: C9300 - Kron - cannot execute in non-interactive context in Switching</title>
    <link>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867060#M547468</link>
    <description>&lt;P&gt;Then probably the implamentation of cron consider "cli install add file " as interactive, even though you suppress the necesssity for interactiveness with "prompt-level none"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 04 Jul 2023 14:12:16 GMT</pubDate>
    <dc:creator>Flavio Miranda</dc:creator>
    <dc:date>2023-07-04T14:12:16Z</dc:date>
    <item>
      <title>C9300 - Kron - cannot execute in non-interactive context</title>
      <link>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867044#M547463</link>
      <description>&lt;P&gt;Hello together&lt;BR /&gt;try ios upgrade with kron on c9300, but this will be failed with following syntax:&lt;BR /&gt;&amp;nbsp; &amp;nbsp;---&amp;gt;&amp;gt;"&lt;STRONG&gt;% Interactive command cannot execute in non-interactive context"&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;so please what are for this the best way? i try also to enable guestshell, but from this explained&lt;BR /&gt;error dont found any solution. thanks for possible update.&lt;BR /&gt;--&amp;gt;&lt;/P&gt;&lt;P&gt;conf t&lt;BR /&gt;!&lt;BR /&gt;kron policy-list iosupgrade&lt;BR /&gt;cli install add file flash:cat9k_iosxe.17.06.05.SPA.bin activate commit prompt-level none&lt;BR /&gt;!&lt;BR /&gt;kron occurrence iosupgrade at 13:01 oneshot&lt;BR /&gt;policy-list iosupgrade&lt;BR /&gt;!&lt;BR /&gt;abc-testing0xxxx#sh kron schedule&lt;BR /&gt;Kron Occurrence Schedule&lt;BR /&gt;iosupgrade inactive, will run once in 0 days 00:00:02 at 13:01 on&lt;/P&gt;&lt;P&gt;abc-testing0xxxx#&lt;BR /&gt;*Jul 4 13:01:00.001: Major 1, Minor 0&lt;BR /&gt;*Jul 4 13:01:00.001: Timer Event iosupgrade&lt;BR /&gt;*Jul 4 13:01:00.002: Call parse_cmd 'install add file flash:cat9k_iosxe.17.06.05.SPA.bin activate commit prompt-level none'&lt;BR /&gt;*Jul 4 13:01:00.052: Kron CLI return 0&lt;BR /&gt;'&lt;BR /&gt;**CLI 'install add file flash:cat9k_iosxe.17.06.05.SPA.bin activate commit prompt-level none':&lt;BR /&gt;% Interactive command cannot execute in non-interactive context'&lt;/P&gt;&lt;P&gt;--&lt;BR /&gt;debug kron all&lt;BR /&gt;*Jul 4 13:01:00.052: Major 4, Minor 7&lt;BR /&gt;*Jul 4 13:01:00.052: Respond to end of CLI Process&lt;BR /&gt;*Jul 4 13:01:00.052: Forcing Removing Occur iosupgrade&lt;BR /&gt;*Jul 4 13:01:00.052: Removing Occur iosupgrade&lt;BR /&gt;*Jul 4 13:01:00.052: Removing Policy Name 'iosupgrade'&lt;BR /&gt;abc-testing0xxxx#&lt;BR /&gt;*Jul 4 13:01:00.052: Finished Removing Occurrence iosupgrade&lt;BR /&gt;abc-testing0xxxx#&lt;/P&gt;&lt;P&gt;abc-testing0xxxx#sh kron schedule&lt;BR /&gt;Kron Occurrence Schedule&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jul 2023 13:31:19 GMT</pubDate>
      <guid>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867044#M547463</guid>
      <dc:creator>Maurizio Caloro</dc:creator>
      <dc:date>2023-07-04T13:31:19Z</dc:date>
    </item>
    <item>
      <title>Re: C9300 - Kron - cannot execute in non-interactive context</title>
      <link>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867051#M547465</link>
      <description>&lt;P&gt;not all command allow and work with Kron&lt;BR /&gt;try use EEM instead&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jul 2023 13:57:46 GMT</pubDate>
      <guid>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867051#M547465</guid>
      <dc:creator>MHM Cisco World</dc:creator>
      <dc:date>2023-07-04T13:57:46Z</dc:date>
    </item>
    <item>
      <title>Re: C9300 - Kron - cannot execute in non-interactive context</title>
      <link>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867052#M547466</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/1034731"&gt;@Maurizio Caloro&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;I understand this output "% Interactive command cannot execute in non-interactive context'" as saying that the cron script tried to run the command but at some point it was requested to take a decision (interactive) but the script is "non-interactive"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;The solution I see would be run a script using some language like Expect in association with cron in order to interact with the prompt as necessary.&lt;/P&gt;
&lt;P&gt;Another alternative, less likelly to work, but does not hurt to try, would be run the command on the switch, identify which is the interaction required and then schedule another kron policy-list&amp;nbsp; with the required response.&lt;/P&gt;
&lt;P&gt;For example, if the interaction required is a "Yes" some where, run a kron policy-list&amp;nbsp; only with the command "Yes".&amp;nbsp; But, as I said, never tested and I dont know if will work.&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jul 2023 13:55:42 GMT</pubDate>
      <guid>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867052#M547466</guid>
      <dc:creator>Flavio Miranda</dc:creator>
      <dc:date>2023-07-04T13:55:42Z</dc:date>
    </item>
    <item>
      <title>Re: C9300 - Kron - cannot execute in non-interactive context</title>
      <link>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867058#M547467</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Hello&amp;nbsp;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/178747"&gt;@Flavio Miranda&lt;/a&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks for your quick answer, the syntax "install add file flash:cat9k_iosxe.17.06.05.SPA.bin activate commit &lt;STRONG&gt;prompt-level none"&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;with the syntax "&lt;STRONG&gt;prompt-level none&lt;/STRONG&gt;" no answer will be need and auto-reboot without any input are needed!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jul 2023 14:01:56 GMT</pubDate>
      <guid>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867058#M547467</guid>
      <dc:creator>Maurizio Caloro</dc:creator>
      <dc:date>2023-07-04T14:01:56Z</dc:date>
    </item>
    <item>
      <title>Re: C9300 - Kron - cannot execute in non-interactive context</title>
      <link>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867060#M547468</link>
      <description>&lt;P&gt;Then probably the implamentation of cron consider "cli install add file " as interactive, even though you suppress the necesssity for interactiveness with "prompt-level none"&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jul 2023 14:12:16 GMT</pubDate>
      <guid>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867060#M547468</guid>
      <dc:creator>Flavio Miranda</dc:creator>
      <dc:date>2023-07-04T14:12:16Z</dc:date>
    </item>
    <item>
      <title>Re: C9300 - Kron - cannot execute in non-interactive context</title>
      <link>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867063#M547469</link>
      <description>&lt;P&gt;dont waste your time use EEM or script. it better&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jul 2023 14:16:52 GMT</pubDate>
      <guid>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867063#M547469</guid>
      <dc:creator>MHM Cisco World</dc:creator>
      <dc:date>2023-07-04T14:16:52Z</dc:date>
    </item>
    <item>
      <title>Re: C9300 - Kron - cannot execute in non-interactive context</title>
      <link>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867071#M547470</link>
      <description>&lt;P&gt;ok direction Script, you mean Python? thanks for any possible link....&lt;/P&gt;</description>
      <pubDate>Tue, 04 Jul 2023 14:41:48 GMT</pubDate>
      <guid>https://community.cisco.com/t5/switching/c9300-kron-cannot-execute-in-non-interactive-context/m-p/4867071#M547470</guid>
      <dc:creator>Maurizio Caloro</dc:creator>
      <dc:date>2023-07-04T14:41:48Z</dc:date>
    </item>
  </channel>
</rss>

