ColdFusion hangs or slow when several datasources are not found

76 views
Skip to first unread message

hofar...@houseoffusion.com

unread,
Aug 19, 2014, 11:48:25 PM8/19/14
to ColdFusion Technical Talk

Hi All,

We recently encountered a problem on our Coldfusion 7 server in which it seems to hang or the page loading is very slow when several datasources were not found due to network problem.

The Coldfusion server has many datasources that are found on 3 different database servers. One of the database servers' network connection had a problem and it caused the coldfusion to run very slow and thus affecting all sites even though the datasource of those sites are found. One site only access one datasource.

We are using Windows 2003 Server, Coldfusion 7, and IIS6.

Has anybody encountered and solved this problem?

Thanks,

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:359162

hofar...@houseoffusion.com

unread,
Aug 20, 2014, 12:32:29 AM8/20/14
to ColdFusion Technical Talk

Check your DSN settings, and set the login timeout to something reasonable
like 5 seconds. The default is 30 seconds. You may have to tweak this a
bit based on the time it takes to actually authenticate to your DB servers.
All our DBs are local to the network and I've never had issue with a 5
second timeout.

Also ensure you DSN have "maintain database connection" checked. This is a
performance tweak in general. This forces CF to reuse the connection and
reduces the overhead running a query.

What is happening is CF is still attempting to connect to the DB server as
needed. Each thread doing so, will wait until the login timeout is met
before terminating.

CF has a finite number of threads, which is outlined in the CFAdmin. The
threads are getting used up by the waiting DB requests, once this reaches
the maximum number of threads, additional requests are queued and you will
begin to see slowness. Something like a cascade effect.

The 5 seconds won't solve the issue all around. It just releases those
threads faster. Depending on the number of queries attempting to run on the
failed DB server. You may still see slowness.


~Byron Mann
Lead Engineer & Architect
HostMySite


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:359163

hofar...@houseoffusion.com

unread,
Aug 20, 2014, 2:55:13 AM8/20/14
to ColdFusion Technical Talk

Hi Bryan,

I will do as you suggested. Thanks a lot!

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:359164

hofar...@houseoffusion.com

unread,
Aug 20, 2014, 2:57:43 AM8/20/14
to ColdFusion Technical Talk

Oh! I am so sorry I misspelled your name. Thanks again for the solution Byron! :)

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:359165
Reply all
Reply to author
Forward
0 new messages