Create a Post
cancel
Showing results for 
Search instead for 
Did you mean: 
Harshpal_Bhati
Employee
Employee

Central Script to Perform gateway changes

Hi Everyone ,

 

This could be very useful script for enterprise customer where check point gateways are being managed by MDS or Management server . There are many common changes that needs to be done on individual  gateway , For example configuring syslog ,NTP , SNMP . In many of the cases customer needs to get some information from all individual gateway like version ,Hotfix ,what all blades are enabled .

Script is based on sk85621 and sk101047 . 

 

Below is the bash code for script to run bash / clish command on multiple gateway which has working SIC .

gateway_ip_list.txt  is located in current directory which has IP of all the gateways 

****************************************

[Expert@Management:0]# cat rcommand.sh
#!/bin/bash

echo "Do you want to run bash or clish command"
read shell
echo "please input the $shell command to run on all the gateway"
read input
for dest in $(<gateway_ip_list.txt); do
echo "running the $shell command $input on $dest "

cprid_util -server $dest -verbose rexec -rcmd /bin/$shell -c "$input"
done

[Expert@Management:0]#

********************************************

Please refer the attached pdf .

 

Watch a demo here :

0 Replies

Leaderboard

Epsum factorial non deposit quid pro quo hic escorol.

Upcoming Events

    CheckMates Events