Cannot send mail from e-mail client
Error log :
Dec 12 10:51:57 mail postfix/smtpd[20948]: connect from unknown[156.33.44.94]
Dec 12 10:51:59 mail postfix/smtp[20943]: connect to mail.example.com[176.44.65.28]:25: Operation timed out
Dec 12 10:51:59 mail postfix/smtp[20944]: connect to mail.example.com[176.44.65.28]:25: Operation timed out
Dec 12 10:51:59 mail postfix/smtp[20943]: 17F375788205: to=<root@mail.example.com>, relay=none, delay=27864, delays=27834/0.03/30/0, dsn=4.4.1, status=deferred (connect to mail.example.com[176.44.65.28]:25: Operation timed out)
Dec 12 10:51:59 mail postfix/smtp[20944]: 0CF88578851A: to=<vscan@mail.example.com>, relay=none, delay=29065, delays=29035/0.01/30/0, dsn=4.4.1, status=deferred (connect to mail.example.com[176.44.65.28]:25: Operation timed out)
Dec 12 10:51:59 mail postfix/smtpd[20948]: NOQUEUE: reject: RCPT from unknown[156.33.44.94]: 554 5.7.1 <unknown[156.33.44.94]>: Client host rejected: Access denied; from= <admin@example.com>to= <test@gmail.com>proto=ESMTP helo=<[156.33.44.94]>
Dec 12 10:52:01 mail postfix/smtpd[20948]: disconnect from unknown[156.33.44.94]</test@gmail.com></admin@example.com></unknown[156.33.44.94]></vscan@mail.example.com></root@mail.example.com>
postfix main.cf :
broken_sasl_auth_clients = yes
command_directory = /usr/local/sbin
config_directory = /usr/local/etc/postfix
content_filter = smtp-amavis:[127.0.0.1]:10024
daemon_directory = /usr/local/libexec/postfix
data_directory = /var/db/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
dovecot_destination_recipient_limit = 1
html_directory = /usr/local/share/doc/postfix
inet_protocols = ipv4
mail_owner = postfix
mailq_path = /usr/local/bin/mailq
manpage_directory = /usr/local/man
mydestination = localhost.$mydomain, localhost
mydomain = example.com
myhostname = mail.example.com
mynetworks_style = host
newaliases_path = /usr/local/bin/newaliases
proxy_read_maps = $local_recipient_maps $mydestination $virtual_alias_maps $virtual_alias_domains $virtual_mailbox_maps $virtual_mailbox_domains $relay_recipient_maps $relay_domains $canonical_maps $sender_canonical_maps $recipient_canonical_maps $relocated_maps $transport_maps $mynetworks $virtual_mailbox_limit_maps
queue_directory = /var/spool/postfix
readme_directory = /usr/local/share/doc/postfix
relay_domains = proxy:mysql:/usr/local/etc/postfix/mysql_relay_domains_maps.cf
sample_directory = /usr/local/etc/postfix
sendmail_path = /usr/local/sbin/sendmail
setgid_group = maildrop
smtp_tls_note_starttls_offer = yes
smtp_use_tls = yes
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_non_fqdn_hostname, reject_non_fqdn_sender, reject_non_fqdn_recipient, reject_unauth_destination, reject_unauth_pipelining, reject_invalid_hostname, reject_rbl_client list.dsbl.org, reject_rbl_client bl.spamcop.net, reject_rbl_client sbl-xbl.spamhaus.org
smtpd_sasl_auth_enable = yes
smtpd_sasl_authenticated_header = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_path = private/auth
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_sender_restrictions = permit_sasl_authenticated, permit_mynetworks
smtpd_tls_CAfile = /etc/ssl/postfix/smtpd.pem
smtpd_tls_cert_file = /etc/ssl/postfix/smtpd.pem
smtpd_tls_key_file = /etc/ssl/postfix/smtpd.pem
smtpd_tls_loglevel = 0
smtpd_tls_received_header = yes
smtpd_tls_session_cache_timeout = 3600s
smtpd_use_tls = yes
soft_bounce = no
tls_random_source = dev:/dev/urandom
transport_maps = hash:/usr/local/etc/postfix/transport
unknown_local_recipient_reject_code = 550
vacation_destination_recipient_limit = 1
virtual_alias_maps = proxy:mysql:/usr/local/etc/postfix/mysql_virtual_alias_maps.cf
virtual_gid_maps = static:1002
virtual_mailbox_base = /mail
virtual_mailbox_domains = proxy:mysql:/usr/local/etc/postfix/mysql_virtual_domains_maps.cf
virtual_mailbox_limit = 51200000
virtual_mailbox_limit_maps = proxy:mysql:/usr/local/etc/postfix/mysql_virtual_mailbox_limit_maps.cf
virtual_mailbox_limit_override = yes
virtual_mailbox_maps = proxy:mysql:/usr/local/etc/postfix/mysql_virtual_mailbox_maps.cf
virtual_maildir_limit_message = Sorry, this user has overdrawn their diskspace quota. Please try again later.
virtual_minimum_uid = 1002
virtual_overquota_bounce = yes
virtual_transport = dovecot
virtual_uid_maps = static:1002
postconf: warning: /usr/local/etc/postfix/main.cf: unused parameter: virtual_create_maildirsize=yes
postconf: warning: /usr/local/etc/postfix/main.cf: unused parameter: virtual_mailbox_extended=yes
master.cf
smtp inet n - n - - smtpd
#smtp inet n - n - 1 postscreen
#smtpd pass - - n - - smtpd
#dnsblog unix - - n - 0 dnsblog
#tlsproxy unix - - n - 0 tlsproxy
#submission inet n - n - - smtpd
# -o syslog_name=postfix/submission
# -o smtpd_tls_security_level=encrypt
# -o smtpd_sasl_auth_enable=yes
# -o smtpd_client_restrictions=permit_sasl_authenticated,reject
# -o milter_macro_daemon_name=ORIGINATING
smtps inet n - n - - smtpd
# -o syslog_name=postfix/smtps
-o smtpd_tls_wrappermode=yes
-o smtpd_sasl_auth_enable=yes
-o smtpd_client_restrictions=permit_sasl_authenticated,reject
# -o milter_macro_daemon_name=ORIGINATING
#628 inet n - n - - qmqpd
pickup fifo n - n 60 1 pickup
cleanup unix n - n - 0 cleanup
qmgr fifo n - n 300 1 qmgr
#qmgr fifo n - n 300 1 oqmgr
tlsmgr unix - - n 1000? 1 tlsmgr
rewrite unix - - n - - trivial-rewrite
bounce unix - - n - 0 bounce
defer unix - - n - 0 bounce
trace unix - - n - 0 bounce
verify unix - - n - 1 verify
flush unix n - n 1000? 0 flush
proxymap unix - - n - - proxymap
proxywrite unix - - n - 1 proxymap
smtp unix - - n - - smtp
relay unix - - n - - smtp
# -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
showq unix n - n - - showq
error unix - - n - - error
retry unix - - n - - error
discard unix - - n - - discard
local unix - n n - - local
virtual unix - n n - - virtual
lmtp unix - - n - - lmtp
anvil unix - - n - 1 anvil
scache unix - - n - 1 scache
vacation unix - n n - - pipe
flags=DRhu user=vacation argv=/var/spool/vacation/vacation.pl
dovecot unix - n n - - pipe
flags=DRhu user=vmail:vmail argv=/usr/local/libexec/dovecot/deliver -f ${sender} -d ${recipient}
##Maia
smtp-amavis unix - - n - 2 smtp
-o smtp_data_done_timeout=2400
-o smtp_send_xforward_command=yes
-o disable_dns_lookups=yes
-o max_use=20
127.0.0.1:10025 inet n - n - - smtpd
-o content_filter=
-o local_recipient_maps=
-o relay_recipient_maps=
-o smtpd_restriction_classes=
-o smtpd_delay_reject=no
-o smtpd_client_restrictions=permit_mynetworks,reject
-o smtpd_helo_restrictions=
-o smtpd_sender_restrictions=
-o smtpd_recipient_restrictions=permit_mynetworks,reject
-o mynetworks_style=host
-o mynetworks=127.0.0.0/8,10.4.4.4/32
-o strict_rfc821_envelopes=yes
-o smtpd_error_sleep_time=0
-o smtpd_soft_error_limit=1001
-o smtpd_hard_error_limit=1000
-o smtpd_client_connection_count_limit=0
-o smtpd_client_connection_rate_limit=0
-o receive_override_options=no_header_body_checks,no_unknown_recipient_checks,no_address_mappings
I am using postfix 2.9.4 & dovecot 2.1.12, any help really appreciated
5 Replies
[17:36:45] C: Connected to mail.example.com, port 465
[17:36:46] S: 220 mail.example.com ESMTP Postfix
[17:36:46] C: EHLO [192.168.1.4]
[17:36:46] S: 250-mail.example.com
[17:36:46] S: 250-PIPELINING
[17:36:46] S: 250-SIZE 10240000
[17:36:46] S: 250-VRFY
[17:36:46] S: 250-ETRN
[17:36:46] S: 250-AUTH PLAIN
[17:36:46] S: 250-AUTH=PLAIN
[17:36:46] S: 250-ENHANCEDSTATUSCODES
[17:36:46] S: 250-8BITMIME
[17:36:46] S: 250 DSN
[17:36:46] C: MAIL FROM: <admin@example>SIZE=426
[17:36:48] S: 250 2.1.0 Ok
[17:36:48] C: RCPT TO: <test@domain2.com>[17:36:48] S: 554 5.7.1 <unknown[125.123.44.44]>: Client host rejected: Access denied
[17:36:48] C: RSET
[17:36:49] S: 250 2.0.0 Ok
[17:36:49] C: QUIT
[17:36:50] S: 221 2.0.0 Bye</unknown[125.123.44.44]></test@domain2.com></admin@example>
Strange thing is from thunderbird or outlook 2012 works fine
Have you configured The Bat to use SMTP authentication in your account settings?
I believe both Outlook and Thunderbird checks if the SMTP server requires/supports authentication when setting up the e-mail account, and enables this option automatically, which would explain why it works in these clients.
[17:36:46] S: 250-AUTH PLAIN
[17:36:46] S: 250-AUTH=PLAIN
Isn't it that line meant authenticated attempt from thebat?
@quantizer:
Yes, i have already set it up, how about this line
[17:36:46] S: 250-AUTH PLAIN [17:36:46] S: 250-AUTH=PLAIN
Isn't it that line meant authenticated attempt from thebat?
Nope, that's part of the server listing the features/commands that are supported - these show up after the client has sent the EHLO (or HELO) command. In your log, when a line begins with "S:", it's a response from the server, while the "C:" at the beginning shows that it's a command sent by the client.