Skip to main content
October 1, 2007
Answered

Deadlock in Coldfusion 8

  • October 1, 2007
  • 4 replies
  • 2197 views
We had a server with ColdFusion 6 and SQL server 2000. There was a scheduled task in ColdFusion server that ran every morning that updated one of the databases in SQL server.

2 weeks ago, we replaced the server (the machine) with a new one. In this process, we upgraded Coldfusion to 8, but did not change the version of SQL server. It is still 2000. I made sure that all the settings in CF8 is the same as it was in CF6. Nothing in the scheduled process has been changed either.

Ever since we made the switch-over, the cfm file of the scheduled task in ColdFusion server does not run the queries all the way through, and I see this error in the application log:

"Error Executing Database Query.[Macromedia][SQLServer JDBC Driver][SQLServer]Transaction (Process ID 54) was deadlocked on lock resources with another process and has been chosen as the deadlock victim. Rerun the transaction."

I understand why a process is deadlocked in SQL server but I don't know what might be different between CF8 and CF6 that is now causing this problem. Any help will be greatly appreciated.

Thanks
Firoozeh Hunt
This topic has been closed for replies.
Correct answer Newsgroup_User
When I manually run the scheduled task in ColdFusion, the process runs
without any deadlock, but when it runs at the scheduled time which is
7:00 am (when no one else is logged in), it runs into the deadlock issue.

It is the database that is throwing the deadlock. Any logs on the
database that can show where the multiple requests are coming in from?
Is the update occuring despite the deadlock? Is there a possibility
that somehow the task was duplicated so that it is being run twice at
7:00am either on the new server so in some combination with other servers?

4 replies

Inspiring
October 4, 2007
Ian,
You are absolutely right about the process running on the other server.
The old server has not been turned off yet, and your comment just made
me realize that they are both running the process from the same URL.

Thank you so much for your help.
Firoozeh

Well that would do it! It's nice when it's ultimately an easy fix isn't it?



October 4, 2007
Ian,
You are absolutely right about the process running on the other server. The old server has not been turned off yet, and your comment just made me realize that they are both running the process from the same URL.

Thank you so much for your help.
Firoozeh
Newsgroup_UserCorrect answer
Inspiring
October 3, 2007
When I manually run the scheduled task in ColdFusion, the process runs
without any deadlock, but when it runs at the scheduled time which is
7:00 am (when no one else is logged in), it runs into the deadlock issue.

It is the database that is throwing the deadlock. Any logs on the
database that can show where the multiple requests are coming in from?
Is the update occuring despite the deadlock? Is there a possibility
that somehow the task was duplicated so that it is being run twice at
7:00am either on the new server so in some combination with other servers?

October 3, 2007
More information about this issue:

When I manually run the scheduled task in ColdFusion, the process runs without any deadlock, but when it runs at the scheduled time which is 7:00 am (when no one else is logged in), it runs into the deadlock issue.