1824822 Members
4190 Online
109674 Solutions
New Discussion юеВ

Sendmail doubt

 
SOLVED
Go to solution
Rafael Mendon├зa Braga
Regular Advisor

Sendmail doubt

Hello experts!!
Using HP-UX 11i.

I did a script to send me an e-mail everynight reporting the status of the filesystem of our servers here in the company... This way, I can know how much they are growing day by day.
I'm using mailx to send these e-mails...

Some of the servers send me the mail as "root@company.com" in the "From" field only and some send as "Administrator [root@company.com]" ... How can i set the others to e-mail me with the "Administrator" in the field from?

Thanks,

Rafael M. Braga
4 REPLIES 4
Pete Randall
Outstanding Contributor
Solution

Re: Sendmail doubt

See the " Rewriting the From Line on Outgoing Mail" section in this manual:

http://docs.hp.com/en/5991-0707/ch02s03.html


Pete

Pete
David Child_1
Honored Contributor

Re: Sendmail doubt

Try changing root's gecos field in /etc/passwd to 'Administrator'.

i.e.

root:*************:0:3:Administrator:/root:/sbin/sh

Check the servers that 'work' and you will probably find them set up that way.

David
Christopher Caldwell
Honored Contributor

Re: Sendmail doubt

#run_your_script | mailx -r admin@admin.com you@youraddress.com

-r changes the reply-to [from] field. Substitute the appropriate address.

You'll get an authentication warning like
X-Authentication-Warning: you.you.com: joe set sender to fred@fred.com using -r
if you're not a "Trusted User" from sendmail's perspective. root is generally Trusted.
Rafael Mendon├зa Braga
Regular Advisor

Re: Sendmail doubt

Thanks everybody!!

I used David suggestion!!

Thanks a lot!