cancel
Showing results for 
Search instead for 
Did you mean: 
Post a Question
Danny
Pearl

Command to show the number of permitted cores

Jump to solution

I'm looking for Bash command to show the number of permitted (licensed) cores of any Check Point GAiA system, even when CoreXL is not enabled.

Thanks in advance!

1 Solution

Accepted Solutions
Danny
Pearl

Re: Command to show the number of permitted cores

Jump to solution

I created this one-liner:

case `cpstat os | grep "Appliance Name" | tr -s ' ' | cut -c17-21` in Check) grep -c ^processor /proc/cpuinfo;; *) cplic print -p 2>/dev/null | tr ' ' '\n' | grep fw1:6.0:mc_all_ | cut -c 16- | awk '{ sum += $1 } END { print sum }';; esac

and added it to our Common Check Point Commands (ccc) script.

19 Replies
Admin
Admin

Re: Command to show the number of permitted cores

Jump to solution

It’s encoded in the license string, which means cplic print -p should show it.

Danny
Pearl

Re: Command to show the number of permitted cores

Jump to solution

I created this one-liner:

case `cpstat os | grep "Appliance Name" | tr -s ' ' | cut -c17-21` in Check) grep -c ^processor /proc/cpuinfo;; *) cplic print -p 2>/dev/null | tr ' ' '\n' | grep fw1:6.0:mc_all_ | cut -c 16- | awk '{ sum += $1 } END { print sum }';; esac

and added it to our Common Check Point Commands (ccc) script.

Admin
Admin

Re: Command to show the number of permitted cores

Jump to solution

On my system, the above command shows I am licensed for 16 cores, which I know to be false.

My system has two CPSG-CPSM-EVAL licenses, each of which contains 8 cores.

Also, one of the licenses is expired Smiley Happy

Licensed cores are NOT additive, either.

0 Kudos
Danny
Pearl

Re: Command to show the number of permitted cores

Jump to solution

Licensed cores are NOT additive?

What is this SmartUpdate message meaning then:

I added a 4-Core license to an 8-Core Eval license and are told to licensed for 12 cores now. This means licensed cores are additive, no?

0 Kudos
Admin
Admin

Re: Command to show the number of permitted cores

Jump to solution

Technically they're not supposed to be. Smiley Happy

0 Kudos
Danny
Pearl

Re: Command to show the number of permitted cores

Jump to solution

Well.. I can see CoreXL technically using all 12 cores.

0 Kudos

Re: Command to show the number of permitted cores

Jump to solution

might be just a glitch with eval license

0 Kudos

Re: Command to show the number of permitted cores

Jump to solution

Technically this was the only way to license more than 8 cores before bigger core number came out Smiley Happy

0 Kudos
Danny
Pearl

Re: Command to show the number of permitted cores

Jump to solution

I found another issue with my one-liner when SMT is enabled:

The license contains just a string for 8 cores. However, with SMT enabled 16 cores are shown on the system and CoreXL actively uses them. Looks like I need to advance my one-liner a little more.

Re: Command to show the number of permitted cores

Jump to solution

Did you try rebooting this system. Number of cores is checked during boot against the license. Any chance you have had eval and did not reboot after it expired?

0 Kudos

Re: Command to show the number of permitted cores

Jump to solution

In case gateway is using "new" license string where some features cannot be found in cp.macro, it gives you following output:

[Expert@GWA:0]# cplic print -p | tr ' ' '\n' | grep fw1:6.0:mc_all_ | cut -c 16- | awk '{ sum += $1 } END { print sum }'
Warning: Can't find ::CPSB-CTNT in cp.macro. License version might be not compatible
8
‍‍‍
Kind regards,
Jozko Mrkvicka
0 Kudos

Re: Command to show the number of permitted cores

Jump to solution

Its okay, eval license might contain more features than known and supported with the version you use

0 Kudos
Danny
Pearl

Re: Command to show the number of permitted cores

Jump to solution

Jozko Mrkvicka : Could you please try if the following command resolves the Warning message?

cplic print -p 2>/dev/null | tr ' ' '\n' | grep fw1:6.0:mc_all_ | cut -c 16- | awk '{ sum += $1 } END { print sum }'

Re: Command to show the number of permitted cores

Jump to solution

Hi Danny Jung‌,

Yes, it is solved now Smiley Happy

[Expert@GWA:0]# cplic print -p 2>/dev/null | tr ' ' '\n' | grep fw1:6.0:mc_all_ | cut -c 16- | awk '{ sum += $1 } END { print sum }'
8
[Expert@GWA:0]#

You can update CCC with this updated syntax.

Thank you.

Kind regards,
Jozko Mrkvicka
0 Kudos
Danny
Pearl

Re: Command to show the number of permitted cores

Jump to solution

Added in version 3.3 of our Common Check Point Commands (ccc) script.

Re: Command to show the number of permitted cores

Jump to solution

Lol, was about to answer just that

Re: Command to show the number of permitted cores

Jump to solution

Scripting is cool, but why not simplify it, by using the good old CLI command?

fw ctl get int fwlic_num_of_allowed_cores
fwlic_num_of_allowed_cores = 16

0 Kudos
Admin
Admin

Re: Command to show the number of permitted cores

Jump to solution

On my 1490, that command returns 100000 Smiley Happy

On my regular gateway (which runs the standard All-in-One eval), it returns 16.

Re: Command to show the number of permitted cores

Jump to solution

100000 - that's the way to go