• The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved postfix setup for horde and activesync

hjmaier

New Pleskian
Hi,

i am struggling with the setup of Horde, active sync and postfix.

I managed to log in with active sync from my iphone. I can retriev mails. it seems to work great. I just can‘t get the mail sending to work with ios. In my mail logs I have always this entry:


=====
Mar 20 13:17:02 midgard-forum postfix/smtpd[20235]: NOQUEUE: reject: RCPT from localhost.localdomain[::1]: 454 4.7.1 <[email protected]>: Relay access denied; from=<[email protected]>
====

Any idea what is wrong? I‘ve been reading a lit of suggestion across the net, but everything they mentioned does not work.

My postconf -n looks like this:

====
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases, hash:/var/spool/postfix/plesk/aliases
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
debugger_command = PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin ddd $daemon_directory/$process_name $process_id & sleep 5
default_transport = = smtp
disable_vrfy_command = yes
html_directory = no
inet_interfaces = all
inet_protocols = all
mail_owner = postfix
mailbox_size_limit = 0
mailman_destination_recipient_limit = 1
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
message_size_limit =256000000
mydestination = localhost.$mydomain, localhost, localhost.localdomain
myhostname = midgard-forum.de
mynetworks =
newaliases_path = /usr/bin/newaliases.postfix
plesk_virtual_destination_recipient_limit = 1
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.10.1/README_FILES
relay_domains = $mydestination
relay_transport = relay
sample_directory = /usr/share/doc/postfix-2.10.1/samples
sender_dependent_default_transport_maps = hash:/var/spool/postfix/plesk/sdd_transport_maps
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtp_send_xforward_command = yes
smtp_tls_security_level = may
smtp_use_tls = no
smtpd_authorized_xforward_hosts = 127.0.0.0/8 [::1]/128
smtpd_client_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_rbl_client bl.spamcop.net, reject_rbl_client b.barracudacentral.org
smtpd_milters = , inet:127.0.0.1:12768
smtpd_proxy_timeout = 3600s
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sender_restrictions = check_sender_access hash:/var/spool/postfix/plesk/blacklists, permit_sasl_authenticated
smtpd_timeout = 3600s
smtpd_tls_cert_file = /etc/postfix/postfix.pem
smtpd_tls_ciphers = medium
smtpd_tls_key_file = $smtpd_tls_cert_file
smtpd_tls_mandatory_ciphers = medium
smtpd_tls_mandatory_protocols = TLSv1 TLSv1.1 TLSv1.2
smtpd_tls_protocols = TLSv1 TLSv1.1 TLSv1.2
smtpd_tls_security_level = may
smtpd_use_tls = yes
tls_medium_cipherlist = HIGH:!aNULL:!MD5
transport_maps = , hash:/var/spool/postfix/plesk/transport
unknown_local_recipient_reject_code = 550
virtual_alias_maps = $virtual_maps, hash:/var/spool/postfix/plesk/virtual
virtual_gid_maps = static:31
virtual_mailbox_base = /var/qmail/mailnames
virtual_mailbox_domains = $virtual_mailbox_maps, hash:/var/spool/postfix/plesk/virtual_domains
virtual_mailbox_limit = 0
virtual_mailbox_maps = , hash:/var/spool/postfix/plesk/vmailbox
virtual_transport = plesk_virtual
virtual_uid_maps = static:30
====
 
Hi,

i am struggling with the setup of Horde, active sync and postfix.

I managed to log in with active sync from my iphone. I can retriev mails. it seems to work great. I just can‘t get the mail sending to work with ios. In my mail logs I have always this entry:


=====
Mar 20 13:17:02 midgard-forum postfix/smtpd[20235]: NOQUEUE: reject: RCPT from localhost.localdomain[::1]: 454 4.7.1 <[email protected]>: Relay access denied; from=<[email protected]>
====

Any idea what is wrong? I‘ve been reading a lit of suggestion across the net, but everything they mentioned does not work.

My postconf -n looks like this:

====
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases, hash:/var/spool/postfix/plesk/aliases
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
debugger_command = PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin ddd $daemon_directory/$process_name $process_id & sleep 5
default_transport = = smtp
disable_vrfy_command = yes
html_directory = no
inet_interfaces = all
inet_protocols = all
mail_owner = postfix
mailbox_size_limit = 0
mailman_destination_recipient_limit = 1
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
message_size_limit =256000000
mydestination = localhost.$mydomain, localhost, localhost.localdomain
myhostname = midgard-forum.de
mynetworks =
newaliases_path = /usr/bin/newaliases.postfix
plesk_virtual_destination_recipient_limit = 1
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.10.1/README_FILES
relay_domains = $mydestination
relay_transport = relay
sample_directory = /usr/share/doc/postfix-2.10.1/samples
sender_dependent_default_transport_maps = hash:/var/spool/postfix/plesk/sdd_transport_maps
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtp_send_xforward_command = yes
smtp_tls_security_level = may
smtp_use_tls = no
smtpd_authorized_xforward_hosts = 127.0.0.0/8 [::1]/128
smtpd_client_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_rbl_client bl.spamcop.net, reject_rbl_client b.barracudacentral.org
smtpd_milters = , inet:127.0.0.1:12768
smtpd_proxy_timeout = 3600s
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sender_restrictions = check_sender_access hash:/var/spool/postfix/plesk/blacklists, permit_sasl_authenticated
smtpd_timeout = 3600s
smtpd_tls_cert_file = /etc/postfix/postfix.pem
smtpd_tls_ciphers = medium
smtpd_tls_key_file = $smtpd_tls_cert_file
smtpd_tls_mandatory_ciphers = medium
smtpd_tls_mandatory_protocols = TLSv1 TLSv1.1 TLSv1.2
smtpd_tls_protocols = TLSv1 TLSv1.1 TLSv1.2
smtpd_tls_security_level = may
smtpd_use_tls = yes
tls_medium_cipherlist = HIGH:!aNULL:!MD5
transport_maps = , hash:/var/spool/postfix/plesk/transport
unknown_local_recipient_reject_code = 550
virtual_alias_maps = $virtual_maps, hash:/var/spool/postfix/plesk/virtual
virtual_gid_maps = static:31
virtual_mailbox_base = /var/qmail/mailnames
virtual_mailbox_domains = $virtual_mailbox_maps, hash:/var/spool/postfix/plesk/virtual_domains
virtual_mailbox_limit = 0
virtual_mailbox_maps = , hash:/var/spool/postfix/plesk/vmailbox
virtual_transport = plesk_virtual
virtual_uid_maps = static:30
====

Hello,
your emails seems to be reject by gmail because some configuration are not correct for a mail server.

- Your server hostname have to be a FQDN (Fully qualified domain name) like server.yourdomain.tld and not only yourdomain.tld
- You have to set the server hostname as reverse DNS on your server IP (in the panel of your hosting provider)
- Have you set all the proper DNS records to send emails ? You can look on iRedmail documentation which explain very well each DNS records to use on a mail server : Setup DNS records for your iRedMail server (A, PTR, MX, SPF, DKIM)
- I have recommend you to use only IPv4 to send emails. Just edit the line inet_protocols and replace all by ipv4 like this :
Code:
inet_protocols = ipv4
 
Thank you for your answer.

But it is not gmail which is rejecting the mail. The Connection itself is rejected by postfix on my server. The mailserver itself works fine. I can send mail i can get mails. POP3 works, IMAP, SMTP ...

The only Problem is, when I try to log in via active sync. Active sync works for Calendars, incoming mails, address book ... Just not for sending mails.

I triied your sugestion inet_protocols = ipv4. It only changes the error message to: [...] localhost.localdomain[::1]

According to the documentations I found spreaded accross net, it is because postfix does not allow the Connection, but:

mydestination = localhost.$mydomain, localhost, localhost.localdomain
relay_domains = $mydestination

should do the trick. I guess there is a different Setting (maybe mynetworks).
 
I changed the reverse dns entry and my Server Name, all still works well, beside that silly Connection to send mails.
 
I've found the guilty one. I had to set this:

mynetworks = 127.0.0.0/8 [::1]/128 46.4.105.107 [2a01:4f8:141:1c7::2]

Now it works just fine.
 
Back
Top