Operating System - Linux
1753505 Members
7147 Online
108794 Solutions
New Discussion юеВ

Re: reciver problem in sendmail

 
Fadia Almarei
Super Advisor

reciver problem in sendmail

Dear All
I have sendmail server in RHEL v.4 ,i have a mail user1@mydomain forwared to user2@yahoo.com , if i try to send a mail to the mail user1@mydomain it will be recieved by the mail user2@yahoo.com , the problem that i have that the to address will apear user1@mydomain, I want it to apear user2@yahoo.com , what is the feature that i can use in sendmail to get this idea.kindly advice.
BR;
Fadia
fadia.marei
8 REPLIES 8
Ivan Ferreira
Honored Contributor

Re: reciver problem in sendmail

If I understood correctly, I think that you need virtual user tables:

http://www.faqs.org/docs/linux_network/x15291.html
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
Steven E. Protter
Exalted Contributor

Re: reciver problem in sendmail

Shalom Fadia:

In a file called /etc/aliases

user1@mydomain: user2@yahoo.com

Thats the fast way.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Fadia Almarei
Super Advisor

Re: reciver problem in sendmail

as i know the alias is for local users on the system , but the yahoo user is for outside , i use the virtualtable to work on it but it does not work the reciever will be user1@mydomain as in the example.
fadia.marei
Fadia Almarei
Super Advisor

Re: reciver problem in sendmail

Dear All
i need your help, I want to read the contant of the mail reseived in user@mydomain and save it in a file then resend it with senmail, I want a script to do all this , kindly your help, maily i want to how to save the mail contant in a file.
BR;
fadia.marei
Steven E. Protter
Exalted Contributor

Re: reciver problem in sendmail

Shalom again fadia,

You have been provided a solution above.

sendmail does not save an email and then later forward it.

Sendmail can be told to forward certain mails recieved to new uers via two established methods.

/etc/aliases

user1@domain.com: someone@newdomain.com

This forwards mail recieved for user1@domain.com to someone@newdomain.com

Or /etc/mail/virtusertable

user1@domain.com someone@newdomain.com

It can also be used to route mail locally.

Now to deal with another issue.

You are not being a good ITRC member. You fail to reward those who wish to help you by assigning points.

http://forums1.itrc.hp.com/service/forums/pageList.do?userId=CA1068778&listType=unassigned&forumId=1
Your assignment ratio is atrocious, 25% of the responses receive points.

Please read this:
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=140137
Forums ettiqute.

If you persist in ignoring your responsibilities as an ITRC member, I will simply stop responding to your questions. I don't want to seem mean or angry, but ITRC works in a certain way, which you seem intent on ignoring.

Your sendmail issue is simple, easy to correct and should be fixed by now.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Fadia Almarei
Super Advisor

Re: reciver problem in sendmail

steven
I appreciate evey effort given to me by answering my question , but i wait to get my answer then i will give marks, thanks for your effort but i want from you a script to do this , the problem as i told before is in the reciever mail, that it is the mail of the user who forward his mail, kindly read my question carfully
fadia.marei
Steven E. Protter
Exalted Contributor

Re: reciver problem in sendmail

I was referring to your overall record. Before my post 25 of 109. Please go back at your convenience and do something about it.

Please add this entry to /etc/mail/virtusertable

user1@mydomain user2@yahoo.com

Check /etc/mail/sendmail.cf and see if it uses virtusertable, report back if it does not.

Diagnostic:

sendmail -v -d8 -d38 user1@mydomain

type some text

.



Report back diagnostics and obviously use real user names. Check /var/log/maillog

I know we can solve this. Three or four years ago I had exactly this issue and I can assure you my servers correctly process these directives.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Fadia Almarei
Super Advisor

Re: reciver problem in sendmail

thanks Steven, I will follow up this issue, my problem is not in recieving the message for the forwarded mail, the problem is that the reciever adress that apears in the message is the user adress not the forwarded mail address,in a simple words i wont to mascurading and do generics in the reciver mail address.
fadia.marei