Here's a script correction for an obvious mistake that I managed not to spot. In summary, it is:
s/$chkd/$sau/ IOW the script should read: ========================================================================== #!/bin/bash # # Update the Spamassassin rules # sau=/usr/bin/sa-update if [ -x $sau ] then $sau err=$? case $err in 0) echo "Spamassassin rules update completed."; service spamassassin restart; echo "Spamassassin restarted." ;; 1) echo "No Spamassassin rule updates available.";; 2) echo "Spamassassin rules updates available"; echo "Site pre files lint check failed."; echo "Fix the files and try again.";; *) echo "Spamassassin rules update failed: error=$err" esac else echo "Error: $sau does not exist" exit 0 fi ==================================================================== Martin