Hi,
I have configured a postfix mail server on RHEL6. It's working fine locally but when I am sending mail to gmail or yahoomail an error is coming "Relay Access Denied".
Postfix version - Postfix-2.6.6-2.2e16_1.x86_64
My host name - mail1.xyz.ac.in (xyz is not the real domain name)
IP address - 172.16.1.12
[root@mail1 ~]# postconf -n
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
header_checks = regexp:/etc/postfix/header_checks
home_mailbox = Maildir/
html_directory = no
inet_interfaces = all
inet_protocols = all
local_recipient_maps =
mail_owner = postfix
mail_spool_directory = /var/spool/mail
mailbox_size_limit = 20485760
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
mydomain = xyz.ac.in
myhostname = mail1.xyz.ac.in
mynetworks = 172.16.1.0/29, 127.0.0.0/8,
mynetworks_style = subnet
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.6.6/README_FILES
sample_directory = /usr/share/doc/postfix-2.6.6/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtp_generic_maps = hash:/etc/postfix/generic
smtpd_banner = $myhostname ESMTP $mail_name ($mail_version)
smtpd_client_restrictions = warn_if_reject permit_mynetworks, reject_unknown_client,permit
smtpd_recipient_restrictions = warn_if_reject permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_path = private/auth
smtpd_sasl_security_options = noanonymous, noplaintext
smtpd_sasl_tls_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_tls_auth_only = yes
smtpd_tls_cert_file = /etc/pki/tls/certs/server.crt
smtpd_tls_key_file = /etc/pki/tls/certs/server.key
smtpd_tls_loglevel = 1
smtpd_tls_security_level = may
smtpd_tls_session_cache_database = btree:/var/spool/postfix/smtpd_tls_cache
smtpd_tls_session_cache_timeout = 3600s
soft_bounce = yes
tls_random_source = dev:/dev/urandom
unknown_local_recipient_reject_code = 550
[root@mail1 ~]# telnet mail1.xyz.ac.in 25
Trying 172.16.1.12...
Connected to mail1.xyz.ac.in.
Escape character is '^]'.
220 mail1.xyz.ac.in ESMTP Postfix (2.6.6)
ehlo localhost
250-mail1.xyz.ac.in
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-STARTTLS
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
mail from:
root@root.ac.in
250 2.1.0 Ok
rcpt to:
user.name@gmail.com
454 4.7.1 <user.name@gmail.com>: Relay access denied
quit
221 2.0.0 Bye
Connection closed by foreign host.
[root@mail1 ~]#