Mailing List Archive

analog-help: Problems uncompressing log file in cron job
Hello,

I have a script which calls analog numerous times to process different sets of log files. I have been using this script as a cron job successfully for years now (updating it everytime I upgrade analog -- I'm currently using 3.0), without any problems on my Slackware Linux machine. I recently attempted to use this script on my RedHat 5 Linux machines, and it worked as expected. That is, until I ran it in cron.

When running the script in cron, analog does not successfully decompress my compressed log files. I have tried many remedies, including (but not limited to) explicitly nameing the path to zcat in my 'UNCOMPRESS' directive, explicitly exporting the PATH environment variable in my front-end script, and calling analog directly from a cron entry. ALL of these yield the same results -- analog executes, processes the uncompressed log files, and returns errors regarding all the compressed log files :

-----
/usr/sbin/analog: Warning F: Problems uncompressing logfile
/var/www/logs/access_log.0.gz
(For help on all errors and warnings, see docs/errors.html)
/usr/sbin/analog: Warning F: Problems uncompressing logfile
/var/www/logs/access_log.1.gz
/usr/sbin/analog: Warning F: Problems uncompressing logfile
/var/www/logs/access_log.2.gz
-----

The strangest thing of all is that the data looks correct. I can't verify this for sure, but it may work anyway.

Any idea why this might be occurring?

Thanks,


David Pisoni -- <david@cnation.com>
CyberNation -- <http://www.cnation.com/>
310/689-3170 -- 310/689-3174 (fax)

"If God lived on Earth, people would knock out all His windows."
-- Yiddish saying


--------------------------------------------------------------------
This is the analog-help mailing list. To unsubscribe from this
mailing list, send mail to analog-help-request@lists.isite.net
with "unsubscribe analog-help" in the main BODY OF THE MESSAGE.
--------------------------------------------------------------------
Re: analog-help: Problems uncompressing log file in cron job [ In reply to ]
On Mon, 30 Nov 1998, David Alan Pisoni wrote:

> When running the script in cron, analog does not successfully decompress
> my compressed log files. I have tried many remedies, including (but not
> limited to) explicitly nameing the path to zcat in my 'UNCOMPRESS'
> directive, explicitly exporting the PATH environment variable in my
> front-end script, and calling analog directly from a cron entry.

The only other thing I can think of is making sure that zcat is
universally executable.

> The strangest thing of all is that the data looks correct. I can't
> verify this for sure, but it may work anyway.
>

You could verify it by only analysing the compressed ones and see what
happens.

The warning is generated if pclose returns a non-zero error code. This is
normally if the command didn't exist. I'm not sure if there could be
another reason which would mean that the data was in fact uncompressed and
read successfully.

>
> "If God lived on Earth, people would knock out all His windows."
> -- Yiddish saying
>

Or send him to the gallows on a trumped-up charge?

--
Stephen Turner sret1@cam.ac.uk http://www.statslab.cam.ac.uk/~sret1/
Normally: Statistical Laboratory, 16 Mill Lane, Cambridge CB2 1SB, England
Until 12/98: Dept of Math & Stats, 585 King Edward Ave, Ottawa K1N 6N5, Canada
Microsoft: Where am I allowed to go today?


--------------------------------------------------------------------
This is the analog-help mailing list. To unsubscribe from this
mailing list, send mail to analog-help-request@lists.isite.net
with "unsubscribe analog-help" in the main BODY OF THE MESSAGE.
--------------------------------------------------------------------
Re: analog-help: Problems uncompressing log file in cron job [ In reply to ]
>On Mon, 30 Nov 1998, David Alan Pisoni wrote:
>
>> When running the script in cron, analog does not successfully decompress
>> my compressed log files. I have tried many remedies, including (but not
>> limited to) explicitly nameing the path to zcat in my 'UNCOMPRESS'
>> directive, explicitly exporting the PATH environment variable in my
>> front-end script, and calling analog directly from a cron entry.
>
>The only other thing I can think of is making sure that zcat is
>universally executable.
>

Oh it is. And it apparently is working, since the data all show up.

>> The strangest thing of all is that the data looks correct. I can't
>> verify this for sure, but it may work anyway.
>>
>
>You could verify it by only analysing the compressed ones and see what
>happens.
>
>The warning is generated if pclose returns a non-zero error code. This is
>normally if the command didn't exist. I'm not sure if there could be
>another reason which would mean that the data was in fact uncompressed and
>read successfully.
>

That is odd, I know. Especially since it works under the command line. Well, I was just wondering if you had heard of it before...

>>
>> "If God lived on Earth, people would knock out all His windows."
>> -- Yiddish saying
>>
>
>Or send him to the gallows on a trumped-up charge?
>

<G>



David Pisoni -- <david@cnation.com>
CyberNation -- <http://www.cnation.com/>
310/689-3170 -- 310/689-3174 (fax)

"For any belief, no matter how palpably absurd you find it, there is or has been a proponent who is smarter than you." - Craig Neumeier



--------------------------------------------------------------------
This is the analog-help mailing list. To unsubscribe from this
mailing list, send mail to analog-help-request@lists.isite.net
with "unsubscribe analog-help" in the main BODY OF THE MESSAGE.
--------------------------------------------------------------------