Created
October 21, 2011 22:08
-
-
Save pivotalcommon/1305104 to your computer and use it in GitHub Desktop.
Arpwatch bihourly.sh modifications; no emails, different paths
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/bihourly.sh b/bihourly.sh | |
index fd273a4..d7da573 100755 | |
--- a/bihourly.sh | |
+++ b/bihourly.sh | |
@@ -6,7 +6,7 @@ | |
PATH=${PATH}:/usr/local/sbin | |
export PATH | |
# | |
-cd /usr/operator/arpwatch | |
+cd /usr/local/arpwatch | |
# | |
list="`cat list`" | |
cname="`cat cname`" | |
@@ -44,22 +44,22 @@ arpsnmp -d ${alist} > ${temp1} 2>&1 | |
sed -e '/arpsnmp: suppressed DECnet flip flop/d' ${temp1} > ${temp2} | |
if [ -s ${temp2} ]; then | |
mail -s "`hostname` arpwatch report" \ | |
- [email protected] < ${temp2} | |
+ [email protected] < ${temp2} | |
fi | |
rm -f ${temp1} ${temp2} | |
-d=/www/NETINFO/arpwatch | |
- | |
-f=arp.dat | |
-cp ${f} ${d} | |
- | |
-f=ethercodes.dat | |
-diff ethercodes.dat ${d} >>/dev/null 2>&1 | |
-if [ $? -ne 0 ]; then | |
- echo Updating ${d}/${f} | |
- cp ${f} ${d} | |
-fi | |
- | |
+#d=/www/NETINFO/arpwatch | |
+# | |
+#f=arp.dat | |
+#cp ${f} ${d} | |
+# | |
+#f=ethercodes.dat | |
+#diff ethercodes.dat ${d} >>/dev/null 2>&1 | |
+#if [ $? -ne 0 ]; then | |
+# echo Updating ${d}/${f} | |
+# cp ${f} ${d} | |
+#fi | |
+# | |
rm ${l} | |
- | |
+# | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment