HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Server Operation (http://www.howtoforge.com/forums/forumdisplay.php?f=5)
-   -   Email Forwarding Issue (http://www.howtoforge.com/forums/showthread.php?t=30300)

crayz1 13th January 2009 19:24

Email Forwarding Issue
 
I am having issues forwarding emails received to virtual user accounts. The log shows the messages are received and forwarded, but I am not receiving the forwarded emails. I have scoured the forums trying to find if there is a fix for the issue, but I haven't come up with a solution.

I have made sure my mail server is not backlisted, which it is not. The server sends and receives email without issues. I appreciate any insight/answers.

Here is an example of the server receiving the email to the virtual user account and forwarding it to my gmail account.
Code:

Jan 13 11:27:57 server1 postfix/smtpd[15204]: connect from yw-out-1718.google.com[74.125.46.153]
Jan 13 11:27:57 server1 postfix/smtpd[15204]: 87FA0A9A381: client=yw-out-1718.google.com[74.125.46.153]
Jan 13 11:27:57 server1 postfix/cleanup[15208]: 87FA0A9A381: message-id=<496CC109.3010504@gmail.com>
Jan 13 11:27:57 server1 postfix/qmgr[14150]: 87FA0A9A381: from=<crayz1@gmail.com>, size=2010, nrcpt=1 (queue active)
Jan 13 11:27:57 server1 postfix/pickup[14148]: A22CBA9A3AD: uid=10020 from=<domain.com_user>
Jan 13 11:27:57 server1 postfix/cleanup[15208]: A22CBA9A3AD: message-id=<20090113162757.A22CBA9A3AD@server1.mailserver.com>
Jan 13 11:27:57 server1 postfix/local[15209]: 87FA0A9A381: to=<domain.com_user@server1.mailserver.com>, orig_to=<user@domain.com>, relay=local, delay=0.15, delays=0.11/0.01/0/0.03, dsn=2.0.0, status=sent (delivered to command: /usr/bin/procmail -f-)
Jan 13 11:27:57 server1 postfix/cleanup[15216]: A49F1A9A3B5: message-id=<496CC109.3010504@gmail.com>
Jan 13 11:27:57 server1 postfix/qmgr[14150]: A22CBA9A3AD: from=<domain.com_user@server1.mailserver.com>, size=458, nrcpt=1 (queue active)
Jan 13 11:27:57 server1 postfix/local[15209]: 87FA0A9A381: to=<domain.com_user@server1.mailserver.com>, orig_to=<user@domain.com>, relay=local, delay=0.18, delays=0.11/0.01/0/0.06, dsn=2.0.0, status=sent (forwarded as A49F1A9A3B5)
Jan 13 11:27:57 server1 postfix/qmgr[14150]: A49F1A9A3B5: from=<crayz1@gmail.com>, size=2178, nrcpt=1 (queue active)
Jan 13 11:27:57 server1 postfix/qmgr[14150]: 87FA0A9A381: removed
Jan 13 11:27:57 server1 postfix/local[15209]: A22CBA9A3AD: to=<admispconfig@localhost.localdomain>, relay=local, delay=0.07, delays=0.04/0/0/0.03, dsn=2.0.0, status=sent (delivered to command: /usr/bin/procmail -f-)
Jan 13 11:27:57 server1 postfix/qmgr[14150]: A22CBA9A3AD: removed
Jan 13 11:27:59 server1 postfix/smtp[15218]: A49F1A9A3B5: to=<crayz1@gmail.com>, orig_to=<user@domain.com>, relay=gmail-smtp-in.l.google.com[74.125.45.27]:25, delay=2.1, delays=0.02/0.02/0.44/1.6, dsn=2.0.0, status=sent (250 2.0.0 OK 1231864079 4si3956402yxq.36)
Jan 13 11:27:59 server1 postfix/qmgr[14150]: A49F1A9A3B5: removed


virtual users table
Code:

user@www.domain.com    domain.com_user
domain.com_user@www.domain.com    domain.com_user
user@domain.com    domain.com_user
domain.com_user@domain.com    domain.com_user


crayz1 14th January 2009 05:49

ok, I found something that could be related to the error.

I sent a test email from another virtual user account which correctly forwarded through postfix and was received by 3 accounts. Each account showed the email was sent from xxxx@example.com.

Apparently I must have missed something some where.

falko 14th January 2009 12:53

Are you trying to forward to external addresses, or also to addresses that are on the same server?

What's in your main.cf? (Are you using ISPConfig?)

crayz1 14th January 2009 13:48

Quote:

Originally Posted by falko (Post 164545)
Are you trying to forward to external addresses, or also to addresses that are on the same server?

What's in your main.cf? (Are you using ISPConfig?)

Yes, I am trying to forward both internally and externally. And, yes, I am using ispconfig.

main.cf
Code:

# See /usr/share/postfix/main.cf.dist for a commented, more complete version


# Debian specific:  Specifying a file name will cause the first
# line of that file to be used as the name.  The Debian default
# is /etc/mailname.
#myorigin = /etc/mailname

smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

readme_directory = no

# TLS parameters
smtpd_tls_cert_file = /etc/postfix/ssl/smtpd.crt
smtpd_tls_key_file = /etc/postfix/ssl/smtpd.key
smtpd_use_tls = yes
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache

# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.

myhostname = server1.domain.com
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
#mydestination = server1.domain.com, localhost.domain.com, , localhost
relayhost =
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
mailbox_command =
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
inet_protocols = all
smtpd_sasl_local_domain =
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
broken_sasl_auth_clients = yes
smtpd_sasl_authenticated_header = yes
smtpd_recipient_restrictions = permit_sasl_authenticated,permit_mynetworks,reject_unauth_destination
smtpd_tls_auth_only = no
smtp_use_tls = yes
smtp_tls_note_starttls_offer = yes
smtpd_tls_CAfile = /etc/postfix/ssl/cacert.pem
smtpd_tls_loglevel = 1
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom
home_mailbox = Maildir/

virtual_maps = hash:/etc/postfix/virtusertable

mydestination = /etc/postfix/local-host-names

Thanks for the help.

falko 15th January 2009 13:49

Quote:

Originally Posted by crayz1 (Post 164561)
Yes, I am trying to forward both internally and externally.

And which ones do not arrive? The forwards to the internal or to the external addresses, or both?

Do you have SPF records for your domains?


All times are GMT +2. The time now is 16:08.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.