<?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 Super basic script to check connection to 3 CP update servers in Scripts</title>
    <link>https://community.checkpoint.com/t5/Scripts/Super-basic-script-to-check-connection-to-3-CP-update-servers/m-p/270071#M1468</link>
    <description>&lt;P&gt;Hey guys,&lt;/P&gt;
&lt;P&gt;Below is super basic script to verify connection to below servers:&lt;/P&gt;
&lt;P&gt;Lab:&lt;/P&gt;
&lt;P&gt;[Expert@CP-GW:0]# ./check_cp_updates.sh&lt;BR /&gt;ERROR: Provide a valid server file via -f servers.txt&lt;BR /&gt;Usage:&lt;BR /&gt;./check_cp_updates.sh -f servers.txt [--path /some/path] [--connect-timeout 5] [--max-time 20] [--retries 1] [--parallel 1] [--out results.csv]&lt;/P&gt;
&lt;P&gt;Examples:&lt;BR /&gt;./check_cp_updates.sh -f cp_update_servers.txt&lt;BR /&gt;./check_cp_updates.sh -f cp_update_servers.txt --path / --parallel 5&lt;BR /&gt;[Expert@CP-GW:0]# touch cp_update_servers.txt&lt;BR /&gt;[Expert@CP-GW:0]# vi cp_update_servers.txt&lt;BR /&gt;[Expert@CP-GW:0]# ./check_cp_updates.sh -f cp_update_servers.txt&lt;BR /&gt;Done. Results written to: results_cp_update_servers.csv&lt;BR /&gt;[Expert@CP-GW:0]# more results_cp_update_servers.csv&lt;BR /&gt;timestamp,server,url,http_code,time_total,remote_ip,error&lt;BR /&gt;2026-02-09T09:26:59-0500,updates.checkpoint.com,&lt;A href="https://updates.checkpoint.com/,404,0.126571,18.245.104.81" target="_blank"&gt;https://updates.checkpoint.com/,404,0.126571,18.245.104.81&lt;/A&gt;,""&lt;BR /&gt;2026-02-09T09:26:59-0500,dl3.checkpoint.com,&lt;A href="https://dl3.checkpoint.com/,302,0.081083,23.221.242.130" target="_blank"&gt;https://dl3.checkpoint.com/,302,0.081083,23.221.242.130&lt;/A&gt;,""&lt;BR /&gt;2026-02-09T09:26:59-0500,downloads.checkpoint.com,&lt;A href="https://downloads.checkpoint.com/,301,0.389605,18.67.17.36" target="_blank"&gt;https://downloads.checkpoint.com/,301,0.389605,18.67.17.36&lt;/A&gt;,""&lt;BR /&gt;[Expert@CP-GW:0]#&lt;/P&gt;</description>
    <pubDate>Tue, 17 Feb 2026 13:03:30 GMT</pubDate>
    <dc:creator>the_rock</dc:creator>
    <dc:date>2026-02-17T13:03:30Z</dc:date>
    <item>
      <title>Super basic script to check connection to 3 CP update servers</title>
      <link>https://community.checkpoint.com/t5/Scripts/Super-basic-script-to-check-connection-to-3-CP-update-servers/m-p/270071#M1468</link>
      <description>6</description>
      <pubDate>Tue, 17 Feb 2026 13:03:30 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/Scripts/Super-basic-script-to-check-connection-to-3-CP-update-servers/m-p/270071#M1468</guid>
      <dc:creator>the_rock</dc:creator>
      <dc:date>2026-02-17T13:03:30Z</dc:date>
    </item>
    <item>
      <title>Re: Super basic script to check connection to 3 CP update servers</title>
      <link>https://community.checkpoint.com/t5/Scripts/Super-basic-script-to-check-connection-to-3-CP-update-servers/m-p/270077#M1470</link>
      <description>&lt;P&gt;Thank you for sharing this useful script! I'd like to propose an enhancement to support gateways that don't have direct internet connectivity but are configured with a proxy using something like this:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;get_proxy_config() {
  local proxy_line
  proxy_line="$(clish -c "show configuration proxy" 2&amp;gt;/dev/null | grep "^set proxy address" || true)"
  
  if [[ -n "$proxy_line" ]]; then
    local proxy_ip proxy_port
    proxy_ip="$(echo "$proxy_line" | awk '{print $4}')"
    proxy_port="$(echo "$proxy_line" | awk '{print $6}')"
    
    if [[ -n "$proxy_ip" &amp;amp;&amp;amp; -n "$proxy_port" ]]; then
      echo "${proxy_ip}:${proxy_port}"
      return 0
    fi
  fi
  return 1
}

PROXY_CONFIG="$(get_proxy_config || true)"
export PROXY_CONFIG&lt;/LI-CODE&gt;
&lt;P&gt;&lt;BR /&gt;And then something like this&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;if [[ -n "${PROXY_CONFIG}" ]]; then
  curl_opts+=(--proxy "${PROXY_CONFIG}")
fi&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Feb 2026 15:22:27 GMT</pubDate>
      <guid>https://community.checkpoint.com/t5/Scripts/Super-basic-script-to-check-connection-to-3-CP-update-servers/m-p/270077#M1470</guid>
      <dc:creator>Vincent_Bacher</dc:creator>
      <dc:date>2026-02-09T15:22:27Z</dc:date>
    </item>
  </channel>
</rss>

