Re: Webalizer cron syntax

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Hi,

On Fri, Sep 12, 2008 at 01:38, Bob Hoffman <bob@xxxxxxxxxxxxxx> wrote:
> if [ -s /var/log/httpd/mysite1_access_log ]; then exec /usr/bin/webalizer
> -Qc /etc/webalizer/mysite1.conf;
> fi
> if [ -s /var/log/httpd/mysite2_access_log ]; then exec /usr/bin/webalizer
> -Qc /etc/webalizer/mysite2.conf;
> Fi

You have to remove the "exec" from the command lines. "exec" means the
program that will run will replace the script, so no command after
that one will execute on the script.

> If I do not add the fi after each, the file gets an error when I run
> /etc/cron.daily/00webalizer

Yes, you must keep the "fi"s, and I believe they should be lowercase.

HTH,
Filipe
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
http://lists.centos.org/mailman/listinfo/centos

[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux