_____/ On Thursday 25 August 2005 00:23, [Karel Kubat] wrote : \_____
> Roy Schestowitz wrote:
>> I have a hard time setting up a job which periodically outputs usage
>> stats. I wish to be able to easily check stats remotely, so every 10
>> minutes the following gets executed:
>> top -b -n 1 >> ~/public_html/caption.txt
>> However, the cron job comes up with the following error:
>> "TERM environment variable not set."
> Weird that top would need to know what TERM it's on.. but anyway, have you
> tried putting
> at the top of your crontab definition? That defines the TERM variable..
> Hope this helps,
Thanks for the reply, Karel. After several days without a reply, I asked a
similar (not copied-and-pasted) question in the Mandrake NG and found a
before calling 'top -b -n 1 >> ~/public_html/caption.txt' I added the
which appears to have done the trick. Declaring a TERM assignment alone
without 'export' seems to be insufficient.