Operating System - HP-UX
1863256 Members
1330 Online
110447 Solutions
New Discussion

mailx with mailrc with from= setup does not work

 
Steven_181
Advisor

mailx with mailrc with from= setup does not work

Hi,

Currently all the mailx send out from the server from all user have the following format:
[email protected]

We are trying to setup mailx to send out email to have the email all from [email protected].

[email protected] ==> [email protected]

We have edited the sendmail.cf to have localhost change to @domainA.com successfully.
However we are not manage to change username ==> no-reply-servername.

By the way, we don't one to use the mailx -r option as we have to change all script which are everywhere.

In our .mailrc file we have the following

set smtp=smtp://mail.gr.domainA.com
set [email protected]
set [email protected]

when we tried to send using following command

mailx -d -s "Testing" [email protected]

assign(MAILRC)=/root/.mailrc
assign(smtp)=smtp://mail.gr.domainA.com
value(autoprint)=
value(flipr)=
assign(from)[email protected]
value(autoprint)=
value(flipr)=
assign(replyto)[email protected]
value(autoprint)=
assign(smtp)=smtp://mail.gr.domainA.com
value(autoprint)=
value(flipr)=
assign(from)[email protected]
value(autoprint)=
value(flipr)=
assign(replyto)[email protected]
value(autoprint)=

It is able to read the mailrc file with the field from, however when the email is send out it have only
[email protected].

Any idea how to make it work?

We tried the aliases setup, genericstable however it does not work.


 

 

 

1 REPLY 1
Saajan_d
HPE Pro

Re: mailx with mailrc with from= setup does not work

COnfigure genericstable and it should work.

rebuild the genericstable in the sendmail.cf with the /usr/newconfig/etc/mail/cf/cf/gen_cf setup and theh copy sendmail.gen.cf file to /etc/mail/sendmail.cf and reconfigure sendmail again with DS and DM entry and then create a file called genericstabel and provide the appropraite entry and then rebuild the genericstable database as below 

 makemap dbm /etc/mail/genericstable < /etc/mail/genericstable

and then restart the senemail service and then recheck again

if still not working, kindly raise a consultancy ticket with HPE as it is a configuration and system admin task



I work at HPE
HPE Support Center offers support for your HPE services and products when and how you need it. Get started with HPE Support Center today.
[Any personal opinions expressed are mine, and not official statements on behalf of Hewlett Packard Enterprise]
Accept or Kudo