Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Coldfusion 9 MySQL communications link failure

Participant ,
Jan 04, 2011 Jan 04, 2011

've just installed Coldfusion 9, and everything is now working fine and it's connected to my MySQL databse via the Coldfusion Administrator as a datasrouce, but I get this error occuring infrequently, maybe 5 - 10 times a day. I don't know how to recreate it, and if you get it and refresh the page it goes away.

Error Executing Database Query. Communications link failure Last packet sent to the server was 0 ms ago

The error is being caught by coldfusion as it's displaying a user friendly message and emailing me the problem.

Almost all of the time the pages load and work fine, and this problem has only happened since going from CFMX7 to CF9, both using MySQL.

The MySQL version I am using is "5.0.77"

I've tried localhost and 127.0.0.1 as the host in the datasource, it makes no difference.

Does anyone have any idea what this is and how to fix it? I've seen some similar posts for Java but I don't see how to translate the fix across into Coldfusion?

And could it be a MySQL or Apache problem anyway?

24.6K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Engaged , Jan 12, 2011 Jan 12, 2011

The Maintain Connections setting means that after a db connection is created

for a given database, that connection will be used for the current query and

then kept open in a connection pool so that they can be reused for later

queries. The reason is that opening a connection is an expensive, time

consuming operation, and its more efficient to only have to authenticate

once. When this setting is disabled, for every page request accessing a

given database, a new database connection will be created, the

...
Translate
Community Expert ,
Nov 28, 2012 Nov 28, 2012
LATEST

mowebdev2 wrote:

I appreciate any clarifications.

Then start your own thread!

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jan 08, 2011 Jan 08, 2011

The fact that it occurs intermittently makes me think it could be caused by a middle-man application -- firewall, proxy, antivirus, that sort of thing.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Jan 12, 2011 Jan 12, 2011

Right, I've not had the errors occuring for 2 days now,

the day before last I had "Maintain Connections" UNchecked,

yesterday I had "Maintain Connections" checked and was using a validation query.

Thank you both for your help and advice, I am now much more knowledgeable when it comes to Coldfusion Datasources.

The problem is obviously still there in the background, and this is just a work around using the validation query, I will continue to apply MySQL and Coldfusion 9 updates and run another datasource without the validation query to see if the problem stops occuring with future updates.

However as the error is so infrequent, I agree with Steven that it's a suitable workaround, especially as I've got other work to do and the front end user is none the wiser.

I will also investigate further with the error logs and see if I can find out any more information, but I'm not promising any speedy updates on the matter.

As a final point, I've got this question on StackOverflow.com and I'll have to mark the question as answered by myself and refer to this post here, unless either of you want to respond to the post so I can give you the credit you're due.

http://stackoverflow.com/questions/4500414/coldfusion-9-mysql-communications-link-failure

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jan 13, 2011 Jan 13, 2011

PeteComcar,

You get no more communication failure. You have Maintain Connections going, too! What more could you want? Hats off to Steven!

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Apr 11, 2011 Apr 11, 2011

I've read through this and made changes based on these posts, but still have a few questions relating to a DSN 'failure'

http://forums.adobe.com/thread/836689

Thanks so muc if you can help explain/resolve!

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Valorous Hero ,
Apr 11, 2011 Apr 11, 2011

Beards247 wrote:


but still have a few questions relating to a DSN 'failure'

I'm sorry the Psychic Hot Line forum is the next one over.

I'm affraid we can not read your mind here.  You will need to actually ASK any questions you would like help with explaining.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Apr 11, 2011 Apr 11, 2011

Thanks for getting back isaac. From the other post -

The full error Error Executing Database Query.  [Macromedia][SQLServer JDBC Driver][SQLServer]Invalid object name  'LittleBobbyTables'. (table name withheld)

It fails intermittently - there is 1 table and 1 view that occassionally get this error. At first I suspected a network DNS issue, but it doesn't seem to be  the case since test CF Data Source Names to server name,  Server alias,  and IP address DSN all work.

We are able to stop the error by changing the Data Source Name from server to the alias name or vice versa.  So the process:

ColdFusion error - cannot find tables that do exist. Go into admin:

  • Change CF DSN from actual server name to DNS alias, submit or vice versa and submit

Trying to figure out why this resolves the problem? b/c the connection pool is refreshed? Bigger Q - how do we troubleshoot the actual failure?

FWIW, I've increased the connection pool, decreased the time out and decreased the check time.

Thanks in advance,

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources