LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-18-2014, 06:14 AM   #1
szboardstretcher
Senior Member
 
Registered: Aug 2006
Location: Detroit, MI
Distribution: GNU/Linux systemd
Posts: 4,278

Rep: Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694
Forward domain emails to another domain and address


Quick Background:
I've always been terrible with mail setup. I would so much rather leave it for a mail administrator/expert.

Anyway, im in this situation.

I have access to the domain records for all sites at the registrar (nettica). And I have full access to do whatever I would like at the servers.

There are two domains, and one administrator email. The two domains are fooX.com and fooY.com, and the admin email is admin@gmail.com

Question:
What kind of setup would i have to do, MX/TXT record-wise, and server-wise, to take all mail inbound to *.fooX.com and *.fooY.com and forward to admin@gmail.com?

A few pointers and an explanation as to where to go from here would be sufficient. I just don't even know where to start right now.
 
Old 05-18-2014, 04:29 PM   #2
dijetlo
Senior Member
 
Registered: Jan 2009
Location: RHELtopia....
Distribution: Solaris 11.2/Slackware/RHEL/
Posts: 1,491
Blog Entries: 2

Rep: Reputation: Disabled
I'm not a big fan of doing clever things with MX records.
1: If you screw it up, you're going to be saying " soon" for at least 12 hours while your fix gets replicated.
2: People will, from time to time, look at MX records, you don't want your corporate mail server pointed at your gmail account...not good for your image, as it were.

You can do it at the mail server but it depends on which mail server your running. You want to set up an alias for the accounts (all accounts) which, if your server accepts expansion characters looks something like
Code:
*@foo?.com = admin@gmail.com
or maybe...
*@foo{x,y}.com = admin@gmail.com
It depends on how the email program or underlying shell interprets expansion characters,
Quote:
And I have full access to do whatever I would like at the servers.
Fortune favors the bold.
Quote:
He either fears his fate too much,
Or his deserts are small,
That dares not put it to the touch
To gain or lose it all.

Last edited by dijetlo; 05-18-2014 at 04:58 PM.
 
1 members found this post helpful.
Old 05-19-2014, 12:54 PM   #3
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 13,159
Blog Entries: 1

Rep: Reputation: 2021Reputation: 2021Reputation: 2021Reputation: 2021Reputation: 2021Reputation: 2021Reputation: 2021Reputation: 2021Reputation: 2021Reputation: 2021Reputation: 2021
Quote:
Question:
What kind of setup would i have to do, MX/TXT record-wise, and server-wise, to take all mail inbound to *.fooX.com and *.fooY.com and forward to admin@gmail.com?

A few pointers and an explanation as to where to go from here would be sufficient. I just don't even know where to start right now.
Assuming that the MX records for both domains point to your smtp server, you can create a catch-all email address for both domains. Thus whatever mail comes in, it's forwarded to admin@gmail.com.
So use your favorite search engine to see how to setup a catch-all email address for your MTA

Regards
 
1 members found this post helpful.
Old 05-19-2014, 12:58 PM   #4
szboardstretcher
Senior Member
 
Registered: Aug 2006
Location: Detroit, MI
Distribution: GNU/Linux systemd
Posts: 4,278

Original Poster
Rep: Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694Reputation: 1694
Quote:
Originally Posted by bathory View Post
Assuming that the MX records for both domains point to your smtp server, you can create a catch-all email address for both domains. Thus whatever mail comes in, it's forwarded to admin@gmail.com.
So use your favorite search engine to see how to setup a catch-all email address for your MTA

Regards
Thanks for the info, it was super simple to find with the words 'catch all.' That was my missing piece. Thank you friend.
 
  


Reply

Tags
mail forwarding mx dns


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
new qmail install changes from address to domain@domain mrshiat Linux - General 1 12-19-2012 10:35 AM
POSTFIX - allow only emails from specific domain spacexplorer Linux - Server 7 07-26-2012 03:42 AM
Postfix - Multiple Emails / 1 domain Panicker Linux - Newbie 2 11-17-2011 08:04 AM
can someone help me how to forward a domain to another domain with musking? patience Linux - Server 1 08-03-2010 11:08 AM
IPtables - block subdomains (a.domain.com, b.domain.com, c.domain.com,...) benjalien Linux - Networking 6 06-24-2009 07:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 05:48 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