cpstat

Description

Shows the status and statistics information of Check Point applications.

Syntax

cpstat [-d] [-p <Port>] [-s <SICname>] [-f <Flavor>] [-o <Polling Interval> [-c <Count>] [-e <Period>]] [-x] [-j] <Application Flag>

Parameters

Parameter

Description

-d

Runs the command in debug mode.

Use only if you troubleshoot the command itself.

The output shows the SNMP queries and SNMP responses for the applicable SNMP OIDs.

-p <Port>

Optional.

Port number of the Application Monitoring (AMON) server.

The default port is 18192.

-s <SICname>

Optional.

Secure Internal Communication (SIC) name of the Application Monitoring (AMON) server.

-f <Flavor>

Optional.

Specifies the type of the information to collect.

If you do not specify a flavor explicitly, the command uses the first flavor in the <Application Flag>. To see all flavors, run the cpstat command without any parameters.

-o <Polling Interval>

Optional.

Specifies the polling interval (in seconds) - how frequently the command collects and shows the information.

Examples:

  • 0 - The command shows the results only once and the stops (this is the default value).

  • 5 - The command shows the results every 5 seconds in the loop.

  • 30 - The command shows the results every 30 seconds in the loop.

  • N - The command shows the results every N seconds in the loop.

Use this parameter together with the "-c <Count>" parameter and the "-e <Period>" parameter.

Example:

cpstat os -f perf -o 2

-c <Count>

Optional.

Specifies how many times the command runs and shows the results before it stops.

You must use this parameter together with the "-o <Polling Interval>" parameter.

Examples:

  • 0 - The command shows the results repeatedly every <Polling Interval> (this is the default value).

  • 10 - The command shows the results 10 times every <Polling Interval> and then stops.

  • 20 - The command shows the results 20 times every <Polling Interval> and then stops.

  • N - The command shows the results N times every <Polling Interval> and then stops.

Example:

cpstat os -f perf -o 2 -c 2

-e <Period>

Optional.

Specifies the time (in seconds), over which the command calculates the statistics.

You must use this parameter together with the "-o <Polling Interval>" parameter.

You can use this parameter together with the "-c <Count>" parameter.

Example:

cpstat os -f perf -o 2 -c 2 -e 60

-x

Generates the output in the XML format

-j

Generates the output in the JSON format

<Application Flag>

Mandatory.

See the table below with flavors for the application flags.

These flavors are available for the application flags:

Note - The available flags depend on the enabled Software Blades.

Feature or Software Blade

Flag

Flavors

List of enabled Software Blades

blades

ips, fw, av, amw, vpn, vpn, aspm, ia, apcl, default

Operating System

os

default, ifconfig, routing, routing6, memory, old_memory, cpu, disk, perf, multi_cpu, multi_disk, sensors, power_supply, hw_info, all, average_cpu, average_memory, statistics, updates, licensing, connectivity, vsx

Firewall

fw

default, interfaces, policy, perf, hmem, kmem, inspect, cookies, chains, fragments, totals, totals64, ufp, http, ftp, telnet, rlogin, smtp, pop3, sync, log_connection, all

Application Control

appi

default, subscription_status, update_status, RAD_status, top_last_hour, top_last_day, top_last_week, top_last_month

URL Filtering

urlf

default, subscription_status, update_status, RAD_status, top_last_hour, top_last_day, top_last_week, top_last_month

Anti-Virus

ci

default

Threat Prevention

antimalware

default, scanned_hosts, scanned_mails, subscription_status, update_status, history_av_incidents, history_ab_incidents, history_ab_comp_hosts, history_av_comp_hosts, top_sus_urls, top_countries, ab_prm_contracts, av_prm_contracts, ab_prm_contracts, infected_hosts, ab_prm_contracts, av_prm_contracts

Threat Prevention Statistics

monitoring

all, without_network

Threat Prevention Top Events

topEvents

top_last_hour, top_last_day, top_last_week, top_last_month

Threat Emulation

threat-emulation

default, general_statuses, update_status, scanned_files, malware_detected, scanned_on_cloud, malware_on_cloud, average_process_time, emulated_file_size, queue_size, peak_size, file_type_stat_file_scanned, file_type_stat_malware_detected, file_type_stat_cloud_scanned, file_type_stat_cloud_malware_scanned, file_type_stat_filter_by_analysis, file_type_stat_cache_hit_rate, file_type_stat_error_count, file_type_stat_no_resource_count, contract, downloads_information_current, downloading_file_information, queue_table, history_te_incidents, history_te_comp_hosts

Statistics for some IPS protections

asm

default, WS

IPsec VPN

vpn

default, product, IKE, ipsec, traffic, compression, accelerator, nic, statistics, watermarks, all

QoS

fg

all

High Availability

ha

default, all

Certificate Authority

ca

default, crl, cert, user, all

Anti-Virus

ci

default

Provisioning Agent

PA

default

Provisioning Agent

PAHB

default

Basic Security Gateway Statistics

web_ui

fw, accepted_data, service_count, ips, av, urlf, vpn, aspm

Historical status values

persistency

product, TableConfig, SourceConfig

Return Value

  • 0 - success.

  • 1 - failure.

Output

  • Success shows the output.

  • Failure shows an appropriate error message.

Example 1

[Expert@HostName]# cpstat -f cpu os

CPU User Time (%):   1
CPU System Time (%): 6
CPU Idle Time (%):   93
CPU Usage (%):       7
CPU Queue Length:    -
CPU Interrupts/Sec:  1625
CPUs Number:         4

[Expert@HostName]#

Example 2

[Expert@HostName]# cpstat os -f perf

Total Virtual Memory (Bytes):            2048765952
Active Virtual Memory (Bytes):           770162204
Total Real Memory (Bytes):               2048765952
Active Real Memory (Bytes):              916725760
Free Real Memory (Bytes):                1132040192
Memory Swaps/Sec:                        -
Memory To Disk Transfers/Sec:            -
CPU User Time (%):                       1
CPU System Time (%):                     6
CPU Idle Time (%):                       93
CPU Usage (%):                           7
CPU Queue Length:                        -
CPU Interrupts/Sec:                      1641
CPUs Number:                             4
Disk Servicing Read\Write Requests Time: -
Disk Requests Queue:                     -
Disk Free Space (%):                     83
Disk Total Free Space (Bytes):           52432896
Disk Available Free Space (Bytes):       52432896
Disk Total Space (Bytes):                62914560

[Expert@HostName]#

Example 3

[Expert@HostName]# cpstat -f default fw

Policy name:  local
Install time: Thu Sep 16 15:44:35 2021


Interface table
-------------------------------------------------
|Name    |Dir|Total   |Accept  |Deny    |Log    |
-------------------------------------------------
|WAN     |in | 5211524| 5208364|    3160|3499377|
|WAN     |out| 8388637| 8388336|     301|      0|
|LAN1    |in |       0|       0|       0|      0|
|LAN1    |out|       0|       0|       0|      0|
|LAN3    |in |       0|       0|       0|      0|
|LAN3    |out|       0|       0|       0|      0|
|LAN1.334|in |    1161|    1161|       0|   2386|
|LAN1.334|out|     520|     520|       0|   2534|
|LAN1.348|in | 8323376| 8323344|      32|      0|
|LAN1.348|out|18681816| 5442172|13239644|      1|
-------------------------------------------------
|        |   |40607034|27363897|13243137|3504298|
-------------------------------------------------



Interface table (64-bit)
--------------------------------
|Name|Dir|Total|Accept|Deny|Log|
--------------------------------
--------------------------------



ISP link table
------------------
|Name|Status|Role|
------------------
------------------


[Expert@HostName]#