- Products
- Learn
- Local User Groups
- Partners
- More
MVP 2026: Submissions
Are Now Open!
What's New in R82.10?
10 December @ 5pm CET / 11am ET
Announcing Quantum R82.10!
Learn MoreOverlap in Security Validation
Help us to understand your needs better
CheckMates Go:
Maestro Madness
Hello
Does anybody have a script to create Network Objects in bulk via CLI using dbedit?
I have used the below script to create hosts and it did not work. My device is Smart 1-50 running Gaia R77.30
create host_plain web_server
modify network_objects web_server ipaddr 192.168.1.1
update network_objects web_server
update_all
Thanks in advance
Actual dbedit commands look correct. The question is how do you execute them and what error do you get.
Hopefully you have read the SK Editing the objects_5_0.C file via Check Point database editing utilities
Here's output of your own commands:
[Expert@ms01:0]# dbedit
Enter Server name (ENTER for 'localhost'):
Please enter a command, -h for help or -q to quit:
dbedit> create host_plain web_server
dbedit> modify network_objects web_server ipaddr 192.168.1.111
dbedit> update network_objects web_server
web_server updated successfully.
dbedit> update_all
dbedit> print network_objects web_server
Object Name: web_server
Object UID: {D864991F-7B18-B641-A6E1-503D440952F2}
Class Name: host_plain
Table Name: network_objects
Last Modified by: System
Last Modified from: localhost
Last Modification time: Mon Jun 18 22:05:21 2018
Fields Details
--------------
Kaspars Zibarts show it correctly. You have right syntaxe, but problem must be in execution. I usually pushing configuration from file, so I'm able to add thousands rows at once.
How to run file?
On localhost:
dbedit -s localhost -f /somepath/import-file.txt Under MDS on certain domain:
dbedit -s <domain server IP> -f /somepath/import-file.txt In case you need to add more objects, but some with same names already exist in your database, then you can ingnore errors:
dbedit -s localhost -f /somepath/import-file.txt -ignore_script_failureHere are some simple object code examples (host, network, ip range, group):
Create host 10.0.0.3
create host_plain host10.0.0.3
modify network_objects host10.0.0.3 ipaddr 10.0.0.3
modify network_objects host10.0.0.3 comments "Company Host"
update network_objects host10.0.0.3Create network 10.0.0.128/25
create network net10.0.0.128m25
modify network_objects net10.0.0.128m25 ipaddr 10.0.0.128
modify network_objects net10.0.0.128m25 netmask 255.255.255.128
modify network_objects net10.0.0.128m25 comments "Company network"
update network_objects net10.0.0.128m25Create IP range 10.0.0.2-10.0.0.25
create address_range range10.0.0.2-10.0.0.25
modify network_objects range10.0.0.2-10.0.0.25 ipaddr_first 10.0.0.2
modify network_objects range10.0.0.2-10.0.0.25 ipaddr_last 10.0.0.25
modify network_objects range10.0.0.2-10.0.0.25 comments "server range"
update network_objects range10.0.0.2-10.0.0.25Put all previous to simple group:
create network_object_group branchSubnetGroup
addelement network_objects branchSubnetGroup '' network_objects:host10.0.0.3
addelement network_objects branchSubnetGroup '' network_objects:net10.0.0.128m25
addelement network_objects branchSubnetGroup '' network_objects:range10.0.0.2-10.0.0.25
modify network_objects branchSubnetGroup comments "Group of objects"
update network_objects branchSubnetGroupMore examples you can find in Multi-Domain Security Management R77 Versions Administration Guide . There are examples of rules, renaming, etc.
Best is wait and see what Ravindra Katragadda has to say
i suspected the same but it's good to give people some time to chew on info provided as in turn if you can suss out the problem yourself you might actually remember it instead of someone serving you answer on the plate
But yes all info you provided is correct and helpful of course
Petr Hantak
Thank you so much for such a detailed explanation.
I used the below lines to create a script.
create host_plain Block_80.80.80.80
modify network_objects Block_80.80.80.80 ipaddr 80.80.80.80
update network_objects Block_80.80.80.80
update_allI saved this into a text file.
I copied this file to /var/log/ in the MDS.
Then, I log into MDS, went to the CMA context using mdsenv xx.xx.xx.xx command. Then I ran the below commands
dos2unix /var/log/test.txt
dbedit -local -globallock -f /var/log/test.txt &> test_output.txt
The output file shows the below error.
create <object_type> <object_name>
Error in line: 1
Can you please help me why am I seeing this?
First of all, try to execute the commands manually and see if you get the same error, could it be that object already exists?
SK30383:
That Object doesn't exist. It's a new one.
if I change the update_all to savedb, will it work?
it is an additional command, not a replacement, however it will not remove the error
we recently added a lot of Office 365 hosts and networks and used this format for the host:
create host_plain O365-H-94.245.88.28
modify network_objects O365-H-94.245.88.28 ipaddr 94.245.88.28
update network_objects O365-H-94.245.88.28
update_all
savedb
And this for the networks:
create network O365-N-94.245.120.64_26
modify network_objects O365-N-94.245.120.64_26 ipaddr 94.245.120.64
modify network_objects O365-N-94.245.120.64_26 netmask 255.255.255.192
update network_objects O365-N-94.245.120.64_26
update_all
savedb
These are just the single host and a single network, but if you copy the text above and use VI on the MDS instead of notepad or make sure to use notepad++ or a similar product that can store the file as a linux file so you dont have strange characters in the file.
Double check by doing a cat of you text file on the MDS.
I tried exactly on MDS R77.30 your object and it worked without issues.
Leaderboard
Epsum factorial non deposit quid pro quo hic escorol.
| User | Count |
|---|---|
| 22 | |
| 15 | |
| 7 | |
| 6 | |
| 5 | |
| 5 | |
| 4 | |
| 4 | |
| 4 | |
| 4 |
Fri 12 Dec 2025 @ 10:00 AM (CET)
Check Mates Live Netherlands: #41 AI & Multi Context ProtocolTue 16 Dec 2025 @ 05:00 PM (CET)
Under the Hood: CloudGuard Network Security for Oracle Cloud - Config and Autoscaling!Fri 12 Dec 2025 @ 10:00 AM (CET)
Check Mates Live Netherlands: #41 AI & Multi Context ProtocolTue 16 Dec 2025 @ 05:00 PM (CET)
Under the Hood: CloudGuard Network Security for Oracle Cloud - Config and Autoscaling!Thu 18 Dec 2025 @ 10:00 AM (CET)
Cloud Architect Series - Building a Hybrid Mesh Security Strategy across cloudsAbout CheckMates
Learn Check Point
Advanced Learning
YOU DESERVE THE BEST SECURITY