- Products
- Learn
- Local User Groups
- Partners
- More
Quantum Spark Management Unleashed!
Introducing Check Point Quantum Spark 2500:
Smarter Security, Faster Connectivity, and Simpler MSP Management!
Check Point Named Leader
2025 Gartner® Magic Quadrant™ for Hybrid Mesh Firewall
HTTPS Inspection
Help us to understand your needs better
CheckMates Go:
SharePoint CVEs and More!
What is the command line script to create object/object group and add object in an object group. Like hundred of objects (IPs).
I am using Checkpoint R80.10.
There is no such CLI script - you have to write your own using CP commands from GAiA clish or the Management API.
mgmt add group name "group_name"
mgmt add host name "host_name_1" ip-address "x.x.x.1" groups.1 "group_name"
mgmt add host name "host_name_2" ip-address "x.x.x.2" groups.1 "group_name"
Thanks! Tested okay.
I need to add 100 new IPs in to group, how can I add in single command?
With 80.10 you cannot or else just create for loop in bash. Starting Mgmt API version 1.6 (R80.40) you can use API call add objects-batch do what you want.
Kind regards,
Arturas Zalenekas
Can you please give full syntex of this command- add objects-batch ( i have 100 ips in .csv file and need to add in group)
I am using R80.40, so i need full command syntex to add 100 jobects in to group.
# cat hosts.csv
name,ip-address,groups
test1,192.2.0.1,gtest
test2,192.2.0.2,gtest
test3,192.2.0.3,gtest
# mgmt_cli -r true add host --batch hosts.csv
Gaia WebUi has a nice UI interface to allow adding routes in batch mode. I always missed a batch mode to add objects directly in SmartConsole. A SmartConsole Extension could solve this of course.
Not working follwoing syntex in R80.40-# mgmt_cli -r true add host --batch hosts.csv
Following syntex working for creating object but if any object existing that time getting error, pls help for this.
mgmt_cli add host --batch filename.csv
You can use the "set-if-exists true" parameter to handle such a situation
It is documented in the management API reference guide
https://sc1.checkpoint.com/documents/latest/APIs/index.html#cli/add-host~v1.8%20
set-if-exists | boolean Default: false |
If another object with the same identifier already exists, it will be updated. The command behaviour will be the same as if originally a set command was called. Pay attention that original object's fields will be overwritten by the fields provided in the request payload! |
Kind Regards
Jim
Danny, I have to add over 200 IPs to an object group, but when I log into the MDS to run the commands mentioned above but get this error (see below) when trying to add an object group. I am Running R81.10.
Any thoughts?
Error:
MGMTXXX You are not logged in to management server, in order to log-in you will need to run "mgmt login user [user name]"
The error message is telling you how to resolve this issue: log into the management server using the specified command.
Note that this is required for any use of the API (including via mgmt and mgmt_cli).
Also note that changes must be published or they will not take effect: https://sc1.checkpoint.com/documents/latest/APIs/index.html#clish/publish~v1.9%20
Leaderboard
Epsum factorial non deposit quid pro quo hic escorol.
User | Count |
---|---|
9 | |
7 | |
3 | |
2 | |
2 | |
2 | |
1 | |
1 |
Wed 03 Sep 2025 @ 11:00 AM (SGT)
Deep Dive APAC: Troubleshooting 101 for Quantum Security GatewaysThu 04 Sep 2025 @ 10:00 AM (CEST)
CheckMates Live BeLux: External Risk Management for DummiesWed 10 Sep 2025 @ 11:00 AM (CEST)
Effortless Web Application & API Security with AI-Powered WAF, an intro to CloudGuard WAFWed 10 Sep 2025 @ 11:00 AM (EDT)
Quantum Spark Management Unleashed: Hands-On TechTalk for MSPs Managing SMB NetworksWed 03 Sep 2025 @ 11:00 AM (SGT)
Deep Dive APAC: Troubleshooting 101 for Quantum Security GatewaysThu 04 Sep 2025 @ 10:00 AM (CEST)
CheckMates Live BeLux: External Risk Management for DummiesWed 10 Sep 2025 @ 11:00 AM (EDT)
Quantum Spark Management Unleashed: Hands-On TechTalk for MSPs Managing SMB NetworksAbout CheckMates
Learn Check Point
Advanced Learning
YOU DESERVE THE BEST SECURITY