SSIS package fails and then runs successfully 15 minutes later - sql

I have an SSIS package that is scheduled to run every weekday morning at 8:15. It copies data to and from Active Directory and SQL. About two weeks ago, it started failing, with no changes having been made to the server (beyond MS updates).
The funny thing is that if I then immediately run the package again, it succeeds. Here is the error text from when it fails:
Date 7/14/2011 8:15:00 AM
Log Job History (Reference: Active Directory)
Step ID 1
Server MMCI-GD1SQL2
Job Name Reference: Active Directory
Step Name Run Package
Duration 00:00:32
Sql Severity 0
Sql Message ID 0
Operator Emailed
Operator Net sent
Operator Paged
Retries Attempted 0
Message
Executed as user: MMCI\service-sql. Microsoft (R) SQL Server Execute Package Utility Version 10.0.1600.22 for 32-bit Copyright (C) Microsoft Corp 1984-2005. All rights reserved.
Started: 8:15:00 AM Error: 2011-07-14 08:15:31.88
Code: 0xC0047062
Source: Synchronize Permissions Active Directory Permissions [133]
Description: System.DirectoryServices.AccountManagement.PrincipalOperationException: There is no such object on the server. ---> System.DirectoryServices.DirectoryServicesCOMException (0x80072030): There is no such object on the server.
at System.DirectoryServices.DirectoryEntry.Bind(Boolean throwIfFail)
at System.DirectoryServices.DirectoryEntry.Bind()
at System.DirectoryServices.DirectoryEntry.RefreshCache()
at System.DirectoryServices.AccountManagement.ADStoreCtx.LoadDirectoryEntryAttributes(DirectoryEntry de)
--- End of inner exception stack trace ---
at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.HandleUserException(Exception e)
at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.PrimeOutput(Int32 outputs, Int32[] outputIDs, PipelineBuffer[] buffers)
at Microsoft.SqlServer.Dts.Pipeline.ManagedComponentHost.HostPrimeOutput(IDTSManagedComponentWrapper100 wrapper, Int32 outputs, Int32[] outputIDs, IDTSBuffer100[] buffers, IntPtr ppBufferWirePacket) End Error Error: 2011-07-14 08:15:31.90
Code: 0xC0047038
Source: Synchronize Permissions SSIS.Pipeline
Description: SSIS Error Code DTS_E_PRIMEOUTPUTFAILED. The PrimeOutput method on component "Active Directory Permissions" (133) returned error code 0x80131501. The component returned a failure code when the pipeline engine called PrimeOutput(). The meaning of the failure code is defined by the component, but the error is fatal and the pipeline stopped executing. There may be error messages posted before this with more information about the failure. End Error DTExec: The package execution returned DTSER_FAILURE (1). Started: 8:15:00 AM Finished: 8:15:31 AM Elapsed: 31.343 seconds. The package execution failed. The step failed.
Any thoughts?

Has some new Group Policy been applied that changed the permissions for the account your automated run uses, but which doesn't apply to your user id? I'm assuming when you say "I then ... run the package", you mean your logged-in user id.

Based on the error message that you had provided, the issue seems to be that the task within your package is trying to query an object in Active Directory that might no longer exist.
System.DirectoryServices.AccountManagement.PrincipalOperationException:
There is no such object on the server. --->
System.DirectoryServices.DirectoryServicesCOMException (0x80072030):
There is no such object on the server.
I could be wrong on the below part. I am just speculating what your package might be doing based on the description provided.
Since your package synchronizes data between SQL Server and Active Directory, I assume that the task named Synchronize Permissions Active Directory Permissions selects some form of data stored in SQL Server and updates the content in Active Directory or vice versa. If my assumption is correct, this task is probably Script Task or Script Component. I believe that the code inside this component is failing to select an object (group/user) in Active Directory.
I would check whether a group/user was deleted in Active Directory on the days prior to when the package failed to run.
Hope this helps.

Related

SQL Server Backup Jobs Failing. The error seems to be related to MaximumErrorCount, but I am not sure how to fix value or if changing it will resolve?

My Backup jobs are failing with following error when check it's history. I have already checked this link regarding maximumerrorcount value.
https://stackoverflow.com/questions/3250648/sql-server-2008-change-the-maximumerrorcount-or-fix-the-errors
At this point I'm not sure what to do if maximumerrorcount is only masking the actual problem.
Log Job History (DB_TaxExemption_BKP.Subplan_1)
Step ID 1 Server INHOUSE-DB Job Name DB_TaxExemption_BKP.Subplan_1
Step Name Subplan_1 Duration 00:00:00 Sql Severity 0 Sql Message
ID 0 Operator Emailed Operator Net sent Operator Paged Retries
Attempted 0 Message Executed as user: NT AUTHORITY\LOCAL SERVICE.
Microsoft (R) SQL Server Execute Package Utility Version
14.0.1000.169 for 64-bit Copyright (C) 2017 Microsoft. All rights reserved. Started: 10:12:00 PM Error: 2022-03-30 22:12:00.47
Code: 0xC00291EC Source: {4D6AAF94-D3FC-4873-9F66-E35E323A6BEE}
Execute SQL Task Description: Failed to acquire connection "Local
server connection". Connection may not be configured correctly or you
may not have the right permissions on this connection. End Error
Warning: 2022-03-30 22:12:00.47 Code: 0x80019002 Source:
OnPreExecute Description: SSIS Warning Code
DTS_W_MAXIMUMERRORCOUNTREACHED. The Execution method succeeded, but
the number of errors raised (1) reached the maximum allowed (1);
resulting in failure. This occurs when the number of errors reaches
the number specified in MaximumErrorCount. Change the
MaximumErrorCount or fix the errors. End Warning Error: 2022-03-30
22:12:00.48 Code: 0xC0024104 Source: Back Up Database (Full)
Description: The Execute method on the task returned error code
0x80131904 (Login failed for user 'backupuser'.). The Execute method
must succeed, and indicate the result using an "out" parameter. End
Error ## Heading ##Error: 2022-03-30 22:12:00.48 Code: 0xC0024104
Source: {XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX} Description: The
Execute method on the task returned error code 0x80131904 (Login
failed for user 'backupuser'.). The Execute method must succeed, and
indicate the result using an "out" parameter. End Error Warning:
2022-03-30 22:12:00.48 Code: 0x80019002 Source: OnPostExecute
Description: SSIS Warning Code DTS_W_MAXIMUMERRORCOUNTREACHED. The
Execution method succeeded, but the number of errors raised (2)
reached the maximum allowed (1); resulting in failure. This occurs
when the number of errors reaches the number specified in
MaximumErrorCount. Change the MaximumErrorCount or fix the errors.
End Warning DTExec: The package execution returned DTSER_FAILURE (1).
Started: 10:12:00 PM Finished: 10:12:00 PM Elapsed: 0.219 seconds.
The package execution failed. The step failed
I know for sure that the user for this backup job is sysadmin and it is not locked out all rights are grated. And this is production so I cannot take many risks. What am I missing ?

Copy data activity fails when sink is immutable

In my Azure data factory pipeline, I'm using a Copy data activity inside a ForEach activity to copy files from an input container to an archive container before processing the files in the input container. This normally works, but today I made the archive container immutable by adding a legal hold policy to it, and the next time the copy data activity ran, it failed with an error (see below). Is there any way around this, since you should be able to add new files to an immutable container?
Error code: 2200
Failure type: User configuration issue
Details:
Failure happened on 'Sink' side. ErrorCode=AdlsGen2OperationFailed,'Type=Microsoft.DataTransfer.Common.Shared.HybridDeliveryException,Message=ADLS Gen2 operation failed for: Operation returned an invalid status code 'Conflict'. Account: 'mydatalake'. FileSystem: 'raw'. Path: 'Source/ABC/File_2021_03_24.csv'. ErrorCode: 'PathImmutableDueToLegalHold'. Message: 'This operation is not permitted as the path is immutable due to one or more legal holds.'. RequestId: '37f75e88-501a-0026-2fa1-20d52e000000'. TimeStamp: 'Wed, 24 Mar 2021 11:30:54 GMT'..,Source=Microsoft.DataTransfer.ClientLibrary,''Type=Microsoft.Azure.Storage.Data.Models.ErrorSchemaException,Message=Operation returned an invalid status code 'Conflict',Source=Microsoft.DataTransfer.ClientLibrary,'
Source: Pipeline LoadMyData

How to Clear SSIS Warning Code DTS_W_MAXIMUMERRORCOUNTREACHED?

I got this error message after running my SSIS package.
Source : flat text file
Target : sql database
Warning: 0x80019002 at Package: SSIS Warning Code DTS_W_MAXIMUMERRORCOUNTREACHED. The Execution method succeeded, but the number of errors raised (3) reached the maximum allowed (1); resulting in failure. This occurs when the number of errors reaches the number specified in MaximumErrorCount. Change the MaximumErrorCount or fix the errors.
SSIS package "........\Package.dtsx" finished: Failure.
The program '[7312] DtsDebugHost.exe: DTS' has exited with code 0 (0x0).
Below is my simple source file
CAS, SubName, ListCode, Type, CountryCode, ListName
^1000413-72-8^,^fasiglifam^,^447^,^Chemical Inventory^,^EU^,^ECICS Custom Tariff Codes^
^1000413-72-8^,^fasiglifam^,^0^,^^,^NN^,^SPHERA Global Substance List^
Below SSIS flow task failing in source. Target is SQL database.
Please help me on this .
In case of error means some issue is there and you need to fix it. But, still if you want to set the number to higher value, you can set at the package level.

SSIS CSV Import Error 0xC0202092 DTS_E_PRIMEOUTPUTFAILED

All of the sudden, a CSV file that is imported into a db/table every morning is failing every time within the last few weeks. I do not support this process directly, so I don't know much about SSIS, but would greatly appreciate some help as I need this working and whoever supports this process has no idea what the issue is. I'm not sure if that error regarding the row has anything to do with the data in the row because it looks fine to me. The CSV includes Active Directory information for every computer in AD and is exported from PowerShell to a server where the CSV is imported into a table via SSIS. The process is entirely automated and nothing has changed.
[Source - Clean_Gold CSV [1]] Error: The column delimiter for column "LastLogontimestamp" was not found.
[Source - Clean_Gold CSV [1]] Error: An error occurred while processing file "H:\Computers\clean_gold.csv" on data row 40377.
[SSIS.Pipeline] Error: SSIS Error Code DTS_E_PRIMEOUTPUTFAILED. The PrimeOutput method on component "Source - Clean_Gold CSV" (1) returned error code 0xC0202092. The component returned a failure code when the pipeline engine called PrimeOutput(). The meaning of the failure code is defined by the component, but the error is fatal and the pipeline stopped executing. There may be error messages posted before this with more information about the failure.
I looked at 40,378 and saw someone put a ", in the description of the computer object in Active Directory. That caused an issue with the delimiting.

I can execute SSIS on visual studio, but it doesn't in a job of SQL Server 2008

I have a simple SSIS package that I made in visual studio, it takes data from an Access data base and pass it to an SQL database. I can execute the package without any problems in Visual Studio 2008 but when I try to implement and execute it on a job in SQL Server 2008 it fails, I get this error message as output:
Executed as user: SRV06 \ SYSTEM . Execute Package Utility for Microsoft (R ) SQL Server Version 10.0.1600.22 for 32 -bit Copyright ( C ) Microsoft Corp 1984-2005 . All rights reserved . Started: 12:41:02 PM Error: 2014-05-30 12:41:02.59 Code: 0xC0202009 Source : Fill Complaints Connection Management " IndicadoresQuejas " Description: SSIS Error Code DTS_E_OLEDBERROR . OLE DB error . Error Code: 0x80040E4D . There is an OLE DB record is available . Source : " Microsoft SQL Server Native Client 10.0 " Result : 0x80040E4D Description: " Login failed for user ' sa' . " . End Error Error: 2014-05-30 12:41:02.59 Code: 0xC020801C Origin: SSIS Error Code DTS_E_CANNOTACQUIRECONNECTIONFROMCONNECTIONMANAGER : Data Flow OLE DB Destination [525 ] Description Task . Error of the method call AcquireConnection administrator " IndicadoresQuejas " connection . Error Code: 0xC0202009 . There may be other exposed Error messages before this with more information on why the error AcquireConnection method. End Error Error: 2014-05-30 12:41:02.59 Code: 0xC0047017 Source : Data Flow Task SSIS.Pipeline Description : Error in validating component " OLE DB Destination " ( 525 ); 0xC020801C error code was returned. End Error Error: 2014-05-30 12:41:02.59 Code: 0xC004700C Source : Data Flow Task SSIS.Pipeline Description: Failed to validate one or more components. End Error Error: 2014-05-30 12:41:02.59 Code: 0xC0024107 Source : Data Flow Task Description : There were errors during task validation . End DTExec error : package execution returned DTSER_FAILURE ( 1). Started: 12:41:02 AM Finished : 12:41:02 PM Elapsed: 0.281 seconds . Package execution failed . Unable to perform the step.
I know that it's in spanish but I hope this won't be a problem. I'll give some details about the package and the job.
In the package the "IndicadoresQuejas" is a data source that connects to the SQL Server data base, to enter this data base I've already typed and saved the user and pasword inside the package.
There's another data source clled "Quejas" that gets the data from the Acces data base, this one doesn't need user and password.
There's an OLDB connection named SRVXX\BI2008.IndicadoresQuejas.sa
The SSIS package has Prtection Level of EncryptSensitiveWithPassword
About the Job, it has jusy one step called "Llenar Quejas" this one executes the SSIS package but as I mentioned it fails. I've alredy enter the job properties and edited the job's step, it has the type of "SQL Package Server Integration Services", the "execute as" is "Service Account of SQL Server Agent" the package origin is "system file", In execution options everything is unchecked, the SQL Server 2008 is 32 bits as well as Visual Studio. The command line is:
/FILE "F:\Proyectos\Indicadores Quejas\SSIS Quejas\Llenar Quejas.dtsx" /DECRYPT /CONNECTION IndicadoresQuejas;"\"Data Source=SRVXX\BI2008;User ID=sa;Initial Catalog=IndicadoresQuejas;Provider=SQLNCLI10.1;Persist Security Info=True;\"" /CONNECTION Quejas;"\"Dsn=Quejas;\"" /CONNECTION "SRVXX\BI2008.IndicadoresQuejas.sa";"\"Data Source=SRV06\BI2008;User ID=sa;Initial Catalog=IndicadoresQuejas;Provider=SQLNCLI10.1;Persist Security Info=True;Auto Translate=False;Application Name=SSIS-Package-{B52933E5-68A2-4A0E-8A60-8F905810CF31}SRVXX\BI2008.IndicadoresQuejas.sa;\"" /CHECKPOINTING OFF /REPORTING E
In the data sources the data sources of the package (Quejas, and Indicadores Quejas) and the OLDB connection(SRVXX\BI2008.IndicadoresQuejas.sa) are checked.
I've searched on the internet about this problem, but nothing has helped me, and I've visited the Microsoft support page as well but nothing.
I know that the problem is that it's not connecting to "IndicadoresQuejas" correctly, and I've checked several times that the users and passwords are correct. But I really don't know what's wrong. I've also checked the ODBCs and everything looks fine.
I've also tried to import the package to the MSDB folder of the Integration Services in SQL server but I've been told that from all the other jobs that had been done, importing packages to that folder has never been necessary.
I don't really expect to get the actual solution here, but if you could give me at least a clue of what I should be checking or reviewing.
I hope that the Spanish messages and names will not be a problem. If more details are needed I'll provide them. Thanks