LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-30-2008, 02:51 PM   #1
lokeshreddy4u
LQ Newbie
 
Registered: Jun 2008
Posts: 2

Rep: Reputation: 0
Help required to setting forwarder to external mail id on sendmail


Hi,

I want to set forwarder on sendmail to forward all my mails to yahoo account.

my account is lreddy@abc.com --> Exchange email id .

We are using sendmail as MTA. all mails will be delivered based on mailertable rules.

Can some one guide me how to proceed ..
 
Old 07-01-2008, 02:57 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,516

Rep: Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501
If you have a home dir in the box running sendmail you can create a .forward file containing the address you want the mail to be forwarded. You can also use /etc/mail/aliases to do the same thing. You need to run newaliases afterwards for the changes to make effetct.
Else if it's a virtual mail address you must use /etc/mail/virtusertable to make the association. After that you must run:
Code:
makemap hash /etc/mail/virtusertable < /etc/mail/virtusertable

Last edited by bathory; 07-02-2008 at 03:11 AM.
 
Old 07-01-2008, 04:23 PM   #3
lokeshreddy4u
LQ Newbie
 
Registered: Jun 2008
Posts: 2

Original Poster
Rep: Reputation: 0
Hi .. Thanks for reply..

Actually mail box belongs to exchange.

All my company mails forwards to exchange server for delivery.

already i tried by adding email is on virtusertable like..

lreddy@abc.com lokesh@yahoo.com

-------------------------

But still mails are going to exchange mailbox , its not forwarding to yahoo account.

i am using mailertable for smtp replay..

abc.com esmtp:xxx.xxx.xxx ( exchange server ).

Can you explain is virtusertable will execute before / after mailertable ?

Awaiting for your responce..

Thanx
 
Old 07-02-2008, 04:28 AM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,516

Rep: Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501Reputation: 1501
I'm not sure, but I think that virtusertable is read first and then mailertable. You can use just virtusertable to do what you want, like this:
Code:
lreddy@abc.com lokesh@yahoo.com
@abc.com %1@exchange.server
so your mail will be forwarded to yahoo and anybody's else will go to the exchange server.
Another possibility is to use ldap_routing, that I think is more suitable for your case.

If this is not what you want, then you should do the forwarding from your account on exchange server.

Last edited by bathory; 07-02-2008 at 07:54 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
SMTP forwarder to mail server behind a firewall jlregister Linux - Software 1 12-02-2007 04:23 AM
setting packet forwarder b123coder Linux - Networking 1 05-05-2005 07:27 AM
Sendmail - problem receiving external mail manudath Linux - Wireless Networking 7 12-21-2004 02:14 PM
sendmail and external mail server levand Linux - Networking 10 12-17-2004 10:45 AM
configure sendmail to use external mail server Drogo Linux - Software 0 09-16-2004 10:16 PM


All times are GMT -5. The time now is 03:47 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration