LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 06-26-2015, 06:00 AM   #1
CedSha
LQ Newbie
 
Registered: Jun 2015
Distribution: Ubuntu
Posts: 7

Rep: Reputation: Disabled
Question Is POSTFIX capable of Relaying received mailbox


Hi everybody,
Our MX record point to one server in Country A. I would like to know if I could relay all the mail coming to this server to my Private server located in Country B. I have several users and we do not want just forwarding from usern@domain1.com to usern@domain2.com which would be a lot of mess.
For sending mail I found how to relay from Country B to A , but really cannot find the way for incoming mails.
Thanks for any suggestion...
 
Old 06-26-2015, 09:50 AM   #2
CedSha
LQ Newbie
 
Registered: Jun 2015
Distribution: Ubuntu
Posts: 7

Original Poster
Rep: Reputation: Disabled
Lightbulb Maybe like that...

Hmmmm I have a good feeling for the relay_transport parameter...and the transport table
It looks like I should define the transport map first
Code:
transport_maps = hash:/etc/postfix/transport
and in this map I should enter
Code:
domain1.com smtp:[IP of server in country B]
then as far as I understand I should run :
Code:
postmap /etc/postfix/transport
Will go to try all these and keep informed.

Last edited by CedSha; 06-26-2015 at 10:21 AM. Reason: Structure the idea
 
Old 06-27-2015, 11:26 AM   #3
CedSha
LQ Newbie
 
Registered: Jun 2015
Distribution: Ubuntu
Posts: 7

Original Poster
Rep: Reputation: Disabled
Thumbs down Missing something...

It cannot works All I got is :
Code:
Recipient address rejected: User unknown in virtual alias table
I confirm the server A use virtual,
but cannot understand why users should be in an alias table because it should be message sent to them are relayed via the transport setup ???
postconf -n gives :
Code:
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
append_dot_mydomain = no
biff = no
broken_sasl_auth_clients = yes
config_directory = /etc/postfix
home_mailbox = Maildir/
inet_interfaces = all
mailbox_command = /usr/bin/procmail-wrapper -o -a $DOMAIN -d $LOGNAME
mailbox_size_limit = 0
mydestination = servera.info, localhost.servera.info, localhost
myhostname = servera.info
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
myorigin = /etc/mailname
readme_directory = no
recipient_delimiter = +
relayhost = 
sender_bcc_maps = hash:/etc/postfix/bcc
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
smtpd_recipient_restrictions = permit_mynetworks permit_sasl_authenticated reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
smtpd_tls_cert_file = /etc/ssl/certs/ssl-cert-snakeoil.pem
smtpd_tls_key_file = /etc/ssl/private/ssl-cert-snakeoil.key
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtpd_use_tls = yes
transport_maps = hash:/etc/postfix/transport
virtual_alias_maps = hash:/etc/postfix/virtual
help still warmly welcome...
 
  


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
Debian mail server root mailbox received a compromising message jordib Linux - Security 20 03-13-2011 12:50 PM
Debian mail server root mailbox received a compromising message (OT) 120 Linux - Security 1 03-11-2011 04:35 PM
postfix relaying email to multiple mailbox server inaki Linux - Server 5 04-06-2010 12:34 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 06:44 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
Open Source Consulting | Domain Registration