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 12-08-2011, 01:52 PM
Special Member
 
Posts: 125
Exclamation How to search logs for an email address

I've got a bit of a "situation" and I need to search the logs on my Zimbra server to see if mail has been sent or received from a particular email address.

Can someone please show me the command(s) necessary.

Thanks
Reply With Quote
  #2 (permalink)  
Old 12-08-2011, 02:23 PM
Starter Member
 
Posts: 2
Default

Quote:
Originally Posted by yonatan View Post
I've got a bit of a "situation" and I need to search the logs on my Zimbra server to see if mail has been sent or received from a particular email address.

Can someone please show me the command(s) necessary.

Thanks
To search the most recent log
Code:
grep user@domain.com /var/log/zimbra.log | more
However the older logs are compressed, which requires more effort:
Code:
for i in /var/log/zimbra.log.*.gz ; do gunzip -c $i | grep user@domain.com | more; done;

You can vary this a bit and find just the "to" address using...
Code:
for i in /var/log/zimbra.log.*.gz ; do gunzip -c $i | grep "to=<user@domain.com>" | more; done;

Last edited by Linux2012; 12-08-2011 at 02:31 PM..
Reply With Quote
  #3 (permalink)  
Old 12-08-2011, 02:57 PM
Special Member
 
Posts: 125
Default

Excellent just what I needed! Thank you very much Linux2012
Reply With Quote
  #4 (permalink)  
Old 12-08-2011, 10:54 PM
Elite Member
 
Posts: 334
Default

Zimbra 7 has a feature tracking :

Code:
/opt/zimbra/libexec/zmmsgtrace -s "sender@domain.tld"
or

Code:
/opt/zimbra/libexec/zmmsgtrace -r "recipient@domain.tld"
CLI zmmsgtrace - Zimbra :: Wiki

zmmsgtrace was available on Zimbra 5, disappeared on Zimbra 6 and back on Zimbra 7
__________________
Best Regards
---
Masim "Vavai" Sugianto
Vavai Personal Blog
Personal Blog [ID]

Release 7.1.3_GA_3346.SLES11_64_20110930001521 SLES11_64 FOSS edition.
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.