<?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: scp with cprid_util in API / CLI Discussion</title>
    <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99221#M5242</link>
    <description>&lt;DIV class=""&gt;
&lt;P&gt;Try this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;for i in `grep 'sic_name\|ipaddr' $FWDIR/conf/objects.C|grep -A1 sic_name|grep 'ipaddr '|tr -d ':ipadr ()\t'`; do cprid_util -server $i -verbose rexec -rcmd /bin/clish -c "show configuration"; done &amp;gt; gaia_backup_all_$(date +%Y%m%d%H%M)&lt;/LI-CODE&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;/DIV&gt;</description>
    <pubDate>Thu, 15 Oct 2020 14:17:12 GMT</pubDate>
    <dc:creator>Danny</dc:creator>
    <dc:date>2020-10-15T14:17:12Z</dc:date>
    <item>
      <title>scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99210#M5238</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I'm looking for an easy way to get the Gaia config from multiple gateways and store in one place. My ideas was to try this with cpdir_util. I tried:&lt;/P&gt;&lt;P&gt;`$CPDIR/bin/cprid_util -server $IP -timeout 5 -verbose rexec -rcmd /bin/clish -s -c 'save configuration $GW'`&lt;BR /&gt;Where GW is a variable, this just saved the config with the name $GW in /&lt;/P&gt;&lt;P&gt;Not getting this to work I just used a fixed name&lt;/P&gt;&lt;P&gt;`$CPDIR/bin/cprid_util -server $IP -timeout 5 -verbose rexec -rcmd /bin/clish -s -c 'save configuration test_steve'`&lt;BR /&gt;This saves the file in /&lt;/P&gt;&lt;P&gt;So next I wanted to copy it to the management server&lt;/P&gt;&lt;P&gt;`$CPDIR/bin/cprid_util -server $IP -timeout 5 -verbose rexec -rcmd bash -c "scp /test_steve &lt;A href="mailto:adminNXO@MGMT_IP:/home/admin/CP_migration/@GW&amp;quot;`" target="_blank"&gt;adminNXO@MGMT_IP:/home/admin/CP_migration/@GW"`&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Trying to rename it during the scp. This doesn't work and even when just trying a fixed name the copy isn't done.&lt;/P&gt;&lt;P&gt;Anyone has any way to do this?&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Thu, 15 Oct 2020 13:16:57 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99210#M5238</guid>
      <dc:creator>Steve_Vandegaer</dc:creator>
      <dc:date>2020-10-15T13:16:57Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99214#M5239</link>
      <description>&lt;P&gt;The error you are making here is that the $GW variable is inside the brackets, that will just be moved over as text as within Clish you cannot use a normal variable this will not work at all.&lt;/P&gt;
&lt;P&gt;The second time you will be able to use a variable but is that a variable available locally on the gateway or is it only on the management server that you are running cprid_util from? For the latter, you should try to move the variable outside the brackets so it will be converted first.&lt;/P&gt;
&lt;P&gt;Hope it makes sense.&lt;/P&gt;</description>
      <pubDate>Thu, 15 Oct 2020 13:45:34 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99214#M5239</guid>
      <dc:creator>Maarten_Sjouw</dc:creator>
      <dc:date>2020-10-15T13:45:34Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99215#M5240</link>
      <description>&lt;P&gt;Ok but even this command doesn't do the copy&lt;/P&gt;&lt;P&gt;`$CPDIR/bin/cprid_util -server $IP -timeout 5 -verbose rexec -rcmd bash -c "scp /test_steve &lt;A href="mailto:adminNXO@MGMT_IP:/home/adminNXO/CP_migration/&amp;quot;`" target="_blank"&gt;adminNXO@MGMT_IP:/home/adminNXO/CP_migration/"`&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Here I would expect to see the file test_steve in the folder on the mgmt&lt;/P&gt;</description>
      <pubDate>Thu, 15 Oct 2020 13:51:38 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99215#M5240</guid>
      <dc:creator>Steve_Vandegaer</dc:creator>
      <dc:date>2020-10-15T13:51:38Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99221#M5242</link>
      <description>&lt;DIV class=""&gt;
&lt;P&gt;Try this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;for i in `grep 'sic_name\|ipaddr' $FWDIR/conf/objects.C|grep -A1 sic_name|grep 'ipaddr '|tr -d ':ipadr ()\t'`; do cprid_util -server $i -verbose rexec -rcmd /bin/clish -c "show configuration"; done &amp;gt; gaia_backup_all_$(date +%Y%m%d%H%M)&lt;/LI-CODE&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;/DIV&gt;</description>
      <pubDate>Thu, 15 Oct 2020 14:17:12 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99221#M5242</guid>
      <dc:creator>Danny</dc:creator>
      <dc:date>2020-10-15T14:17:12Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99222#M5243</link>
      <description>&lt;P&gt;Any way to replace gaia_backup_all with the hostname of the gw it takes a backup from?&lt;/P&gt;</description>
      <pubDate>Thu, 15 Oct 2020 14:18:51 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99222#M5243</guid>
      <dc:creator>Steve_Vandegaer</dc:creator>
      <dc:date>2020-10-15T14:18:51Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99230#M5245</link>
      <description>&lt;DIV class=""&gt;
&lt;P&gt;Sure, just split &lt;FONT color="#3366FF"&gt;&lt;EM&gt;gaia_backup_all&lt;/EM&gt;&lt;/FONT&gt; into single confguration files like this:&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;csplit -z gaia_backup_all /\#\ Configuration/ '{*}'; for i in xx*; do mv $i $(head -1 $i|awk 'NF&amp;gt;1{print $NF}'); done&lt;/LI-CODE&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 15 Oct 2020 15:26:18 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/99230#M5245</guid>
      <dc:creator>Danny</dc:creator>
      <dc:date>2020-10-15T15:26:18Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/100162#M5263</link>
      <description>&lt;P&gt;Thanks a lot, this saves me a lot of work.&lt;/P&gt;</description>
      <pubDate>Mon, 26 Oct 2020 15:17:37 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/100162#M5263</guid>
      <dc:creator>Steve_Vandegaer</dc:creator>
      <dc:date>2020-10-26T15:17:37Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/100171#M5264</link>
      <description>&lt;P&gt;Hi &lt;a href="https://community.checkpoint.com/t5/user/viewprofilepage/user-id/9433"&gt;@Steve_Vandegaer&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;use this script:&lt;/P&gt;
&lt;P&gt;&lt;SPAN class="lia-message-read"&gt;&lt;A class="page-link lia-link-navigation lia-custom-event" href="https://community.checkpoint.com/t5/General-Topics/Easy-Backup-Tool-migrate-export-all-GAIA-configs/td-p/79632/jump-to/first-unread-message" target="_blank" rel="noopener"&gt;Easy Backup Tool - (migrate export + all GAIA configs)&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;This tool creates a backup of &lt;STRONG&gt;all GAIA gateway configurations&lt;/STRONG&gt; with one CLI command "&lt;STRONG&gt;ebackup&lt;/STRONG&gt;" and more other functions!&lt;/P&gt;
&lt;P&gt;Only one CLI command "ebackup"&lt;BR /&gt;- Backup of all Gaia gateway configurations (Check Point appliances, Open Server, SMB appliances 11xx, 14xx)&lt;BR /&gt;- Migrate export on SMS&lt;BR /&gt;- Migrate-server on MDS&lt;BR /&gt;- Backup all files to one TGZ file&lt;BR /&gt;- FTP upload support backup file&lt;BR /&gt;- CP upload support for backup file via cprid_util&lt;/P&gt;
&lt;P&gt;or&lt;/P&gt;
&lt;P&gt;&lt;A href="https://community.checkpoint.com/t5/Enterprise-Appliances-and-Gaia/GAIA-Easy-execute-CLI-commands-on-all-gateways-simultaneously/m-p/50883/highlight/true#M3783" target="_self"&gt;Easy execute CLI commands on all gateways simultaneously&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 26 Oct 2020 16:14:29 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/100171#M5264</guid>
      <dc:creator>HeikoAnkenbrand</dc:creator>
      <dc:date>2020-10-26T16:14:29Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/119223#M5871</link>
      <description>&lt;P&gt;Does this script select all gateways, including those that are members of a cluster?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 24 May 2021 04:50:34 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/119223#M5871</guid>
      <dc:creator>Simon_Macpherso</dc:creator>
      <dc:date>2021-05-24T04:50:34Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/167797#M7410</link>
      <description>&lt;P&gt;Does this only work for R80 versions? I tried it on R81.20 and I get an error [NULL BUF]&lt;/P&gt;</description>
      <pubDate>Fri, 13 Jan 2023 17:35:57 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/167797#M7410</guid>
      <dc:creator>DTaylor</dc:creator>
      <dc:date>2023-01-13T17:35:57Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/176062#M7572</link>
      <description>&lt;P&gt;yes it seems R81.x will need some mods to the script&lt;/P&gt;</description>
      <pubDate>Fri, 24 Mar 2023 11:50:12 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/176062#M7572</guid>
      <dc:creator>SCSupport</dc:creator>
      <dc:date>2023-03-24T11:50:12Z</dc:date>
    </item>
    <item>
      <title>Re: scp with cprid_util</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/176083#M7573</link>
      <description>&lt;P&gt;"(NULL BUF)" means CPRID tried to do something which didn't work. Any number of things can cause this. Do you have any other firewall between the management server and the firewalls it manages?&lt;/P&gt;</description>
      <pubDate>Fri, 24 Mar 2023 13:49:02 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/scp-with-cprid-util/m-p/176083#M7573</guid>
      <dc:creator>Bob_Zimmerman</dc:creator>
      <dc:date>2023-03-24T13:49:02Z</dc:date>
    </item>
  </channel>
</rss>

