You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-user@james.apache.org by Mahesh Sivarama Pillai <sr...@gmail.com> on 2015/04/01 09:22:35 UTC

PRODUCTION ISSUE: James 2.3.2 Refusing connections..Need URGENT HELP !!!!!

Hi All,

We have rolled out James 2.3.2 to production for our email processing
application. I see that James is no longed accepting connetions after few
days of run. It processes around 100K email a day and sends a good amount
of Notification emails through RemoveDelivery.  James is running on a 4 CPU
machine with 8GB RAM. Heapsize of James is set to 4GB with Openjdk 1.7.

INITIALLY WE THOUGHT  the server was getting killed/terminated. As per the
latest information, server is not killed.. Our support team used to restart
the server when we get "Connection Refused" error from port 25..We have a
monitoring tool which Connects to James server every few seconds, and issue
a QUIT command... This monitoring tool is getting Connection Refused error.
Hence the team thought the server is down and followed the routine Stop,
Start commands...

I have the following configurations in various places in the config.xml. I
have INFO logging enabled. I couldnt find any WARN messages about
connections.

SMTP Server (the only process enabled):
<connectiontimeout>360000</connectiontimeout>

Spool Manager: <threads> 10 </threads>

Connections Manager

    <connections>
      <idle-timeout>300000</idle-timeout>
      <max-connections>30</max-connections>
   </connections>

Thread Manager

   <thread-manager>
      <thread-group>
         <name>default</name>
         <priority>5</priority>
         <is-daemon>false</is-daemon>
         <max-threads>100</max-threads>
         <min-threads>20</min-threads>
         <min-spare-threads>20</min-spare-threads>
      </thread-group>
   </thread-manager>

The total number of threads (spool+remotedelivery etc ) are under very much
under 100. We don't have any DB configuration in config.xml as well. Do you
think the timeout values might cause the connection refused errors ?.
Especially the idle-timeout ? Isn't 5 minutes too high ? If say 30 clients
are taking few minutes, this will be more than enough to raise an alert
from the monitoring tool...even if all the connections are being used, it
should be release after the processing done right ? Is there any chance of
the connections not being released and going back to the pool ? Please
provide your comments..

Thanks
Mahesh

Re: PRODUCTION ISSUE: James 2.3.2 Refusing connections..Need URGENT HELP !!!!!

Posted by Mahesh Sivarama Pillai <sr...@gmail.com>.
Ours is a virtual machine (VMWare).. Max heap is set to 4GB.. I will do a
stress test. Infact we did it during our LT (Load testing)... I will post
the details here once I have enough data.. What I was trying to understand
is "is there any possibility of the 30 max connections to go stale and not
sent back to the pool".. If its an issue with the high timeout value, we
should see the emails getting processed after 5 minutes... What is the
ideal value for SMTP idle nowadays... I followed the default value in the
config.xml....

Thanks for the help and pointers so far..

Thanks
Mahesh

On Wed, Apr 1, 2015 at 4:15 PM, Özgür EROĞLU <oe...@gmail.com> wrote:

> Hi Mahesh,
>
> I can not suggest specific values to you. I think you should write a
> stress tester and tune parameters to get the best fit. BTW, although a
> 4CPU( xeon?) machine should perform very well in most of the usage
> scenarios, Memory is another parameter which can become a bottleneck. So,
> as your server is a production server you should allocate as much memory as
> possible to get better performance.
>
> Özgür Eroğlu
>
>
>
> On 04/01/2015 12:31 PM, Mahesh Sivarama Pillai wrote:
>
>> Thanks Özgür...
>>
>> This email application is not exposed to any real users with Inbox. Its an
>> internal email processing application which will recieve emails routed
>> from
>> our Enterprise Email server. So each of our James nodes will receive an
>> email and process it (extract some info from subject and body and call
>> couple of web services)..Let me try to adjust the parameters as you
>> specified. Just a clarification.. In a 4 CPU machine, how far we can go
>> ahead with those parameters ? Can you suggest some figures based on your
>> experience ? The reason is I can't do a trial and error thing in
>> production..
>>
>> Thanks
>> Mahesh
>>
>> On Wed, Apr 1, 2015 at 2:36 PM, Özgür EROĞLU <oe...@gmail.com>
>> wrote:
>>
>>  Sorry, I could not get your point in using two servers which are getting
>>> mail for the same domain, without having a common db  for them.  Of
>>> course
>>> as I do not know you project details, it might have special use case
>>> here.
>>> I just wondered.
>>>
>>>
>>> And I meant;
>>>
>>> increase Spool Manager threads
>>> decrease smtp connectiontimeout
>>> decrease connection manager idle timeout
>>> and increase  connection manager max-connections.
>>>
>>>
>>> Özgür Eroğlu
>>>
>>>
>>> On 04/01/2015 11:43 AM, Mahesh Sivarama Pillai wrote:
>>>
>>>  Hi,
>>>>
>>>>    Thanks for the inputs. We don't have any DB configurations. Its all
>>>> file
>>>> based. There are two servers which are already behind the load balancer.
>>>> We
>>>> were getting Too Many Open files issues.. We have increased the ulimit
>>>> to
>>>> the maximum two days back. Did you mean "decrease the timeout and
>>>> increase
>>>> the max-connections ?" In a 4CPU machine, can I increase the
>>>> max-connections to say 100 if we came to know that its about load ?
>>>>
>>>> Thanks
>>>> Mahesh
>>>>
>>>> On Wed, Apr 1, 2015 at 1:16 PM, Özgür EROĞLU <oe...@gmail.com>
>>>> wrote:
>>>>
>>>>   Hi Mahesh,
>>>>
>>>>> All you have asked may be the cause, I can not give clear answer right
>>>>> now. But if your system have sufficient resources try to increase
>>>>> max-connections and timeout parameters. And observe whether any
>>>>> differences
>>>>> occur or not.
>>>>>
>>>>> But I recommend you to use more than one James instances which are
>>>>> connected to the same and replicated database server( howto do it
>>>>> depends
>>>>> on your DB choice) and put them all behind a load balancer, so that you
>>>>> can
>>>>> reduce the load on one server (of course this will be solution only if
>>>>> the
>>>>> problem is the actual load).
>>>>>
>>>>> Özgür Eroğlu
>>>>>
>>>>>
>>>>> On 04/01/2015 10:22 AM, Mahesh Sivarama Pillai wrote:
>>>>>
>>>>>   Hi All,
>>>>>
>>>>>> We have rolled out James 2.3.2 to production for our email processing
>>>>>> application. I see that James is no longed accepting connetions after
>>>>>> few
>>>>>> days of run. It processes around 100K email a day and sends a good
>>>>>> amount
>>>>>> of Notification emails through RemoveDelivery.  James is running on a
>>>>>> 4
>>>>>> CPU
>>>>>> machine with 8GB RAM. Heapsize of James is set to 4GB with Openjdk
>>>>>> 1.7.
>>>>>>
>>>>>> INITIALLY WE THOUGHT  the server was getting killed/terminated. As per
>>>>>> the
>>>>>> latest information, server is not killed.. Our support team used to
>>>>>> restart
>>>>>> the server when we get "Connection Refused" error from port 25..We
>>>>>> have
>>>>>> a
>>>>>> monitoring tool which Connects to James server every few seconds, and
>>>>>> issue
>>>>>> a QUIT command... This monitoring tool is getting Connection Refused
>>>>>> error.
>>>>>> Hence the team thought the server is down and followed the routine
>>>>>> Stop,
>>>>>> Start commands...
>>>>>>
>>>>>> I have the following configurations in various places in the
>>>>>> config.xml. I
>>>>>> have INFO logging enabled. I couldnt find any WARN messages about
>>>>>> connections.
>>>>>>
>>>>>> SMTP Server (the only process enabled):
>>>>>> <connectiontimeout>360000</connectiontimeout>
>>>>>>
>>>>>> Spool Manager: <threads> 10 </threads>
>>>>>>
>>>>>> Connections Manager
>>>>>>
>>>>>>        <connections>
>>>>>>          <idle-timeout>300000</idle-timeout>
>>>>>>          <max-connections>30</max-connections>
>>>>>>       </connections>
>>>>>>
>>>>>> Thread Manager
>>>>>>
>>>>>>       <thread-manager>
>>>>>>          <thread-group>
>>>>>>             <name>default</name>
>>>>>>             <priority>5</priority>
>>>>>>             <is-daemon>false</is-daemon>
>>>>>>             <max-threads>100</max-threads>
>>>>>>             <min-threads>20</min-threads>
>>>>>>             <min-spare-threads>20</min-spare-threads>
>>>>>>          </thread-group>
>>>>>>       </thread-manager>
>>>>>>
>>>>>> The total number of threads (spool+remotedelivery etc ) are under very
>>>>>> much
>>>>>> under 100. We don't have any DB configuration in config.xml as well.
>>>>>> Do
>>>>>> you
>>>>>> think the timeout values might cause the connection refused errors ?.
>>>>>> Especially the idle-timeout ? Isn't 5 minutes too high ? If say 30
>>>>>> clients
>>>>>> are taking few minutes, this will be more than enough to raise an
>>>>>> alert
>>>>>> from the monitoring tool...even if all the connections are being used,
>>>>>> it
>>>>>> should be release after the processing done right ? Is there any
>>>>>> chance
>>>>>> of
>>>>>> the connections not being released and going back to the pool ? Please
>>>>>> provide your comments..
>>>>>>
>>>>>> Thanks
>>>>>> Mahesh
>>>>>>
>>>>>>
>>>>>>   ------------------------------------------------------------
>>>>>> ---------
>>>>>>
>>>>> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
>>>>> For additional commands, e-mail: server-user-help@james.apache.org
>>>>>
>>>>>
>>>>>
>>>>>  ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
>>> For additional commands, e-mail: server-user-help@james.apache.org
>>>
>>>
>>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
> For additional commands, e-mail: server-user-help@james.apache.org
>
>

Re: PRODUCTION ISSUE: James 2.3.2 Refusing connections..Need URGENT HELP !!!!!

Posted by Özgür EROĞLU <oe...@gmail.com>.
Hi Mahesh,

I can not suggest specific values to you. I think you should write a 
stress tester and tune parameters to get the best fit. BTW, although a 
4CPU( xeon?) machine should perform very well in most of the usage 
scenarios, Memory is another parameter which can become a bottleneck. 
So, as your server is a production server you should allocate as much 
memory as possible to get better performance.

Özgür Eroğlu


On 04/01/2015 12:31 PM, Mahesh Sivarama Pillai wrote:
> Thanks Özgür...
>
> This email application is not exposed to any real users with Inbox. Its an
> internal email processing application which will recieve emails routed from
> our Enterprise Email server. So each of our James nodes will receive an
> email and process it (extract some info from subject and body and call
> couple of web services)..Let me try to adjust the parameters as you
> specified. Just a clarification.. In a 4 CPU machine, how far we can go
> ahead with those parameters ? Can you suggest some figures based on your
> experience ? The reason is I can't do a trial and error thing in
> production..
>
> Thanks
> Mahesh
>
> On Wed, Apr 1, 2015 at 2:36 PM, Özgür EROĞLU <oe...@gmail.com> wrote:
>
>> Sorry, I could not get your point in using two servers which are getting
>> mail for the same domain, without having a common db  for them.  Of course
>> as I do not know you project details, it might have special use case here.
>> I just wondered.
>>
>>
>> And I meant;
>>
>> increase Spool Manager threads
>> decrease smtp connectiontimeout
>> decrease connection manager idle timeout
>> and increase  connection manager max-connections.
>>
>>
>> Özgür Eroğlu
>>
>>
>> On 04/01/2015 11:43 AM, Mahesh Sivarama Pillai wrote:
>>
>>> Hi,
>>>
>>>    Thanks for the inputs. We don't have any DB configurations. Its all file
>>> based. There are two servers which are already behind the load balancer.
>>> We
>>> were getting Too Many Open files issues.. We have increased the ulimit to
>>> the maximum two days back. Did you mean "decrease the timeout and increase
>>> the max-connections ?" In a 4CPU machine, can I increase the
>>> max-connections to say 100 if we came to know that its about load ?
>>>
>>> Thanks
>>> Mahesh
>>>
>>> On Wed, Apr 1, 2015 at 1:16 PM, Özgür EROĞLU <oe...@gmail.com>
>>> wrote:
>>>
>>>   Hi Mahesh,
>>>> All you have asked may be the cause, I can not give clear answer right
>>>> now. But if your system have sufficient resources try to increase
>>>> max-connections and timeout parameters. And observe whether any
>>>> differences
>>>> occur or not.
>>>>
>>>> But I recommend you to use more than one James instances which are
>>>> connected to the same and replicated database server( howto do it depends
>>>> on your DB choice) and put them all behind a load balancer, so that you
>>>> can
>>>> reduce the load on one server (of course this will be solution only if
>>>> the
>>>> problem is the actual load).
>>>>
>>>> Özgür Eroğlu
>>>>
>>>>
>>>> On 04/01/2015 10:22 AM, Mahesh Sivarama Pillai wrote:
>>>>
>>>>   Hi All,
>>>>> We have rolled out James 2.3.2 to production for our email processing
>>>>> application. I see that James is no longed accepting connetions after
>>>>> few
>>>>> days of run. It processes around 100K email a day and sends a good
>>>>> amount
>>>>> of Notification emails through RemoveDelivery.  James is running on a 4
>>>>> CPU
>>>>> machine with 8GB RAM. Heapsize of James is set to 4GB with Openjdk 1.7.
>>>>>
>>>>> INITIALLY WE THOUGHT  the server was getting killed/terminated. As per
>>>>> the
>>>>> latest information, server is not killed.. Our support team used to
>>>>> restart
>>>>> the server when we get "Connection Refused" error from port 25..We have
>>>>> a
>>>>> monitoring tool which Connects to James server every few seconds, and
>>>>> issue
>>>>> a QUIT command... This monitoring tool is getting Connection Refused
>>>>> error.
>>>>> Hence the team thought the server is down and followed the routine Stop,
>>>>> Start commands...
>>>>>
>>>>> I have the following configurations in various places in the
>>>>> config.xml. I
>>>>> have INFO logging enabled. I couldnt find any WARN messages about
>>>>> connections.
>>>>>
>>>>> SMTP Server (the only process enabled):
>>>>> <connectiontimeout>360000</connectiontimeout>
>>>>>
>>>>> Spool Manager: <threads> 10 </threads>
>>>>>
>>>>> Connections Manager
>>>>>
>>>>>        <connections>
>>>>>          <idle-timeout>300000</idle-timeout>
>>>>>          <max-connections>30</max-connections>
>>>>>       </connections>
>>>>>
>>>>> Thread Manager
>>>>>
>>>>>       <thread-manager>
>>>>>          <thread-group>
>>>>>             <name>default</name>
>>>>>             <priority>5</priority>
>>>>>             <is-daemon>false</is-daemon>
>>>>>             <max-threads>100</max-threads>
>>>>>             <min-threads>20</min-threads>
>>>>>             <min-spare-threads>20</min-spare-threads>
>>>>>          </thread-group>
>>>>>       </thread-manager>
>>>>>
>>>>> The total number of threads (spool+remotedelivery etc ) are under very
>>>>> much
>>>>> under 100. We don't have any DB configuration in config.xml as well. Do
>>>>> you
>>>>> think the timeout values might cause the connection refused errors ?.
>>>>> Especially the idle-timeout ? Isn't 5 minutes too high ? If say 30
>>>>> clients
>>>>> are taking few minutes, this will be more than enough to raise an alert
>>>>> from the monitoring tool...even if all the connections are being used,
>>>>> it
>>>>> should be release after the processing done right ? Is there any chance
>>>>> of
>>>>> the connections not being released and going back to the pool ? Please
>>>>> provide your comments..
>>>>>
>>>>> Thanks
>>>>> Mahesh
>>>>>
>>>>>
>>>>>   ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
>>>> For additional commands, e-mail: server-user-help@james.apache.org
>>>>
>>>>
>>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
>> For additional commands, e-mail: server-user-help@james.apache.org
>>
>>


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: PRODUCTION ISSUE: James 2.3.2 Refusing connections..Need URGENT HELP !!!!!

Posted by Mahesh Sivarama Pillai <sr...@gmail.com>.
Thanks Özgür...

This email application is not exposed to any real users with Inbox. Its an
internal email processing application which will recieve emails routed from
our Enterprise Email server. So each of our James nodes will receive an
email and process it (extract some info from subject and body and call
couple of web services)..Let me try to adjust the parameters as you
specified. Just a clarification.. In a 4 CPU machine, how far we can go
ahead with those parameters ? Can you suggest some figures based on your
experience ? The reason is I can't do a trial and error thing in
production..

Thanks
Mahesh

On Wed, Apr 1, 2015 at 2:36 PM, Özgür EROĞLU <oe...@gmail.com> wrote:

> Sorry, I could not get your point in using two servers which are getting
> mail for the same domain, without having a common db  for them.  Of course
> as I do not know you project details, it might have special use case here.
> I just wondered.
>
>
> And I meant;
>
> increase Spool Manager threads
> decrease smtp connectiontimeout
> decrease connection manager idle timeout
> and increase  connection manager max-connections.
>
>
> Özgür Eroğlu
>
>
> On 04/01/2015 11:43 AM, Mahesh Sivarama Pillai wrote:
>
>> Hi,
>>
>>   Thanks for the inputs. We don't have any DB configurations. Its all file
>> based. There are two servers which are already behind the load balancer.
>> We
>> were getting Too Many Open files issues.. We have increased the ulimit to
>> the maximum two days back. Did you mean "decrease the timeout and increase
>> the max-connections ?" In a 4CPU machine, can I increase the
>> max-connections to say 100 if we came to know that its about load ?
>>
>> Thanks
>> Mahesh
>>
>> On Wed, Apr 1, 2015 at 1:16 PM, Özgür EROĞLU <oe...@gmail.com>
>> wrote:
>>
>>  Hi Mahesh,
>>>
>>> All you have asked may be the cause, I can not give clear answer right
>>> now. But if your system have sufficient resources try to increase
>>> max-connections and timeout parameters. And observe whether any
>>> differences
>>> occur or not.
>>>
>>> But I recommend you to use more than one James instances which are
>>> connected to the same and replicated database server( howto do it depends
>>> on your DB choice) and put them all behind a load balancer, so that you
>>> can
>>> reduce the load on one server (of course this will be solution only if
>>> the
>>> problem is the actual load).
>>>
>>> Özgür Eroğlu
>>>
>>>
>>> On 04/01/2015 10:22 AM, Mahesh Sivarama Pillai wrote:
>>>
>>>  Hi All,
>>>>
>>>> We have rolled out James 2.3.2 to production for our email processing
>>>> application. I see that James is no longed accepting connetions after
>>>> few
>>>> days of run. It processes around 100K email a day and sends a good
>>>> amount
>>>> of Notification emails through RemoveDelivery.  James is running on a 4
>>>> CPU
>>>> machine with 8GB RAM. Heapsize of James is set to 4GB with Openjdk 1.7.
>>>>
>>>> INITIALLY WE THOUGHT  the server was getting killed/terminated. As per
>>>> the
>>>> latest information, server is not killed.. Our support team used to
>>>> restart
>>>> the server when we get "Connection Refused" error from port 25..We have
>>>> a
>>>> monitoring tool which Connects to James server every few seconds, and
>>>> issue
>>>> a QUIT command... This monitoring tool is getting Connection Refused
>>>> error.
>>>> Hence the team thought the server is down and followed the routine Stop,
>>>> Start commands...
>>>>
>>>> I have the following configurations in various places in the
>>>> config.xml. I
>>>> have INFO logging enabled. I couldnt find any WARN messages about
>>>> connections.
>>>>
>>>> SMTP Server (the only process enabled):
>>>> <connectiontimeout>360000</connectiontimeout>
>>>>
>>>> Spool Manager: <threads> 10 </threads>
>>>>
>>>> Connections Manager
>>>>
>>>>       <connections>
>>>>         <idle-timeout>300000</idle-timeout>
>>>>         <max-connections>30</max-connections>
>>>>      </connections>
>>>>
>>>> Thread Manager
>>>>
>>>>      <thread-manager>
>>>>         <thread-group>
>>>>            <name>default</name>
>>>>            <priority>5</priority>
>>>>            <is-daemon>false</is-daemon>
>>>>            <max-threads>100</max-threads>
>>>>            <min-threads>20</min-threads>
>>>>            <min-spare-threads>20</min-spare-threads>
>>>>         </thread-group>
>>>>      </thread-manager>
>>>>
>>>> The total number of threads (spool+remotedelivery etc ) are under very
>>>> much
>>>> under 100. We don't have any DB configuration in config.xml as well. Do
>>>> you
>>>> think the timeout values might cause the connection refused errors ?.
>>>> Especially the idle-timeout ? Isn't 5 minutes too high ? If say 30
>>>> clients
>>>> are taking few minutes, this will be more than enough to raise an alert
>>>> from the monitoring tool...even if all the connections are being used,
>>>> it
>>>> should be release after the processing done right ? Is there any chance
>>>> of
>>>> the connections not being released and going back to the pool ? Please
>>>> provide your comments..
>>>>
>>>> Thanks
>>>> Mahesh
>>>>
>>>>
>>>>  ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
>>> For additional commands, e-mail: server-user-help@james.apache.org
>>>
>>>
>>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
> For additional commands, e-mail: server-user-help@james.apache.org
>
>

Re: PRODUCTION ISSUE: James 2.3.2 Refusing connections..Need URGENT HELP !!!!!

Posted by Özgür EROĞLU <oe...@gmail.com>.
Sorry, I could not get your point in using two servers which are getting 
mail for the same domain, without having a common db  for them.  Of 
course as I do not know you project details, it might have special use 
case here. I just wondered.


And I meant;

increase Spool Manager threads
decrease smtp connectiontimeout
decrease connection manager idle timeout
and increase  connection manager max-connections.


Özgür Eroğlu

On 04/01/2015 11:43 AM, Mahesh Sivarama Pillai wrote:
> Hi,
>
>   Thanks for the inputs. We don't have any DB configurations. Its all file
> based. There are two servers which are already behind the load balancer. We
> were getting Too Many Open files issues.. We have increased the ulimit to
> the maximum two days back. Did you mean "decrease the timeout and increase
> the max-connections ?" In a 4CPU machine, can I increase the
> max-connections to say 100 if we came to know that its about load ?
>
> Thanks
> Mahesh
>
> On Wed, Apr 1, 2015 at 1:16 PM, Özgür EROĞLU <oe...@gmail.com> wrote:
>
>> Hi Mahesh,
>>
>> All you have asked may be the cause, I can not give clear answer right
>> now. But if your system have sufficient resources try to increase
>> max-connections and timeout parameters. And observe whether any differences
>> occur or not.
>>
>> But I recommend you to use more than one James instances which are
>> connected to the same and replicated database server( howto do it depends
>> on your DB choice) and put them all behind a load balancer, so that you can
>> reduce the load on one server (of course this will be solution only if the
>> problem is the actual load).
>>
>> Özgür Eroğlu
>>
>>
>> On 04/01/2015 10:22 AM, Mahesh Sivarama Pillai wrote:
>>
>>> Hi All,
>>>
>>> We have rolled out James 2.3.2 to production for our email processing
>>> application. I see that James is no longed accepting connetions after few
>>> days of run. It processes around 100K email a day and sends a good amount
>>> of Notification emails through RemoveDelivery.  James is running on a 4
>>> CPU
>>> machine with 8GB RAM. Heapsize of James is set to 4GB with Openjdk 1.7.
>>>
>>> INITIALLY WE THOUGHT  the server was getting killed/terminated. As per the
>>> latest information, server is not killed.. Our support team used to
>>> restart
>>> the server when we get "Connection Refused" error from port 25..We have a
>>> monitoring tool which Connects to James server every few seconds, and
>>> issue
>>> a QUIT command... This monitoring tool is getting Connection Refused
>>> error.
>>> Hence the team thought the server is down and followed the routine Stop,
>>> Start commands...
>>>
>>> I have the following configurations in various places in the config.xml. I
>>> have INFO logging enabled. I couldnt find any WARN messages about
>>> connections.
>>>
>>> SMTP Server (the only process enabled):
>>> <connectiontimeout>360000</connectiontimeout>
>>>
>>> Spool Manager: <threads> 10 </threads>
>>>
>>> Connections Manager
>>>
>>>       <connections>
>>>         <idle-timeout>300000</idle-timeout>
>>>         <max-connections>30</max-connections>
>>>      </connections>
>>>
>>> Thread Manager
>>>
>>>      <thread-manager>
>>>         <thread-group>
>>>            <name>default</name>
>>>            <priority>5</priority>
>>>            <is-daemon>false</is-daemon>
>>>            <max-threads>100</max-threads>
>>>            <min-threads>20</min-threads>
>>>            <min-spare-threads>20</min-spare-threads>
>>>         </thread-group>
>>>      </thread-manager>
>>>
>>> The total number of threads (spool+remotedelivery etc ) are under very
>>> much
>>> under 100. We don't have any DB configuration in config.xml as well. Do
>>> you
>>> think the timeout values might cause the connection refused errors ?.
>>> Especially the idle-timeout ? Isn't 5 minutes too high ? If say 30 clients
>>> are taking few minutes, this will be more than enough to raise an alert
>>> from the monitoring tool...even if all the connections are being used, it
>>> should be release after the processing done right ? Is there any chance of
>>> the connections not being released and going back to the pool ? Please
>>> provide your comments..
>>>
>>> Thanks
>>> Mahesh
>>>
>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
>> For additional commands, e-mail: server-user-help@james.apache.org
>>
>>


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: PRODUCTION ISSUE: James 2.3.2 Refusing connections..Need URGENT HELP !!!!!

Posted by Mahesh Sivarama Pillai <sr...@gmail.com>.
Hi,

 Thanks for the inputs. We don't have any DB configurations. Its all file
based. There are two servers which are already behind the load balancer. We
were getting Too Many Open files issues.. We have increased the ulimit to
the maximum two days back. Did you mean "decrease the timeout and increase
the max-connections ?" In a 4CPU machine, can I increase the
max-connections to say 100 if we came to know that its about load ?

Thanks
Mahesh

On Wed, Apr 1, 2015 at 1:16 PM, Özgür EROĞLU <oe...@gmail.com> wrote:

> Hi Mahesh,
>
> All you have asked may be the cause, I can not give clear answer right
> now. But if your system have sufficient resources try to increase
> max-connections and timeout parameters. And observe whether any differences
> occur or not.
>
> But I recommend you to use more than one James instances which are
> connected to the same and replicated database server( howto do it depends
> on your DB choice) and put them all behind a load balancer, so that you can
> reduce the load on one server (of course this will be solution only if the
> problem is the actual load).
>
> Özgür Eroğlu
>
>
> On 04/01/2015 10:22 AM, Mahesh Sivarama Pillai wrote:
>
>> Hi All,
>>
>> We have rolled out James 2.3.2 to production for our email processing
>> application. I see that James is no longed accepting connetions after few
>> days of run. It processes around 100K email a day and sends a good amount
>> of Notification emails through RemoveDelivery.  James is running on a 4
>> CPU
>> machine with 8GB RAM. Heapsize of James is set to 4GB with Openjdk 1.7.
>>
>> INITIALLY WE THOUGHT  the server was getting killed/terminated. As per the
>> latest information, server is not killed.. Our support team used to
>> restart
>> the server when we get "Connection Refused" error from port 25..We have a
>> monitoring tool which Connects to James server every few seconds, and
>> issue
>> a QUIT command... This monitoring tool is getting Connection Refused
>> error.
>> Hence the team thought the server is down and followed the routine Stop,
>> Start commands...
>>
>> I have the following configurations in various places in the config.xml. I
>> have INFO logging enabled. I couldnt find any WARN messages about
>> connections.
>>
>> SMTP Server (the only process enabled):
>> <connectiontimeout>360000</connectiontimeout>
>>
>> Spool Manager: <threads> 10 </threads>
>>
>> Connections Manager
>>
>>      <connections>
>>        <idle-timeout>300000</idle-timeout>
>>        <max-connections>30</max-connections>
>>     </connections>
>>
>> Thread Manager
>>
>>     <thread-manager>
>>        <thread-group>
>>           <name>default</name>
>>           <priority>5</priority>
>>           <is-daemon>false</is-daemon>
>>           <max-threads>100</max-threads>
>>           <min-threads>20</min-threads>
>>           <min-spare-threads>20</min-spare-threads>
>>        </thread-group>
>>     </thread-manager>
>>
>> The total number of threads (spool+remotedelivery etc ) are under very
>> much
>> under 100. We don't have any DB configuration in config.xml as well. Do
>> you
>> think the timeout values might cause the connection refused errors ?.
>> Especially the idle-timeout ? Isn't 5 minutes too high ? If say 30 clients
>> are taking few minutes, this will be more than enough to raise an alert
>> from the monitoring tool...even if all the connections are being used, it
>> should be release after the processing done right ? Is there any chance of
>> the connections not being released and going back to the pool ? Please
>> provide your comments..
>>
>> Thanks
>> Mahesh
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
> For additional commands, e-mail: server-user-help@james.apache.org
>
>

Re: PRODUCTION ISSUE: James 2.3.2 Refusing connections..Need URGENT HELP !!!!!

Posted by Özgür EROĞLU <oe...@gmail.com>.
Hi Mahesh,

All you have asked may be the cause, I can not give clear answer right 
now. But if your system have sufficient resources try to increase 
max-connections and timeout parameters. And observe whether any 
differences occur or not.

But I recommend you to use more than one James instances which are 
connected to the same and replicated database server( howto do it 
depends on your DB choice) and put them all behind a load balancer, so 
that you can reduce the load on one server (of course this will be 
solution only if the problem is the actual load).

Özgür Eroğlu

On 04/01/2015 10:22 AM, Mahesh Sivarama Pillai wrote:
> Hi All,
>
> We have rolled out James 2.3.2 to production for our email processing
> application. I see that James is no longed accepting connetions after few
> days of run. It processes around 100K email a day and sends a good amount
> of Notification emails through RemoveDelivery.  James is running on a 4 CPU
> machine with 8GB RAM. Heapsize of James is set to 4GB with Openjdk 1.7.
>
> INITIALLY WE THOUGHT  the server was getting killed/terminated. As per the
> latest information, server is not killed.. Our support team used to restart
> the server when we get "Connection Refused" error from port 25..We have a
> monitoring tool which Connects to James server every few seconds, and issue
> a QUIT command... This monitoring tool is getting Connection Refused error.
> Hence the team thought the server is down and followed the routine Stop,
> Start commands...
>
> I have the following configurations in various places in the config.xml. I
> have INFO logging enabled. I couldnt find any WARN messages about
> connections.
>
> SMTP Server (the only process enabled):
> <connectiontimeout>360000</connectiontimeout>
>
> Spool Manager: <threads> 10 </threads>
>
> Connections Manager
>
>      <connections>
>        <idle-timeout>300000</idle-timeout>
>        <max-connections>30</max-connections>
>     </connections>
>
> Thread Manager
>
>     <thread-manager>
>        <thread-group>
>           <name>default</name>
>           <priority>5</priority>
>           <is-daemon>false</is-daemon>
>           <max-threads>100</max-threads>
>           <min-threads>20</min-threads>
>           <min-spare-threads>20</min-spare-threads>
>        </thread-group>
>     </thread-manager>
>
> The total number of threads (spool+remotedelivery etc ) are under very much
> under 100. We don't have any DB configuration in config.xml as well. Do you
> think the timeout values might cause the connection refused errors ?.
> Especially the idle-timeout ? Isn't 5 minutes too high ? If say 30 clients
> are taking few minutes, this will be more than enough to raise an alert
> from the monitoring tool...even if all the connections are being used, it
> should be release after the processing done right ? Is there any chance of
> the connections not being released and going back to the pool ? Please
> provide your comments..
>
> Thanks
> Mahesh
>


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org