<?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: Exporting large group of IPs into a file from mgmt_cli in API / CLI Discussion</title>
    <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242594#M8946</link>
    <description>&lt;P&gt;OK, i would go with the web API - exporting all the objects and reimporting them to smart1cloud. As web API should still be there (another argument necessary "context" if i remember correctly)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 27 Feb 2025 19:23:33 GMT</pubDate>
    <dc:creator>Nüüül</dc:creator>
    <dc:date>2025-02-27T19:23:33Z</dc:date>
    <item>
      <title>Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242586#M8943</link>
      <description>&lt;P&gt;Hey guys,&lt;/P&gt;
&lt;P&gt;Apologies if this may sound like a really silly question, but Im trying to figure out if Im doing this right. To make a long story short, I imported customer's config into my lab and trying to see if I can export large group with about 5000 IPs into csv format file via cli, but not having much luck so far. Below is command I ran:&lt;/P&gt;
&lt;P&gt;mgmt_cli show group name "Block" &amp;gt; block.csv&lt;/P&gt;
&lt;P&gt;It seems like it did take it and after I logged in, its just "sitting" there for 20 mins and file size is not moving at all.&lt;/P&gt;
&lt;P&gt;If someone could confirm if this is correct, would be awesome.&lt;/P&gt;
&lt;P&gt;Tx as always.&lt;/P&gt;
&lt;P&gt;Andy&lt;/P&gt;</description>
      <pubDate>Thu, 27 Feb 2025 20:55:49 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242586#M8943</guid>
      <dc:creator>the_rock</dc:creator>
      <dc:date>2025-02-27T20:55:49Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242592#M8944</link>
      <description>&lt;P&gt;Hi Andy,&lt;/P&gt;&lt;P&gt;did you try to execute it without redirecting to a file?&lt;/P&gt;&lt;P&gt;what exactly do you want/need to achieve?&amp;nbsp;&lt;/P&gt;&lt;P&gt;as output would be like this:&lt;/P&gt;&lt;LI-SPOILER&gt;- uid: "ff7ae4dc-9f1e-4c1e-af2b-217a6834083c"&lt;BR /&gt;name: "net_auto_feed_zoom-221.122.64.0-24"&lt;BR /&gt;type: "network"&lt;BR /&gt;domain:&lt;BR /&gt;uid: "41e821a0-3720-11e3-aa6e-0800200c9fde"&lt;BR /&gt;name: "SMC User"&lt;BR /&gt;domain-type: "domain"&lt;BR /&gt;subnet4: "221.122.64.0"&lt;BR /&gt;mask-length4: 24&lt;BR /&gt;subnet-mask: "255.255.255.0"&lt;BR /&gt;icon: "NetworkObjects/network"&lt;BR /&gt;color: "blue"&lt;/LI-SPOILER&gt;&lt;P&gt;&amp;nbsp;when having so much objects, maybe using async-response would help&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-SPOILER&gt;mgmt_cli --session-id sid --format json show group async-response true name groupname ( maybe some jq magic like&lt;EM&gt;| jq .tasks[0]&lt;/EM&gt; and so on) &amp;gt; out.txt&lt;/LI-SPOILER&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Feb 2025 19:17:20 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242592#M8944</guid>
      <dc:creator>Nüüül</dc:creator>
      <dc:date>2025-02-27T19:17:20Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242593#M8945</link>
      <description>&lt;P&gt;Hey&amp;nbsp;&lt;a href="https://community.checkpoint.com/t5/user/viewprofilepage/user-id/1663"&gt;@Nüüül&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Tx a lot for responding, appreciated! Yes, without redirecting to a file, works fine, but reason why I need a file is because we are trying to get right CSV file that can be imported into S1C portal for the customer, but only TAC can do it, since there is no regular ssh access.&lt;/P&gt;
&lt;P&gt;Andy&lt;/P&gt;</description>
      <pubDate>Thu, 27 Feb 2025 19:19:49 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242593#M8945</guid>
      <dc:creator>the_rock</dc:creator>
      <dc:date>2025-02-27T19:19:49Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242594#M8946</link>
      <description>&lt;P&gt;OK, i would go with the web API - exporting all the objects and reimporting them to smart1cloud. As web API should still be there (another argument necessary "context" if i remember correctly)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Feb 2025 19:23:33 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242594#M8946</guid>
      <dc:creator>Nüüül</dc:creator>
      <dc:date>2025-02-27T19:23:33Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242595#M8947</link>
      <description>&lt;P&gt;Do you have an example? I tried exporting from smart console, but does NOT let you export only single group, even from object explorer : - (&lt;/P&gt;
&lt;P&gt;Andy&lt;/P&gt;</description>
      <pubDate>Thu, 27 Feb 2025 19:29:31 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242595#M8947</guid>
      <dc:creator>the_rock</dc:creator>
      <dc:date>2025-02-27T19:29:31Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242596#M8948</link>
      <description>&lt;P&gt;how urgent is this? can send you something tomorrow if thats ok?&lt;/P&gt;</description>
      <pubDate>Thu, 27 Feb 2025 19:30:59 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242596#M8948</guid>
      <dc:creator>Nüüül</dc:creator>
      <dc:date>2025-02-27T19:30:59Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242597#M8949</link>
      <description>&lt;P&gt;Its not urgent, no rush. Im just trying to see if I can get this exported from the lab, but so far, no luck.&lt;/P&gt;
&lt;P&gt;Andy&lt;/P&gt;</description>
      <pubDate>Thu, 27 Feb 2025 19:33:37 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242597#M8949</guid>
      <dc:creator>the_rock</dc:creator>
      <dc:date>2025-02-27T19:33:37Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242611#M8950</link>
      <description>&lt;P&gt;My colleague, who is Linux GENIUS (everyone says that about him), helped me figure it out. Anyway, creds are just my lab, so you get an idea &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;He will also send me info how he converted the file to fit into when you try import hosts into another mgmt.&lt;/P&gt;
&lt;P&gt;mgmt_cli show group -u admin -p 'maxwe!!' name "Block" &amp;gt; blockips.csv --format json&lt;/P&gt;
&lt;P&gt;Command to import the file:&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;mgmt_cli add host --batch block.csv&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Example (it HAS TO look like something below)&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;#cat test.csv&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;name,ip-address&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;obj1,192.168.1.1&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Btw, here is example how to get right file format that can be used right away to add via mgmt_cli:&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;example for hosts, but you get an idea for ranges or subnets:&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;mgmt_cli -r true show-group name "Block" --format json | jq '.members[] | [.name, ."ipv4-address"] | @csv' -r &amp;gt;&amp;gt; ip_block_test.csv&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in;"&gt;&lt;SPAN&gt;---&amp;gt;To add address-range via API&lt;/SPAN&gt;&lt;SPAN&gt;:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;mgmt_cli add address-range --batch address-ranges_full.csv&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;#cat address-ranges_full.csv&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;name,ip-address-first,ip-address-last&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;range1,10.0.0.0,10.0.0.100&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: 'Segoe UI'; font-size: 11.25pt; color: #2f2f2f;"&gt;&lt;SPAN&gt;---&amp;gt; To add a network via API:&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;mgmt_cli add network --batch networks.csv&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;#cat networks.csv&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;name,subnet,subnet-mask&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;network1,10.10.10.0,255.255.255.0&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;network2,20.20.20.0,255.255.255.0&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;network3,30.30.30.0,255.255.255.0&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: 'Segoe UI'; font-size: 11.25pt; color: #2f2f2f;"&gt;&lt;SPAN&gt;---&amp;gt; To add a host&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;mgmt_cli add host --batch test.csv&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;#cat test.csv&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;name,ip-address&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;obj1,192.168.1.1&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Hope this saves a headache for whoever has to do this in the future &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P style="margin: 0in; font-family: Calibri; font-size: 11.0pt;"&gt;Andy&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Feb 2025 23:51:38 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242611#M8950</guid>
      <dc:creator>the_rock</dc:creator>
      <dc:date>2025-02-27T23:51:38Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242728#M8951</link>
      <description>&lt;P&gt;&lt;A href="https://github.com/leinadred/sh_ckp-xfer-groups" target="_blank"&gt;https://github.com/leinadred/sh_ckp-xfer-groups&lt;/A&gt;&lt;/P&gt;&lt;P&gt;maybe at least a little starting point.&amp;nbsp; &amp;nbsp;&lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 28 Feb 2025 22:16:18 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242728#M8951</guid>
      <dc:creator>Nüüül</dc:creator>
      <dc:date>2025-02-28T22:16:18Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242729#M8952</link>
      <description>&lt;P&gt;Tx mate, will definitely test it Monday.&lt;/P&gt;
&lt;P&gt;Have an awesome weekend &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Andy&lt;/P&gt;</description>
      <pubDate>Fri, 28 Feb 2025 22:26:15 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242729#M8952</guid>
      <dc:creator>the_rock</dc:creator>
      <dc:date>2025-02-28T22:26:15Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242754#M8953</link>
      <description>&lt;P&gt;Thanks, you too..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;additionally - i checked about the smart-1 cloud api. import to / export from there is possible, see README at the repo. it´s working - at least what i was able to test.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;(currently only works with new to-create network objects/hosts. maybe will adjust that at a later moment. )&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 01 Mar 2025 17:31:47 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242754#M8953</guid>
      <dc:creator>Nüüül</dc:creator>
      <dc:date>2025-03-01T17:31:47Z</dc:date>
    </item>
    <item>
      <title>Re: Exporting large group of IPs into a file from mgmt_cli</title>
      <link>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242757#M8954</link>
      <description>&lt;P&gt;TAC told me as long as they can get right CSV file, they can import it easily, so I think we are good.&lt;/P&gt;
&lt;P&gt;Tx &amp;nbsp;a lot!&lt;/P&gt;
&lt;P&gt;Andy&lt;/P&gt;</description>
      <pubDate>Sun, 02 Mar 2025 02:06:26 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/API-CLI-Discussion/Exporting-large-group-of-IPs-into-a-file-from-mgmt-cli/m-p/242757#M8954</guid>
      <dc:creator>the_rock</dc:creator>
      <dc:date>2025-03-02T02:06:26Z</dc:date>
    </item>
  </channel>
</rss>

