f



How to edit the message sent to maillog

Hi, I have read that I can add the 'To' email address to the message sent to the maillog file but  for the life of me I cannot find out how to do this. 

Can somebody please put me out of my misery and let me know how / where I edit the message format?

Thanks,
Mark
0
mark
11/22/2016 6:10:10 PM
comp.mail.sendmail 13518 articles. 1 followers. jfretby (35) is leader. Post Follow

5 Replies
146 Views

Similar Articles

[PageSpeed] 21

Mark wrote:
> Hi, I have read that I can add the 'To' email address to the message sent to the maillog

Where did you read it?

> file but  for the life of me I cannot find out how to do this. 

> Can somebody please put me out of my misery and let me know how / where I edit the message format?

In the source code...
Or you could use the syslog map, see doc/op/op.*


"What's the problem you are trying to solve?"

sendmail logs a to= entry:
uAM8pP94020964: to=<SOMEUSER@sendmail.org>, delay=00:00:08, xdelay=00:00:02, mailer=esmtp, pri=44174, relay=...., stat=Sent



-- 
Note: please read the netiquette before posting. I will almost never
reply to top-postings which include a full copy of the previous
article(s) at the end because it's annoying, shows that the poster
is too lazy to trim his article, and it's wasting the time of all readers.
0
Claus
11/22/2016 6:33:35 PM
Hi Claus, 

I read about the options to add to the maillog message here;
http://docstore.mik.ua/orelly/networking/sendmail/ch26_01.htm#SML2-CH-26-TAB-3

The syslog man pages seem only to refer to managing the log files, not the messages sent to the files by the facilities. 

The only op.* file I can find on my Centos VPS is /usr/lib64/perl5/CORE/op.h which seems to be for the setup of the Perl environment. :(

0
mark
11/22/2016 8:51:23 PM
> I read about the options to add to the maillog message here;
> http://docstore.mik.ua/orelly/networking/sendmail/ch26_01.htm#SML2-CH-26-TAB-3

I don't see anything about "options to add"; that (illegal copy of the
Bat book?) only shows what is logged by sendmail.

> The only op.* file I can find on my Centos VPS is /usr/lib64/perl5/CORE/op.h which seems to
> be for the setup of the Perl environment. :(

Download the real thing from ftp.sendmail.org and access doc/op/op.*


I didn't see an answer to my question what you are trying to
achieve... (considering that sendmail logs to=).
0
Claus
11/23/2016 12:57:48 AM
Hi Claus, 

> Download the real thing from ftp.sendmail.org and access doc/op/op.*
> 
I have downloaded this :)

> 
> I didn't see an answer to my question what you are trying to
> achieve... (considering that sendmail logs to=).

For some reason I am not getting the to= value in my log.

Unfortunately I have run out of time on this issue and will have to get back to it another day. Thanks for your help :)




0
mark
11/23/2016 10:50:32 AM
> For some reason I am not getting the to= value in my log.

as root:
date | sendmail -v -Am $USER

then check the log. If to= isn't logged, check the queue.

Or try:
date | sendmail -v -Am -D/tmp/sm.log -d89.9 $USER
cat /tmp/sm.log

0
Claus
11/23/2016 1:29:15 PM
Reply: