| CPUG | |
| The Check Point User Group | |
| A Resource For The Check Point Community. Fast. Useful. Independent. | |
|
| |||||||
![]() |
| | LinkBack | Thread Tools | Display Modes |
| |||
| Hi, I'm in the process of upgrading a R55 SPLAT box to R62. Now all of the routes on the firewall are static routes. Is there a way to copy over a file which contains all the static routes? From what I gathered, the routes on the R55 box are stored in /etc/sysconfig/cpnetstart file and on the R62 box, the routes are stored in /etc/sysconfig/netconf.C. Now the formats of these files are definitely different. If there were only a couple of routes, it wouldn't be a problem to type them out again, however some of the firewalls which we will be upgrading have in excess of 100 static routes which can become a nightmare to type in again. Is there a way to convert the one file to the other or is there another way to go about doing this? Thanks Nolan |
| |||
| you can go this way: at the source system in expert mode do: Code: netstat -rn | grep ^[0-9] | awk '{printf "route add -net %-15s gw %-15s netmask %s\n", $1, $2, $3}' | sort > R55_routing_table Code: route add -net 10.1.1.0 gw 10.0.0.2 netmask 255.255.255.0 route add -net 10.1.2.0 gw 10.0.0.2 netmask 255.255.255.0 transfer the file to the new gateway and in expert mode: sh ./R55_routing_table_reviewed then do an route -save and it is done |
| |||
| sorry, the command is Code: route --save if you would like to have the interfaces documented in the dump change the command to this: file: dump_routes_to_restore_file.sh Code: #!/bin/sh
netstat -rn \
| grep ^[0-9] \
| awk '{printf "route add -net %-15s gw %-15s netmask %-18s # %s\n", $1, $2, $3, $8}' \
| sort -n -k6,6 |
| |||
| This is a great script that worked like a champ for me. We're upgrading from R55 to R65 and I just used this script to backup the routes in our live environment and import them into our test lab. Again, worked great! Thanks for the script. I was going to create by own bash script when I found this one and it saved me some time!! P.S. This is my first time to this site and I feel like I've been missing out already as I've supported a checkpoint cluster for a few years now. |
| |||
| We asked Checkpoint TAC how to backup and restore routes and this is there answer: Quote:
Quote:
I just thought I'd share the Checkpoint responses with everyone. I've never been to thrilled with Checkpoint's support. |
![]() |
| Thread Tools | |
| Display Modes | |
| |