LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS
User Name
Password
CentOS This forum is for the discussion of CentOS Linux. Note: This forum does not have any official participation.

Notices


Reply
  Search this Thread
Old 04-26-2018, 12:48 AM   #1
jiteshp715
LQ Newbie
 
Registered: Apr 2018
Posts: 2

Rep: Reputation: Disabled
Postfix with SMTP slow sending speed


Hello Admin,
I have configured an SMTP server for sending emails to our customers.
For this, I have used Postfix MTA with Cyrus.
All things working fine except one thing, the sending speed is too slow. It is sending around 1 mail per 5 seconds (approx).
I have spent 4-5 days already for finding the issue, but not found any solution.

This is My respolv.conf
nano /etc/resolv.conf
; Created by cloud-init on instance boot automatically, do not edit.
;
;nameserver 67.207.67.3
;nameserver 67.207.67.2
nameserver 8.8.8.8
search com


This is my main.cf
[root@mydomain ~]# 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
debugger_command = PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin ddd $daemon_directory/$process_name $process_id & sleep 5
default_process_limit = 10
html_directory = no
inet_interfaces = all
inet_protocols = all
mail_owner = postfix
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
milter_default_action = accept
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
mydomain = $myhostname
myhostname = mydomain.com
mynetworks = 127.0.0.1/32
myorigin = $myhostname
newaliases_path = /usr/bin/newaliases.postfix
non_smtpd_milters = $smtpd_milters
polite_destination_concurrency_limit = 3
polite_destination_rate_delay = 0
polite_destination_recipient_limit = 5
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.10.1/README_FILES
recipient_delimiter = +
relayhost =
sample_directory = /usr/share/doc/postfix-2.10.1/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtp_destination_concurrency_limit = 4
smtp_destination_rate_delay = 1s
smtp_extra_recipient_limit = 2
smtp_use_tls = yes
smtpd_banner = $myhostname ESMTP $mail_name
smtpd_client_restrictions = sleep 5
smtpd_delay_reject = no
smtpd_error_sleep_time = 30
smtpd_hard_error_limit = 20
smtpd_milters = inet:127.0.0.1:8891
smtpd_recipient_limit = 1000
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination, reject_rbl_client opm.blitzed.org, reject_rbl_client list.dsbl.org, reject_rbl_client sbl.spamhaus.org, reject_rbl_client cbl.abuseat.org, reject_rbl_client dul.dnsbl.sorbs.net
smtpd_sasl_auth_enable = yes
smtpd_sasl_authenticated_header = no
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_path = /etc/sasl2/smtpd.conf
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = cyrus
smtpd_sender_restrictions = reject_unknown_sender_domain
smtpd_soft_error_limit = 10
smtpd_tls_CAfile = /etc/ssl/certs/ca-bundle.crt
smtpd_tls_cert_file = /etc/postfix/ssl/mydomain_com.crt
smtpd_tls_key_file = /etc/postfix/ssl/mydomain.key
smtpd_tls_loglevel = 0
smtpd_tls_received_header = yes
smtpd_tls_security_level = may
smtpd_tls_session_cache_database = btree:/var/lib/postfix/smtpd_scache
smtpd_tls_session_cache_timeout = 10800s
smtpd_use_tls = yes
transport_maps = hash:/etc/postfix/transport
turtle_destination_concurrency_limit = 2
turtle_destination_rate_delay = 1s
turtle_destination_recipient_limit = 2
unknown_local_recipient_reject_code = 550
virtual_alias_maps = hash:/etc/postfix/virtual_users

My Maillog File:
Apr 25 12:05:07 mydomain postfix/cleanup[8062]: 79257C18584: message-id=<93d8f3b8e4191815f06ceed174bec8f8@nl.myclientdomain.com>
Apr 25 12:05:07 mydomain opendkim[940]: 79257C18584: DKIM-Signature field added (s=default, d=mydomain.com)
Apr 25 12:05:07 mydomain postfix/qmgr[7660]: 79257C18584: from=<news@mydomain.com>, size=4190, nrcpt=1 (queue active)
Apr 25 12:05:07 mydomain postfix/smtpd[7910]: disconnect from myclientdomain.com[167.99.154.159]
Apr 25 12:05:07 mydomain postfix/smtpd[7914]: connect from myclientdomain.com[167.99.154.159]
Apr 25 12:05:08 mydomain postfix/smtp[8053]: 79257C18584: to=<abc@gmail.com>, relay=gmail-smtp-in.l.google.com[209.85.201.26]:25, delay=0.76, delays=0.09/0/0.27/0.41, dsn=2.0.0, status=sent (250 2.0.0 OK 1524657908 y58-v6si2415264qtb.234 - gsmtp)
Apr 25 12:05:08 mydomain postfix/qmgr[7660]: 79257C18584: removed
Apr 25 12:05:12 mydomain postfix/smtpd[7914]: 95A20C18584: client=myclientdomain.com[167.99.154.159], sasl_method=CRAM-MD5, sasl_username=jitesh@mydomain.com
Apr 25 12:05:12 mydomain postfix/cleanup[8062]: 95A20C18584: message-id=<82022621ebd12ef802c965414fd8cef0@nl.myclientdomain.com>
Apr 25 12:05:12 mydomain opendkim[940]: 95A20C18584: DKIM-Signature field added (s=default, d=mydomain.com)
Apr 25 12:05:12 mydomain postfix/qmgr[7660]: 95A20C18584: from=<news@mydomain.com>, size=4187, nrcpt=1 (queue active)
Apr 25 12:05:12 mydomain postfix/smtpd[7914]: disconnect from myclientdomain.com[167.99.154.159]
Apr 25 12:05:12 mydomain postfix/smtpd[7956]: connect from myclientdomain.com[167.99.154.159]
Apr 25 12:05:13 mydomain postfix/smtp[8053]: 95A20C18584: to=<abcd@gmail.com>, relay=gmail-smtp-in.l.google.com[209.85.201.26]:25, delay=0.82, delays=0.09/0/0.28/0.45, dsn=2.0.0, status=sent (250 2.0.0 OK 1524657913 32si4669301qvb.261 - gsmtp)
Apr 25 12:05:13 mydomain postfix/qmgr[7660]: 95A20C18584: removed
Apr 25 12:05:17 mydomain postfix/smtpd[7956]: B54CBC18584: client=myclientdomain.com[167.99.154.159], sasl_method=CRAM-MD5, sasl_username=jitesh@mydomain.com
Apr 25 12:05:17 mydomain postfix/cleanup[8062]: B54CBC18584: message-id=<2cce882185d872d31979b9058bd13997@nl.myclientdomain.com>
Apr 25 12:05:17 mydomain opendkim[940]: B54CBC18584: DKIM-Signature field added (s=default, d=mydomain.com)
Apr 25 12:05:17 mydomain postfix/qmgr[7660]: B54CBC18584: from=<news@mydomain.com>, size=4179, nrcpt=1 (queue active)
Apr 25 12:05:17 mydomain postfix/smtpd[7956]: disconnect from myclientdomain.com[167.99.154.159]
Apr 25 12:05:17 mydomain postfix/smtpd[7910]: connect from myclientdomain.com[167.99.154.159]
Apr 25 12:05:18 mydomain postfix/smtp[8053]: B54CBC18584: to=<abcde@gmail.com>, relay=gmail-smtp-in.l.google.com[209.85.201.26]:25, delay=0.76, delays=0.09/0/0.27/0.4, dsn=2.0.0, status=sent (250 2.0.0 OK 1524657918 j12-v6si2946429qtf.334 - gsmtp)
Apr 25 12:05:18 mydomain postfix/qmgr[7660]: B54CBC18584: removed
Apr 25 12:05:22 mydomain postfix/smtpd[7910]: D63D6C18584: client=myclientdomain.com[167.99.154.159], sasl_method=CRAM-MD5, sasl_username=jitesh@mydomain.com

Thanks In Advance
Jitesh
 
Old 04-26-2018, 08:47 AM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,831
Blog Entries: 15

Rep: Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669Reputation: 1669
Run "df -hP /var" then "df -hiP /var" to verify you have plenty of space and plenty of free inodes in /var.

We just ran into an odd problem here where CUPS took up all the inodes in /var (space on the other hand was not problem). We initially saw delays in print jobs and email because of this and clearing that issue up resolved both issues.
 
Old 04-27-2018, 01:00 AM   #3
jiteshp715
LQ Newbie
 
Registered: Apr 2018
Posts: 2

Original Poster
Rep: Reputation: Disabled
Hi MensaWater, thanks for the reply, I have checked these commands, I think there is no space problem on my CPU.

Have a look:

df -hP /var
Filesystem Size Used Avail Use% Mounted on
/dev/vda1 25G 1.5G 24G 6% /


df -hiP /var
Filesystem Inodes IUsed IFree IUse% Mounted on
/dev/vda1 13M 34K 13M 1% /

The issue is with postfix. When I try to send my emails using Sendgrid SMTP, that was working fine and the speed was very good. But my postfix SMTP is still too slow.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Postfix is not sending via my Gmail account smtp. Usalabs Linux - Server 4 02-11-2011 12:03 PM
Thunderbird SMTP error while sending mails in Windows7 to Postfix rytec General 8 01-28-2011 09:24 AM
Postfix Problem Sending SMTP Mail j.smith1981 Linux - Server 2 10-27-2010 09:51 PM
smtp 0x800ccc0f error sending mail to postfix Corsari Linux - Networking 4 09-22-2008 10:51 AM
Postfix Help - Sending via third party smtp scarstens Linux - Networking 3 01-27-2004 05:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS

All times are GMT -5. The time now is 08:37 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration