Solved

cron job logging

Posted on 2004-09-17
2
408 Views
Last Modified: 2013-12-16
Hi,

I m using RH7.3 -> created a cron job at /etc/cron.d folder

at every interval of 3mins execute a script ->scripts performs a check on 2 file, if it found then write to a file.

from the /var/log/message -> i can see that i perform the job, but it does not write to file after it has checked the 2 file. (by right it should). I set the cron job permission as root & the scripts file has the permission to execute.

how can i enabled the cron job script logging? just to make sure where it goes wrong?

pls advice
0
Comment
Question by:pyloh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 17

Accepted Solution

by:
owensleftfoot earned 50 total points
ID: 12082716
Does  your script contain the full path to any programs or files used? Cron doesnt run with the same environment as root - the path settings will be different.
0
 

Author Comment

by:pyloh
ID: 12082773
Hi,

Yes, that is the main problem. After adding the full path i have no issue.
Thanks.

Cheers
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Using sort and uniq to pare down large syslog 6 73
PHP error function not working on AWS 10 123
The better OS Architecture 13 87
Recover Lacie Edmini data. 11 63
Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
Fine Tune your automatic Updates for Ubuntu / Debian
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

756 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question