Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
03-30-2006, 05:59 AM
|
#1
|
Member
Registered: May 2004
Location: Atlanta, GA USA
Distribution: Redhat ES4, FC4, FC5, slax, ubuntu, knoppix
Posts: 155
Rep:
|
Logwatch problem when run from cron
Hi all,
I have a strange one here, this just started failing after a logwatch update for FC4.
I get this message in when this is run from cron:
Can't exec "sendmail": No such file or directory at /usr/sbin/logwatch line 941,
<TESTFILE> line 3.
Can't execute sendmail -t: No such file or directory
Here's the crontab entry, and when I run it manually it works. Any ideas?
0 4 * * * /usr/sbin/logwatch --detail=high --mailto=myemail@myaddress.com
Any help would be much appreciated.
I don't run sendmail, I use postfix if this helps.
|
|
|
03-30-2006, 06:48 AM
|
#2
|
Senior Member
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141
Rep: 
|
It sounds like the update overwrote the logwatch.conf file (on my system it's in /etc/log.d/conf/logwatch.conf). What is the mailer set to in your conf file?
|
|
|
03-30-2006, 07:07 AM
|
#3
|
Member
Registered: Oct 2004
Distribution: At home: Ubuntu, Debian Sarge
Posts: 56
Rep:
|
I'm not sure this will help but one thing to be aware of is that the environment that cron uses to execute tasks is (mostly) empty. You might find that logwatch is assuming that sendmail is in the path but PATH isnt set.
Try putting this at the top of your crontab and see if it works then:
replacing SENDMAIL_PATH with the path to sendmail
|
|
|
03-31-2006, 06:48 AM
|
#4
|
Member
Registered: May 2004
Location: Atlanta, GA USA
Distribution: Redhat ES4, FC4, FC5, slax, ubuntu, knoppix
Posts: 155
Original Poster
Rep:
|
I noticed in the logwatch.conf it has sendmail as the defaul mailer it uses sendmail -t. Since I am usung postfix, what should the default mailer be? Or should I commnet out that line?
|
|
|
03-31-2006, 01:21 PM
|
#5
|
Senior Member
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 14.0
Posts: 4,141
Rep: 
|
I'd just change it to whatever the full path to postfix is and see if that fixes the problem.
|
|
|
04-05-2006, 07:07 PM
|
#6
|
Member
Registered: May 2004
Location: Atlanta, GA USA
Distribution: Redhat ES4, FC4, FC5, slax, ubuntu, knoppix
Posts: 155
Original Poster
Rep:
|
Thanks..
That fixed it. Once it had the correct path to sendmail it worked like a champ.
|
|
|
All times are GMT -5. The time now is 02:03 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|