Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
Go Back   Zimbra :: Forums > Zimbra Collaboration Suite > Administrators

Welcome to the Zimbra :: Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-20-2009, 05:35 PM
Active Member
 
Posts: 39
Default [SOLVED] logwatch emails

My original installation of zimbra 18 months ago was configured with the FQN host name as the mail domain--zimbra.scoe.org. I then created the actual mail domain--scoe.org--and added users. Realizing that the mail hostname "zimbra.scoe.org" was a lame duck, I hunted down the global settings that were made in that empty domain, and put them under mail hostname "scoe.org." After waiting 6 month for problems to appear (none did, till now), I deleted the mail host "zimbra.scoe.org."

Delivery of logwatch emails stopped. They had been sent by "logwatch@zimbra.scoe.org" to "root@zimbra.scoe.org. " How do I correct these sender/recipient settings? I have combed /opt/zimbra to no avail.
Reply With Quote
  #2 (permalink)  
Old 05-21-2009, 05:22 PM
Active Member
 
Posts: 46
Default

Mail server should have a hostname different from the mail domain. using the email domain as hostname is not a good idea. If you want to change the hostname in the zimbra configuration. follow the link below. Of course you still have to configure the hostname for your sytem first. The link only handle hostname configuration in the zimbra installation.

ZmSetServerName - Zimbra :: Wiki

Of course, that wasn't your question.
To fix your issue, you can do one of following.
1. recreate the zimbra.scoe.org domain and add the root@zimbra.scoe.org and logwatch@zimbra.scoe.org as an aliases of of the account you want to recive those emails.
or
2. create an alias domain zimbra.scoe.org and forward all emails to scoe.org.
This gets a nice side effect of every account in scoe.org also receive for zimbra.scoe.org. so depend on if want behavior you want.

Last edited by thorng; 05-21-2009 at 05:25 PM.. Reason: typo
Reply With Quote
  #3 (permalink)  
Old 05-22-2009, 01:37 PM
Active Member
 
Posts: 39
Default

Thanks for the input. In a similar post, forum user phoenix stated that logwatch parameters are not made by zimbra, but are set by the Linux utility logwatch itself. The config file on our RHEL 5.3 box is /usr/share/logwatch/default.conf/logwatch.conf. The MailTo and MailFrom settings are in this file, and can be email addresses or usernames. Making these settings, my logwatch emails resumed last night.
Reply With Quote
  #4 (permalink)  
Old 09-09-2009, 09:19 AM
Loyal Member
 
Posts: 89
Default Here's what worked for me

Code:
vi /usr/share/logwatch/default.conf/logwatch.conf
Change MailTo = admin@domain.example
Change MailFrom = Logwatch@domain.example
Change mailer = "sendmail -t" > "mailer = "/opt/zimbra/postfix-*/sbin/sendmail -t"
Because there are over a 1000 hits to this one on google. I also want to point back to the original thread with the fix (#8). This one took me a while to find because so many similar threads ended without an answer.

todd_dsm

Don't forget to Vote for this RFE:
RFE: A place To Display the contents of 'My Documents'
Reasoning: It's new, bold, and cool.

Last edited by todd_dsm; 10-08-2010 at 09:45 AM..
Reply With Quote
  #5 (permalink)  
Old 12-16-2010, 06:32 PM
Active Member
 
Posts: 37
Default

This does not seem to work for me with Z6.0.5 Ubuntu 8.04. I added the following to logwatch.conf
"mailer = "/opt/zimbra/postfix-*/sbin/sendmail -t"

But still get error:
sendmail: fatal: open /etc/postfix/main.cf: No such file or directory

Do I need to install sendmail and disable it to get logwatch to work since mailer is looking for main.cf?

Cheers
Andy
Reply With Quote
  #6 (permalink)  
Old 12-17-2010, 10:44 AM
Starter Member
 
Posts: 1
Default

You have to actually verify the path for the postfix binary, which is likely called sendmail.postfix or something of that nature. Then you have to replace the "*" with the proper version if necessary. I am pretty sure that logwatch won't resolve the * character in the path.

On my RHEL system, the sendmail compatible binary from postfix is:

/opt/zimbra/postfix/sbin/sendmail
Reply With Quote
  #7 (permalink)  
Old 12-17-2010, 11:52 AM
Loyal Member
 
Posts: 89
Default Not so my friend

Quote:
Originally Posted by makfinsky View Post
I am pretty sure that logwatch won't resolve the * character in the path.
Logwatch parses the asterisk just fine. Again, mine looks like this:

Code:
mine:
$ ll /opt/zimbra/postfix-2.6.7.2z/sbin/sendmail
-rwxr-xr-x 1 root root 751331 Jun 30 13:50 /opt/zimbra/postfix-2.6.7.2z/sbin/sendmail

yours:
$ ll /opt/zimbra/postfix/sbin/sendmail
-rwxr-xr-x 1 root root 751331 Jun 30 13:50 /opt/zimbra/postfix/sbin/sendmail

/usr/share/logwatch/default.conf/logwatch.conf
mailer = "/opt/zimbra/postfix-*/sbin/sendmail -t"
The asterisk (*) was there to prevent against breaks when upgrading versions. Somehow I missed the soft link to the postfix directory. All things being equal, yours achieves the same requirement and its simpler; I like yours better. Making the change now...
Reply With Quote
  #8 (permalink)  
Old 12-17-2010, 03:01 PM
Active Member
 
Posts: 37
Default

Thank for the suggestions guys but still no joy.

Sendmail is located at /opt/zimbra/postfix-2.6.5.2z/sbin/sendmail

logwatch config: mailer = "/opt/zimbra/postfix-*/sbin/sendmail -t"

When I run "logwatch -mailto bob@bob.com" I still get:
sendmail: fatal: open /etc/postfix/main.cf: No such file or directory

I also tried logwatch config: mailer = "/opt/zimbra/postfix-2.6.5.2z/sbin/sendmail -t"

But no luck

Cheers
Andy
Reply With Quote
  #9 (permalink)  
Old 12-17-2010, 03:05 PM
Loyal Member
 
Posts: 89
Default

I'm not familiar with ubuntu but can you find sendmail to see if it's in the right location?

$ find /opt/zimbra/postfix/ -name sendmail

Whatever is returned goes into your logwatch config file. PS: any other sendmail should be uninstalled
Reply With Quote
  #10 (permalink)  
Old 12-17-2010, 03:41 PM
Active Member
 
Posts: 37
Default

Running: $ find /opt/zimbra/postfix/ -name sendmail
Returns: /opt/zimbra/postfix/sbin/sendmail

I put this in logwatch config:
mailer = "/opt/zimbra/postfix/sbin/sendmail -t"

But still get: sendmail: fatal: open /etc/postfix/main.cf: No such file or directory

Cheers
Andy
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

blog.zimbra.com




 

SEO by vBSEO ©2011, Crawlability, Inc.