LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
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, 01: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, 01:57 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
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 02:11 AM.
 
Old 07-01-2008, 03: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, 03:28 AM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,163
Blog Entries: 1

Rep: Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032Reputation: 2032
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 06:54 AM.
 
  


Reply



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 03:23 AM
setting packet forwarder b123coder Linux - Networking 1 05-05-2005 06:27 AM
Sendmail - problem receiving external mail manudath Linux - Wireless Networking 7 12-21-2004 01:14 PM
sendmail and external mail server levand Linux - Networking 10 12-17-2004 09:45 AM
configure sendmail to use external mail server Drogo Linux - Software 0 09-16-2004 09:16 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:37 AM.

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
Open Source Consulting | Domain Registration