Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

SSIS Executing SPs Failed - Deadlock

Posted on 2013-01-03
7
Medium Priority
?
1,556 Views
Last Modified: 2016-02-10
I have a SSIS Package which executes few SProcs (on SQL server 2008) , updates a table and exports data in a csv which is FTP'ed.

I have able to successfully execute the package in TEST environment (Hosted on a diff server).

However when I try to execute this package on production , I encounter below error. Any idea what could be causing this? (I have attached the code which calls the SPs from SSIS)

[Execute SQL Task] Error: Executing the query "declare @dt as datetime2
set @dt = SYSDATETIME()
..." failed with the following error: "Transaction (Process ID 94) was deadlocked on lock | communication buffer resources with another process and has been chosen as the deadlock victim. Rerun the transaction.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly.


declare @dt as datetime2

set @dt = SYSDATETIME()

EXECUTE [SP_0_TEMP_DELETE] 
EXECUTE [SP_1_TEMP_APPEND] 
EXECUTE [SP_2_TEMP_APPEND_EXPIRED_RENEWALS] 
EXECUTE [SP_3_UPDATE] @dt
EXECUTE [SP_4_UPDATE_EXPIRED_RENEWALS] @dt
EXECUTE [SP_5_APPEND] @dt

Open in new window

0
Comment
Question by:cynx
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
7 Comments
 
LVL 15

Expert Comment

by:Anuj
ID: 38740474
Make sure your tables used in SPS are properly indexed so the queries completes quickly.
0
 
LVL 1

Author Comment

by:cynx
ID: 38740651
Hi, yes they are.
I have executed this SSIS in test several times, which is exact copy of production; and it never failed before...
0
 
LVL 15

Accepted Solution

by:
Anuj earned 1000 total points
ID: 38740658
can you post the dead lock graph along with the execution plans?
0
Moving data to the cloud? Find out if you’re ready

Before moving to the cloud, it is important to carefully define your db needs, plan for the migration & understand prod. environment. This wp explains how to define what you need from a cloud provider, plan for the migration & what putting a cloud solution into practice entails.

 
LVL 1

Author Comment

by:cynx
ID: 38743156
I have asked my DB Admin to Enable the trace with Deadlock event. I will share the plan and graph tomorrow. Thanks!
0
 
LVL 21

Assisted Solution

by:Alpesh Patel
Alpesh Patel earned 1000 total points
ID: 38743631
In Production some process using the same resource for long time and the SSIS package going to use that.


Some of locking in there that violate the condition and deadlock occurs.
0
 
LVL 1

Author Comment

by:cynx
ID: 38743725
thanks, how to find which process is that ? Can I get this info with help of a script ?
0
 
LVL 1

Author Comment

by:cynx
ID: 39006128
Thanks folks. Sorry for delay in assigning points. It was indeed a deadlock issue which was resolved by DB Team.
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A couple of weeks ago, my client requested me to implement a SSIS package that allows them to download their files from a FTP server and archives them. Microsoft SSIS is the powerful tool which allows us to proceed multiple files at same time even w…
I have a large data set and a SSIS package. How can I load this file in multi threading?
Familiarize people with the process of utilizing SQL Server functions from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Ac…
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question