Create a Post
cancel
Showing results for 
Search instead for 
Did you mean: 
namakasand
Explorer

mgmt_cli bulk operations and CPU usage/throttling?

Hello friends!

I am working on a script that bulk adds hosts and then bulk adds them to a group. I'm using the mgmt_cli 'host' and 'group' commands like so:

 

mgmt_cli -r true add host --batch lots_of_ips.csv

mgmt_cli -r true set group --batch lots_of_ips_2.csv

 

My csv files contain approximately 1200 IPs, and the operations are spiking CPU usage and occasionally crashing the API service.

Is there a way to throttle this command somehow, or is my only option increasing the CPU cores on the management server?

Thank you!

0 Kudos
3 Replies
_Val_
Admin
Admin

Most probably not throttling, but getting timed out. If it takes more than 10 min till processed, API web server will throw a timeout error. Try using up to 500 objects in a list when adding^.

0 Kudos
PhoneBoy
Admin
Admin

From R80.40, you can leverage the add objects-batch command, which is much more performant than running add host --batch.
https://sc1.checkpoint.com/documents/latest/APIs/index.html#cli/add-objects-batch~v1.8%20 

namakasand
Explorer

Thank you for your help guys! We are under 80.40 but updating soon. Until then, I will try the 500 limit.

I appreciate it!

0 Kudos

Leaderboard

Epsum factorial non deposit quid pro quo hic escorol.

Upcoming Events

    CheckMates Events