[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [FW-1] Need Help with log switch script
> Greetings, > I found a cron job script on the nokia site that switches the > log and mail > the log of dropped pakets to me. But of course I am having > problems getting > this script to run properly. > It is running on a Nokia IP300 running IPSO 3.3.1-FCS7. This > is the script: > #!/bin/sh > source/var/etc/pm_profile > cd /var/fw/log > #Filename will include date > PERIOD='date +%d%m%y' You need to replace the two quotes with back-quotes: PERIOD=`date +%d%m%y` > /opt/pkg/FireWall-1-strong.v4.1.SP-3.ipso-3.3/bin/fw logswitch $PERIOD > # output logfile to comma seperated file. > /opt/pkg/FireWall-1-strong.v4.1.SP-3.ipso-3.3/bin/fw > logexport -d, -i$PERIOD.log -oyesterday.log -n > # Search for all dropped packets > ATTACK=$PERIOD.attack > grep "drop"yesterday.log>>$ATTACK I whould have changed this to: grep ",drop," yesterday.log >> $ATTACK If not, you may get some accept messages in the $ATTACK file (a hostname may contain the word "drop" but not ",drop,"). =============================================== To unsubscribe from this mailing list, please see the instructions at http://www.checkpoint.com/services/mailing.html ===============================================
|