Postfix Mail Relay 554

Talk about any thing that related to networking, running servers with *nux.

Moderator: kalinga

Postfix Mail Relay 554

Postby mhmfasy » Sat Jun 17, 2006 10:55 am

hi,

i have installed postfix and it is working fine within the office premisses (LAN). But when i try sending mails from outside office premisses, i get the error message "554 <xxxxxxxx@xxxxt.xxx>: Relay access denied; in my postfix mail log file. I think there is a setting i have to add in main.cf, can u help me on this issue.


thanx,
fasy
mhmfasy
 
Posts: 4
Joined: Thu Jun 15, 2006 2:22 pm
Location: Srilanka

Postby kalinga » Sun Jun 18, 2006 9:34 pm

hi

if your trying to send mails using your mail server form out side the lan (form the internet) you need to setup smtp auth in postfix

http://www.postfix.org/SASL_README.html

hope this help, if you tell me what your really trying to do, i can give you some work around.
kalinga
Site Admin
 
Posts: 209
Joined: Fri Oct 14, 2005 3:19 pm
Location: Sri Lanka

Relay problem in postfix

Postby mhmfasy » Sun Jun 18, 2006 10:51 pm

hi,

thanx 4 your reply. yes, i was going through that link in postfix.org, and also dovecot.org because i am using dovecot. but still i get the error. the error is
--------------------------------------------------------------
Jun 18 22:24:42 localhost postfix/smtpd[3196]: NOQUEUE: reject: RCPT from unknown[xxx.xxx.xxx.xxx]: 554 <xxxxx@gmail.com>: Relay access denied; from=<xxx@xxxxx.xxx> to=<xxxxxx@gmail.com> proto=ESMTP helo=<yourc2c31d90dc>
Jun 18 22:24:45 localhost postfix/smtpd[3196]: disconnect from unknown[xxx.xxx.xxx.xxx]
-----------------------------------------------------------------

my main.cf is

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

smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
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

content_filter = scan:127.0.0.1:10026
receive_override_options = no_address_mappings

myhostname = mail.xxxxxx.xxx
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
localhost.localdomain, localhost
mydestination=localhost
relayhost =
home_mailbox = Maildir/
mynetworks = 127.0.0.0/8, 192.168.1.0/24
mailbox_size_limit = 0

virtual_mailbox_domains = /etc/postfix/vhosts
virtual_mailbox_base = /home/vmail
virtual_mailbox_maps = hash:/etc/postfix/vmaps
virtual_minimum_uid = 1000
virtual_uid_maps = static:5000
virtual_gid_maps = static:5000

smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth


recipient_delimiter = +
inet_interfaces = all

++++++++++++++++++++++++++++++++++++++++++++++

and my dovecot.conf is

base_dir = /var/run/dovecot/
protocols = imap pop3
log_path = /var/log/dovecot
info_log_path = /var/log/dovecot.info
login_dir = /var/run/dovecot/login
login_chroot = yes
login = imap
login_executable = /usr/lib/dovecot/imap-login
login_user = dovecot
login = pop3
login_executable = /usr/lib/dovecot/pop3-login
valid_chroot_dirs = /var/spool/vmail
default_mail_env = maildir:/home/vmail/%d/%n
imap_executable = /usr/lib/dovecot/imap
pop3_executable = /usr/lib/dovecot/pop3
auth = default
disable_plaintext_auth = no
auth_mechanisms = plain digest-md5
auth_userdb = passwd-file /etc/dovecot/users
auth_passdb = passwd-file /etc/dovecot/passwd
auth_executable = /usr/lib/dovecot/dovecot-auth
auth_user = root
auth_verbose = yes

++++++++++++++++++++++++++++++++++++++++++++

is there anything i have to change ?

help me.
mhmfasy
 
Posts: 4
Joined: Thu Jun 15, 2006 2:22 pm
Location: Srilanka

Postby kalinga » Mon Jun 19, 2006 8:48 am

can you show me the postconf -n out put ?

form what i see, you need to enable enable SASL, but just to make sure, just show me the postconf -n out put

are you running Postfix 2.3 ?
kalinga
Site Admin
 
Posts: 209
Joined: Fri Oct 14, 2005 3:19 pm
Location: Sri Lanka

Postby mhmfasy » Tue Jun 20, 2006 5:08 pm

hi,

the postconf -n output is here, yeah, the sasl i tried but no luck, guideme ow to solve this problem.


thanx



mail:~# postconf -n
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
append_dot_mydomain = no
biff = no
config_directory = /etc/postfix
content_filter = scan:127.0.0.1:10026
delay_warning_time = 4h
home_mailbox = Maildir/
inet_interfaces = all
mailbox_size_limit = 0
mydestination = localhost
myhostname = mail.xxxxxxx.lk
mynetworks = 127.0.0.0/8, 192.168.1.0/24, 10.0.0.0/24
receive_override_options = no_address_mappings
recipient_delimiter = +
relayhost =
smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
virtual_gid_maps = static:5000
virtual_mailbox_base = /home/vmail
virtual_mailbox_domains = /etc/postfix/vhosts
virtual_mailbox_maps = hash:/etc/postfix/vmaps
virtual_minimum_uid = 1000
virtual_uid_maps = static:5000
mhmfasy
 
Posts: 4
Joined: Thu Jun 15, 2006 2:22 pm
Location: Srilanka

Postby kalinga » Tue Jun 20, 2006 5:16 pm

hi,

what is your postfix ver ?

dovecot SASL only supported in postfix ver 2.3

read this as well

http://wiki.dovecot.org/PostfixAndDovec ... postfix%29

http://www.postfix.org/SASL_README.html#server_dovecot
kalinga
Site Admin
 
Posts: 209
Joined: Fri Oct 14, 2005 3:19 pm
Location: Sri Lanka


Return to Linux - Networking

Who is online

Users browsing this forum: No registered users and 0 guests