Now with extra stuff

by Stephen McGroarty 2/22/2010 8:30:00 AM

Ok it has been a while since my last update, and I dont think it is because I am running out of stuff to talk about. Today lets just do a simple grep trick. Lets grep some stuff out of a maillog 

grep -i rejected /var/log/maillog

 that should give you about 2000 or so returns. But what if you are looking only for rejected messages from yahoo.com? Lets string some grep commands together shall we. 

 grep -r rejected /var/log/maillog | grep -r yahoo.com 

Now we are starting to narrow it down a little bit, we see only messages from yahoo.com, lets see if your email address is actually being rejected now 

grep -r rejected /var/log/maillog | grep -r yahoo.com | grep - r irocksbigtime  

Now you  you should see just your mesages 

 19:24:25 vsmtpin3 postfix/smtpd[28336]: NOQUEUE: reject: RCPT from unknown[192.168.1.101]: 504 5.5.2 <GNTDJLCVL>: Helo command rejected: need fully-qualified hostname; from=<irocksbigtime@yahoo.com> to=<XXX@XXXXXX-XXXXXXX.XXO> proto=ESMTP helo=<GNTDJLCVL>

and ta-da! you see that your sending mail server does not have a fully qualified domain name and that yahoo wont take your mail.
 

Currently rated 5.0 by 1 people

  • Currently 5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags: , , ,

Weekly Tip

Powered by BlogEngine.NET 1.4.5.0
Theme by Mads Kristensen
Hacked by Stephen McGroarty
Content © Stephen McGroarty


About the author

Stephen Mcgroarty - Avatar Stephen McGroarty

I am a Microsoft Certified Professional with Windows 2003 Server. I have a firm understanding of Linux, Windows, and everything needed for both workstation and servers.

E-mail me Send mail

Calendar

<<  February 2012  >>
SuMoTuWeThFrSa
2930311234
567891011
12131415161718
19202122232425
26272829123
45678910

View posts in large calendar

Disclaimer

The opinions expressed herein are my own personal opinions and do not represent my employer's view in anyway.

© Copyright 2012