<?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: Cisco Prime copy file adding date in Controllers</title>
    <link>https://community.cisco.com/t5/controllers/cisco-prime-copy-file-adding-date/m-p/3989063#M2523</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;I do not think it is possible to do via Prime UI. It allows to add a variable to your script, but its value will be the same for all scheduled instances of the job.&lt;/P&gt;
&lt;P&gt;But this can be done via Prime API. You can add a variable to your CLI template (integer or string) and prepare external script that will deploy this template.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;API:&lt;/P&gt;
&lt;PRE&gt;PUT-/op/cliTemplateConfiguration/deployTemplateThroughJob&lt;/PRE&gt;
&lt;P&gt;Payload sample:&lt;/P&gt;
&lt;PRE&gt;&amp;lt;cliTemplateCommand&amp;gt;
    &amp;lt;templateName&amp;gt;{Name of your template}&amp;lt;/templateName&amp;gt; &lt;BR /&gt;    &amp;lt;targetDevices&amp;gt;
        &amp;lt;targetDevice&amp;gt;
            &amp;lt;targetDeviceID&amp;gt;{ID of your device}&amp;lt;/targetDeviceID&amp;gt;
            &amp;lt;variableValues&amp;gt;
                &amp;lt;variableValue&amp;gt;
                    &amp;lt;name&amp;gt;{Variable name}&amp;lt;/name&amp;gt;
                    &amp;lt;value&amp;gt;{Variable value}&amp;lt;/value&amp;gt;
                &amp;lt;/variableValue&amp;gt;
            &amp;lt;/variableValues&amp;gt;
        &amp;lt;/targetDevice&amp;gt;
    &amp;lt;/targetDevices&amp;gt;
&amp;lt;/cliTemplateCommand&amp;gt;&lt;/PRE&gt;
&lt;P&gt;Hope this helps!&lt;/P&gt;</description>
    <pubDate>Mon, 25 Nov 2019 17:12:32 GMT</pubDate>
    <dc:creator>Alexander Onnikov</dc:creator>
    <dc:date>2019-11-25T17:12:32Z</dc:date>
    <item>
      <title>Cisco Prime copy file adding date</title>
      <link>https://community.cisco.com/t5/controllers/cisco-prime-copy-file-adding-date/m-p/3987308#M2522</link>
      <description>&lt;P&gt;Hello team&lt;/P&gt;&lt;P&gt;I have been two days trying to implement a job and I hope someone can help me or at last tell me there is no way no do it.&lt;/P&gt;&lt;P&gt;I have a capture configured on two Cisco (9500 ans a 9300) devices.&lt;/P&gt;&lt;P&gt;I have made a job on Cisco Prime to launch the capture everyday because there is and issue on my environment that happens randomly but usually at 6:00 am and I don't want to wake up everyday on that time, obviously.&lt;/P&gt;&lt;P&gt;Well, the thing is that I send the job to start and stop the capture ang get the pcaps to analyze, but I want to send it (via ftp, tfp, scp...) in order to not overwrite ir everyday.&lt;/P&gt;&lt;P&gt;What I could't get is sending the copy adding the date to the name, trying to not overwrite every file is made everyday.&lt;/P&gt;&lt;P&gt;Could anybody point me in the good direction?&lt;/P&gt;&lt;P&gt;This is the feature template I made.&lt;/P&gt;&lt;P&gt;It copies the file adding the ip address, but I don't know how to add the date (or a sequence number or something like that) at the end.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Prime template.PNG" style="width: 999px;"&gt;&lt;img src="https://community.cisco.com/t5/image/serverpage/image-id/62024iC2CA40BDA9FD963B/image-size/large?v=v2&amp;amp;px=999" role="button" title="Prime template.PNG" alt="Prime template.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This is the variable:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="imagen.png" style="width: 999px;"&gt;&lt;img src="https://community.cisco.com/t5/image/serverpage/image-id/62025iC9C447F83D4528B7/image-size/large?v=v2&amp;amp;px=999" role="button" title="imagen.png" alt="imagen.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;And this is how it is copied to scp server:&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Prime ficheros.PNG" style="width: 999px;"&gt;&lt;img src="https://community.cisco.com/t5/image/serverpage/image-id/62026i2F74B69060C201A9/image-size/large?v=v2&amp;amp;px=999" role="button" title="Prime ficheros.PNG" alt="Prime ficheros.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Maybe it's possible to make it directly from the switch.&lt;/P&gt;&lt;P&gt;Any help would be welcome.&lt;/P&gt;</description>
      <pubDate>Thu, 21 Nov 2019 15:32:57 GMT</pubDate>
      <guid>https://community.cisco.com/t5/controllers/cisco-prime-copy-file-adding-date/m-p/3987308#M2522</guid>
      <dc:creator>p.juarezponte</dc:creator>
      <dc:date>2019-11-21T15:32:57Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco Prime copy file adding date</title>
      <link>https://community.cisco.com/t5/controllers/cisco-prime-copy-file-adding-date/m-p/3989063#M2523</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;I do not think it is possible to do via Prime UI. It allows to add a variable to your script, but its value will be the same for all scheduled instances of the job.&lt;/P&gt;
&lt;P&gt;But this can be done via Prime API. You can add a variable to your CLI template (integer or string) and prepare external script that will deploy this template.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;API:&lt;/P&gt;
&lt;PRE&gt;PUT-/op/cliTemplateConfiguration/deployTemplateThroughJob&lt;/PRE&gt;
&lt;P&gt;Payload sample:&lt;/P&gt;
&lt;PRE&gt;&amp;lt;cliTemplateCommand&amp;gt;
    &amp;lt;templateName&amp;gt;{Name of your template}&amp;lt;/templateName&amp;gt; &lt;BR /&gt;    &amp;lt;targetDevices&amp;gt;
        &amp;lt;targetDevice&amp;gt;
            &amp;lt;targetDeviceID&amp;gt;{ID of your device}&amp;lt;/targetDeviceID&amp;gt;
            &amp;lt;variableValues&amp;gt;
                &amp;lt;variableValue&amp;gt;
                    &amp;lt;name&amp;gt;{Variable name}&amp;lt;/name&amp;gt;
                    &amp;lt;value&amp;gt;{Variable value}&amp;lt;/value&amp;gt;
                &amp;lt;/variableValue&amp;gt;
            &amp;lt;/variableValues&amp;gt;
        &amp;lt;/targetDevice&amp;gt;
    &amp;lt;/targetDevices&amp;gt;
&amp;lt;/cliTemplateCommand&amp;gt;&lt;/PRE&gt;
&lt;P&gt;Hope this helps!&lt;/P&gt;</description>
      <pubDate>Mon, 25 Nov 2019 17:12:32 GMT</pubDate>
      <guid>https://community.cisco.com/t5/controllers/cisco-prime-copy-file-adding-date/m-p/3989063#M2523</guid>
      <dc:creator>Alexander Onnikov</dc:creator>
      <dc:date>2019-11-25T17:12:32Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco Prime copy file adding date</title>
      <link>https://community.cisco.com/t5/controllers/cisco-prime-copy-file-adding-date/m-p/3989432#M2524</link>
      <description>&lt;P&gt;Hello Alexander,&lt;/P&gt;&lt;P&gt;I appreciate your comment but I have never worked with API.&lt;/P&gt;&lt;P&gt;I don't know how to do that steps or even where to start.&lt;/P&gt;&lt;P&gt;Could you detail your answer or point me in the good direction?&lt;/P&gt;</description>
      <pubDate>Tue, 26 Nov 2019 11:43:14 GMT</pubDate>
      <guid>https://community.cisco.com/t5/controllers/cisco-prime-copy-file-adding-date/m-p/3989432#M2524</guid>
      <dc:creator>p.juarezponte</dc:creator>
      <dc:date>2019-11-26T11:43:14Z</dc:date>
    </item>
    <item>
      <title>Re: Cisco Prime copy file adding date</title>
      <link>https://community.cisco.com/t5/controllers/cisco-prime-copy-file-adding-date/m-p/3989614#M2525</link>
      <description>&lt;P&gt;Hello!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can start from reading the API documentation. It is available at &lt;A href="https://your-pi/webacs/api/v1/" target="_self"&gt;https://your-pi/webacs/api/v1/&lt;/A&gt;&amp;nbsp;on your PI server. Or you can login to PI, click on the "gear" icon near the user name, and then click on REST APIs menu item.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I recommend to start with&amp;nbsp;Getting Started (&lt;A href="https://your-pi/webacs/api/v1/?id=getting-started" target="_self"&gt;https://your-pi/webacs/api/v1/?id=getting-started&lt;/A&gt;) and&amp;nbsp;Step-by-Step Tutorial (&lt;A href="https://your-pi/webacs/api/v1/?id=tutorials" target="_self"&gt;https://your-pi/webacs/api/v1/?id=tutorials&lt;/A&gt;). There are also few examples in different programming languages.&lt;/P&gt;</description>
      <pubDate>Tue, 26 Nov 2019 16:03:10 GMT</pubDate>
      <guid>https://community.cisco.com/t5/controllers/cisco-prime-copy-file-adding-date/m-p/3989614#M2525</guid>
      <dc:creator>Alexander Onnikov</dc:creator>
      <dc:date>2019-11-26T16:03:10Z</dc:date>
    </item>
  </channel>
</rss>

