LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-09-2009, 07:10 AM   #1
Raakh
Member
 
Registered: May 2007
Posts: 128

Rep: Reputation: 15
SMTP problem


Hello,

I am sending mails with JavaMail. My code works fine while sending small quantity of emails from our vps but when sending in loop then start throwing the following errors:

1) javax.mail.MessagingException: Could not connect to SMTP host: mail.mydomain.com, port: 25, response: -1

2) javax.mail.MessagingException: Could not connect to SMTP host: mail.mydomain.com, port: 25;
nested exception is:
java.net.ConnectException: Connection refused

Is there problem of number of connections?
My OS is centOS Enterprise Linux 5.x and lxAdmin installed with Qmail

Thanks & best regards

Last edited by Raakh; 06-09-2009 at 07:11 AM.
 
Old 06-10-2009, 06:07 AM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,598

Rep: Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532
Hi,

You might increase the number in /var/qmail/control/concurrencyincoming, from 20 (in a default installation) to 100 and see if it helps.
 
Old 06-10-2009, 07:11 AM   #3
Raakh
Member
 
Registered: May 2007
Posts: 128

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by bathory View Post
Hi,

You might increase the number in /var/qmail/control/concurrencyincoming, from 20 (in a default installation) to 100 and see if it helps.
Thanks for your favorable reply.

I checked and its already 100

Thanks again & best regards
 
Old 06-10-2009, 07:42 AM   #4
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,598

Rep: Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532Reputation: 1532
You can increase it up to 255.
To check if you reach the 100 concurrent connections that is your limit now, grep for status in qmail-smtpd:
Code:
grep status /var/log/qmail/qmail-smtpd/current

Last edited by bathory; 06-10-2009 at 06:02 PM.
 
Old 06-10-2009, 04:11 PM   #5
jakev383
QmailToaster Developer
 
Registered: Dec 2005
Location: Burlington, NC
Distribution: CentOS, Voyage, Debian, Fedora
Posts: 220

Rep: Reputation: 31
Not sure what flavor of Qmail install you have, but you may also want to look at your tcp.smtp file and make sure you're not limiting how many addresses can be in a message if you're using the CHKUSER patch (CHKUSER_RCPTLIMIT)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
PHP SMTP connection to gmail SMTP protocol violation ratcateme Programming 9 02-23-2009 04:58 AM
smtp auth with sendmail through smtp.sbcglobal.yahoo.com woodson2 Fedora 0 10-23-2008 03:55 PM
SMTP problem grabro Linux - General 1 10-10-2008 05:11 AM
Binding SMTP service into IP tables, and redirecting SMTP to port 366 bamquest6 Linux - Software 1 09-24-2008 03:48 AM
SMTP problem pave Linux - Networking 3 10-13-2004 06:52 AM


All times are GMT -5. The time now is 11:34 PM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration