# Enter Configuration mode
# remove old syslog server
no logging 192.168.1.11
# add new syslog server
# save current configuration
I have made this easier using this simple Python script. All we need is to loop this script for every network device executing the same set of commands. Below is a simple bash script (mass_netscript.sh) to achieve this task.
if [ -z "$1" ]
echo "No target file supplied"
if [ -z "$2" ]
echo "No command file supplied"
for target in $( cat $targetfile ); do
$netscript -t $target -u $username -p $passwd -c $commandfile $verbose
Common sense dictates that this bash script should be executed to the same group of network device where the command file is applicable. So all Cisco IOS device should be executed together with this script.
Hope this helps.