Problem With Process Exit Code (Cmdexec)

Mar 25, 2003

Can someone tell me how i can generate an exit code (Cmdexec). Ive tried running an .exe file in a job but when i do that the job hangs. When i check the history it says the exit code is somewhere in 27000. Now i'm wondering if it is possible for me to generate an exit code if the executable closes.
PS. When i run the file from a batch file it works great

View 1 Replies


ADVERTISEMENT

[Execute Process Task] Error:The Process Exit Code Was -1 While The Expected Was 0.

Mar 11, 2008

Dear list
Im designing a package that uses Microsofts preplog.exe to prepare web log files to be imported into SQL Server

What Im trying to do is convert this cmd that works into an execute process task
D:SSIS ProcessPrepweblogProcessLoad>preplog ex.log > out.log
the above dos cmd works 100%



However when I use the Execute Process Task I get this error
[Execute Process Task] Error: In Executing "D:SSIS ProcessPrepweblogProcessLoadpreplog.exe" "" at "D:SSIS ProcessPrepweblogProcessLoad", The process exit code was "-1" while the expected was "0".

There are two package varaibles
User::gsPreplogInput = ex.log
User::gsPreplogOutput = out.log

Here are the task properties
RequireFullFileName = True
Executable = D:SSIS ProcessPrepweblogProcessLoadpreplog.exe
Arguments =
WorkingDirectory = D:SSIS ProcessPrepweblogProcessLoad
StandardInputVariable = User::gsPreplogInput
StandardOutputVariable = User::gsPreplogOutput
StandardErrorVariable =
FailTaskIfReturnCodeIsNotSuccessValue = True
SuccessValue = 0
TimeOut = 0

thanks in advance
Dave

View 1 Replies View Related

Execute Process Task Error - The Process Exit Code Was 1 While The Expected Was 0.

Jan 30, 2007

How do I use the execute process task? I am trying to unzip the file using the freeware PZUnzip.exe and I tried to place the entire command in a batch file and specified the working directory as the location of the batch file, but the task fails with the error:

SSIS package "IngramWeeklyPOS.dtsx" starting.

Error: 0xC0029151 at Unzip download file, Execute Process Task: In Executing "C:ETLPOSDataIngramWeeklyUnzip.bat" "" at "C:ETLPOSDataIngramWeekly", The process exit code was "1" while the expected was "0".

Task failed: Unzip download file

SSIS package "IngramWeeklyPOS.dtsx" finished: Success.

Then I tried to specify the exe directly in the Executable property and the agruments as the location of the zip file and the directory to unzip the files in, but this time it fails with the following message:

SSIS package "IngramWeeklyPOS.dtsx" starting.

Error: 0xC002F304 at Unzip download file, Execute Process Task: An error occurred with the following error message: "%1 is not a valid Win32 application".

Task failed: Unzip download file

SSIS package "IngramWeeklyPOS.dtsx" finished: Success.

The command in the batch file when run from the command line works perfectly and unzips the file, so there is absolutely no problem with the command, I believe it is just the set up of the variables on the execute process task editor under Process. Any input on resolving this will be much appreciated.

Thanks,

Monisha

View 1 Replies View Related

Execute Process Task - Error :The Process Exit Code Was 2 While The Expected Was 0.

Mar 20, 2008



I am designing a utility which will keep two similar databases in sync. In other words, copying the new data from db1 to db2 and updating the old data from db1 to db2.

For this I am making use of the 'Tablediff' utility which when provided with server name, database, table info will generate .sql file which can be used to keep the target table in sync with the source table.

I am using the Execute Process Task and the process parameters I am providing are:



WorkingDirectory : C:Program Files (x86)Microsoft SQL Server90COM
Executable : C:SQL_bat_FilesSQL5TC_CTIcustomer.bat

The customer.bat file will have the following code:
tablediff -sourceserver "LV-SQL5" -sourcedatabase "TC_CTI" -sourcetable "CUSTOMER_1" -destinationserver "LV-SQL2" -destinationdatabase "TC_CTI" -destinationtable "CUSTOMER" -f "c:SQL_bat_Filessql5TC_CTIsql_filescustomer1"

the .sql file will be generated at: C:SQL_bat_Filessql5TC_CTIsql_filescustomer1.

The Problem:
The Execute Process Task is working fine, ie., the tables are being compared correctly and the .SQL file is being generated as desired. But the task as such is reporting faliure with the following error :

[Execute Process Task] Error: In Executing "C:SQL_bat_FilesSQL5TC_CTIpackage_occurrence.bat" "" at "C:Program Files (x86)Microsoft SQL Server90COM", The process exit code was "2" while the expected was "0". ]

Some of you may suggest to just set the ForceExecutionResult = Success (infact this is what I am doing now just to get the program working), but, this is not what I desire.

Can anyone help ?




View 9 Replies View Related

The Process Exit Code Was 128

Apr 1, 2008

Folks,
I have a SSIS package that works 3 out of 4 times but it does fail occasionally with the following error.

The return value was unknown. The process exit code was 128. The step failed.
I have logging enabled ..but mysteriously the log has no information on the failure..

Any thoughts ?

thanks

View 6 Replies View Related

The Process Exit Code Was 128.

Mar 20, 2008

Hi,

I am running a Sql Server 2005 job and this job is having 25 steps. Each step is calling the .dtsx packae from D: drive location. While running the job i found this error

"The return value was unknown. The process exit code was 128. The step failed."


This error occurs not for any perticular step. It occurs randomally at any step.

I am running this job on
1. Windows 2003 server with SP2
2. Sql Server 2005 (Developer Edition) with SP2

Can any one please help me out resolving this issue.

Amit

View 2 Replies View Related

Process Exit Code:1073741819

Jul 13, 2006

   I have changed a SSIS package last week. Now, I met the problem that the package sometimes failed both in SQL agent and the BIDs.

  SQL agent  just give the detail: Process Exit Code -1073741819. The step failed.


   In BIDs,when I Check the log,there is even no error. But the last Infomation in the output windows is the package canceled. It just like somebody stop running package manually.

   The more strange thing is the package sometimes succeed with running the same data.

 

     Thanks for your help

 

View 18 Replies View Related

The Process Exit Code Was -1073741510

May 9, 2007

I did a few searches and found nothing. Any ideas what this error means?

View 2 Replies View Related

Process Exit Code Of Successful Command

Jul 5, 2000

I wish to have a batch file exit with a return code of 3 if it fails.
In the batch file I have the single command: Exit 3
On SQL Server the Process Exit Code of a successful command is set to 0.

Yet, when I run the job SQL Server says that it is successful.

View 1 Replies View Related

SQLAgent Job Failed. Process Exit Code Was -10737418

Apr 20, 2007

My overnight production job has been running for months. Duration is typically 40 minutes.

Last night it started and without doing anything, it stopped. There was nothing in the SSIS log.

SQLAgent task log reported

The return value was unknown. The process exit code was -10737418.



Usually, I can find something on Google when I enter the error code; not today.



Any ideas?

All suggestions welcomed.



IanO

View 7 Replies View Related

Execute Process Task: Unexpected Exit Code

Jul 5, 2006

In Executing "E:EmailDelivery.exe" "EP12A 4" at "", The process exit code was "-532459699" while the expected was "0". 

View 4 Replies View Related

SSIS - Process Task Exit Code 4 - Via SQL Agent Scheduled Job Only - Works If Manually Started....

Oct 10, 2007

We have a Process Task component setup in a couple SSIS jobs to call a command batch file to support transfering a file via Secure FTP to other servers and the process works fine if we start the SQL Agent job manually, however when the job is started via the scheduler, it fails with an exit code of 4. Even though there is a proxy setup on the agent job, is there a different user account being invoked by the scheduler??? We're on 2005 SP1 Hotfix 1 (2153). Thanks

Some more info...have found that if we leave a login session open on the server (login is the proxy account) the process works. It appears the issue is associated with a need to render/create a command window for the command line/batch process to run in and without an active windows session it fails....would seem to be that a product setup to run on a server in a batch mode would be able to work without this...is this the case? if so, how? Thanks.

View 11 Replies View Related

Execute Process Task How To Exit The Executable Program

Jan 21, 2008

Hello everybody,

Could anybody tell me how can I stop the executable program which I am using in Arguments field of Execute Process Task Editor window. My SSIS process based on three steps.

1. retrieve the file from FTP location
2. Process the file by using windows 32bit application
3. transfer the processed file back to FTP location

The problem occurs in step 2, it opens the win32 application for processing and it does process BUT after that it won't exit untill I close it manually, so it never reaches to step 3 if I don't close it.

Thanks in advance.
Zee.



View 2 Replies View Related

Sqlservr.exe Exit Code Of 259 (0x103) - What Does It Mean?

Mar 20, 2007

Can someone please explain what exit code 259 means as it appears in the debug output below?

When running a C# Stored Procedure within the VS 2005 IDE I receive the following Debug Output:

Auto-attach to process '[1152] [SQL] enterprise' on machine 'enterprise' succeeded.

Debugging script from project script file.

The thread 'enterprisesqlexpress [56]' (0x150) has exited with code 0 (0x0).

The thread 'enterprisesqlexpress [56]' (0x1314) has exited with code 0 (0x0).

The thread 'enterprisesqlexpress [56]' (0x1314) has exited with code 0 (0x0).

'sqlservr.exe' (Managed): Loaded 'C:WINDOWSassemblyGAC_32mscorlib2.0.0.0__b77a5c561934e089mscorlib.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.

'sqlservr.exe' (Managed): Loaded 'c:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLBinnSqlAccess.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.

'sqlservr.exe' (Managed): Loaded 'C:WINDOWSassemblyGAC_32System.Data2.0.0.0__b77a5c561934e089System.Data.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.

'sqlservr.exe' (Managed): Loaded 'C:WINDOWSassemblyGAC_MSILSystem2.0.0.0__b77a5c561934e089System.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.

'sqlservr.exe' (Managed): Loaded 'C:WINDOWSassemblyGAC_32System.Transactions2.0.0.0__b77a5c561934e089System.Transactions.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.

'sqlservr.exe' (Managed): Loaded 'C:WINDOWSassemblyGAC_MSILSystem.Security2.0.0.0__b03f5f7f11d50a3aSystem.Security.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.

Auto-attach to process '[1152] sqlservr.exe' on machine 'enterprise' succeeded.

'sqlservr.exe' (Managed): Loaded 'C:WINDOWSassemblyGAC_MSILSystem.Xml2.0.0.0__b77a5c561934e089System.Xml.dll', Skipped loading symbols. Module is optimized and the debugger option 'Just My Code' is enabled.

'sqlservr.exe' (Managed): Loaded 'SQL2005_Test', No symbols loaded.

'ENTERPRISE;.Net SqlClient Data Provider;4400' (Managed): Loaded 'C:WINDOWSassemblyGAC_MSILSystem.Configuration2.0.0.0__b03f5f7f11d50a3aSystem.Configuration.dll', No symbols loaded.

CurrencyCode Name ModifiedDate

------------ -------------------------------------------------- -----------------------

eee MyCurr4 3/20/2007 12:58:38 PM

(1 row(s) affected)

(1 row(s) returned)

Finished running sp_executesql.

The thread 'enterprisesqlexpress [56]' (0x1314) has exited with code 0 (0x0).

The program '[1152] [SQL] enterprise: enterprisesqlexpress' has exited with code 0 (0x0).

The program '[1152] sqlservr.exe: Managed' has exited with code 259 (0x103).



I would also appreciate hearing back from users as to why I only have two choices in my VS 2005 IDE Output window (Build and Debug). From what I've read, 'Database' should be another choice for 'Show output from:'.



My environment consists of the following:

Database:

Microsoft SQL Server 2005 - 9.00.3042.00 (Intel X86) Feb 9 2007 22:47:07 Copyright (c) 1988-2005 Microsoft Corporation Express Edition on Windows NT 5.1 (Build 2600: Service Pack 2)

I have verified the SQL Server connection has 'Allow SQL/CLR Debugging' enabled.

The Visual Studio 2005 IDE is:

8.0.50727.762 (SP.050727-7600)

Running Microsoft .Net Framework version 2.0.50727

View 4 Replies View Related

Scheduled SSIS/DTS Package Fails Periodically With Exit Code -1073741819

Oct 2, 2007

We have a vendor who has an SSIS package that executes a DTS package. We've asked that they migrate the DTS code completely to SSIS, but that is something that will not be done in the near future. The package is scheduled to run every 5 minutes through a SQL Server scheduled job. 95% of the time the package executes without an error, but occassionally the following error is reported.


Date 10/2/2007 7:35:00 AM
Log Job History (Pyxis - Data Load)

Step ID 1
Server DEVSQL1V5
Job Name Pyxis - Data Load
Step Name Run SSIS Package
Duration 00:00:03
Sql Severity 0
Sql Message ID 0
Operator Emailed
Operator Net sent
Operator Paged
Retries Attempted 0


Message
Executed as user: Domain_NameSQLService. The return value was unknown. The process exit code was -1073741819. The step failed.



When I look at the DTS and SSIS package logs no errors are reported and each log indicates the package completed successfully.

Any ideas what this exit code is indicating or how to further troubleshoot the problem?

Thanks, Dave

View 4 Replies View Related

Incremental Process Based On Action Code

Apr 24, 2007


I will be receiving an incremental file that will contain €œI€? inserts, €œU€? updates, and €œD€? deletes as an action code that I will load into a transform table. If I conditionally split the action code I will lose the fifo order and the data in the transform sequence could be applied out of order causing an error. If I use 3 separate data flows I can apply incremental doing the inserts first, then the updates and then the deletes. I think this would work but I would have to read the transform table three times.

I am looking for some feedback on what is the best most efficient way to handle what I am trying to accomplish?


Thanks
Larry

View 27 Replies View Related

How To Capture The Return Code Of An Execute Process Task

Jan 18, 2008

Can anyone tell me how to capture the return code of a process launched by an Execute Process Task? I am able to capture the output by using the StandardOutputVariable but can't seem to capture the actual code.

View 4 Replies View Related

Execute Process Task - Error/Return Code Listing With Descriptive Messages?

May 28, 2008



I'm having a hard time locating a listing of potential error codes and the meanings for the Execute Process Task component...can someone assist?

Thanks

View 1 Replies View Related

Server Failed With Error Code 0xc0000000 To Spawn A Thread To Process A New Login Or Connection

Mar 6, 2007

Hello All,

Suddenly, the sql server is down, in the log file, C:Program FilesMicrosoft SQL ServerMSSQL.1MSSQLLOGERRORLOG, I found the record as follows,

2007-03-05 15:40:31.59 Logon Error: 17189, Severity: 16, State: 1.
2007-03-05 15:40:31.59 Logon SQL Server failed with error code 0xc0000000 to spawn a thread to process a new login or connection. Check the SQL Server error log and the Windows event logs for information about possible related problems. [CLIENT: 172.21.123.48]

What else I can do to further investigate?

Thanks

Spencer

View 11 Replies View Related

CmdExec Errors!

Oct 1, 2001

I have tried to make a DTS task running a batc-file on the same server as the SQL program is running using the CmdExec command.

My Command is as follows:

CmdExec serverpathatchname.bat

The problem is that everytime the step runs it report the following error:

"The system cannot find the file specified."

In the bat file I am also trying the de-map/map a network drive with another loginname/password than the one used on the SQL-server -> is this i problem?

Hope to hear from you soon, this is a bit urgent!!

Please provide tips to this adresse: qtip@bigfoot.com

View 1 Replies View Related

CmdExec In A Nightly Job

Jul 3, 2007

I have to verify a .CSV file exists before I run a BULK INSERT. I am using XP_FileExist in SQL 2000 to accomplish this. After the Bulk Insert is completed and validated, I need to Rename the file and Move the file to archive the folder. For testing I figure If I can rename the file I can move it. I suspect I have permission issues and need to provide the SQL Server Agent permissions to this folder and file. I have my PC setup as a SQL 2000 Server and am attempting to get this step only working on my local machine. I created a nightly Job that remanes a file that I created in a Job and that is all it does. I am running the Job as SA but am still having issues.



The step being executed by the Job is "Ren C:MyTestFile.csv C:MyTestFile1.csv" (with the quotes). If I run this statment (without the Quotes from a command prompt, the file is renamed.

I have set the Type as "Operating System Command (CmdEXEC)". The Job history shows "The process could not be created for step 2 of job 0x71D51027F920A140A2913234DB7FF509 (reason: The system cannot find the file specified). The step failed."

As I said, I suspect that it is a permissions issue as the command works from the command prompt. What is the windows account that the SQL Server Agent uses to commit these commands? I added "Everyone" with Full access to the folder and I still get the same failure.

I would appreciate any assistance anyone could provide. Thanks in advance!

View 1 Replies View Related

JOBS Using Steps/CmdExec

Feb 4, 2000

Hi All,
In creating 'steps' in JOBS, is it possible to execute many DOS CmdExec in
one step, instead of creating several steps with a single DOS-cmd in each.
For example:

Step1: bcp sourcedb..sourcetbl out source.dat -n -T -Ssourceserver
Step2: isql -T -Stargetserver -Q "truncate table targettbl"
Step3: bcp targetdb..targettbl in source.dat -n -T -Stargetserver

If I created a job executing those 3 functions in 3 separate steps then it works fine. But if I put all those 3 DOS command in one step, it won't work. Somehow,
SQL doesn't 'understand' it should execute after the end of each command OR
I missed something here (apparently so!).
I know if I put all those 3 DOS commands into a DOIT.BAT and execute it, it will work. But I want to use SQL Job to schedule it to run on a regular basis.

Anyone has run into this same problem? Thanks in advance.
David Nguyen.

View 1 Replies View Related

Tasks Using Cmdexec Failing

Feb 2, 1999

WE have a number of SQL 6.5 servers all of which run many scheduled tasks. However on one all tasks which use cmdexec to run batch files fail after 2-3 seconds. The history returns : 'No message' and the error logs just indicate that the tasks have faILED.

The identical tasks run on servers with what appears to be identical configurations and setup.

Tasks scheduled using Tsql run OK !

I would be grateful for any advice or help

Many thanks in advance

Tom

View 1 Replies View Related

Trapping Cmdexec Errors

Nov 11, 1998

I would like to trap a return value from a cmdexec that is scheduled. The cmdexec returns 0 if it is a success and something other than 0 if it doesn't.

Can I raise an error from a command file. The command file calls a console application ( i.e. no interface ).

Any help is appreciated.

View 1 Replies View Related

Cmdexec Job Fails In Sql 2000

Aug 17, 2001

I have a Job that runs a cmdexec job step which executes a batch file in sql server 7.0 that runs fine
In sql 2000 when i try to run that job it gives the following error and fails

----
the process could not be created for step 1 of job 0x677EF599B13FA743AA2D501D4C211AC4 (reason: The system cannot find the file specified). The step failed.
------
In fact i am not able to execute any cmdexec job in sql 2000
The owner of the above job is sa
Does it have to do with SqlAgentCmdExec account which is set to corporate/administrator and has required permission.

Help will be greatly appreciated.

View 1 Replies View Related

CmdExec Job Step In Sql Server2000

Aug 20, 2007

Thanks for the invitation to post a question, so I will post one.

I need to create a job step that uses cmdExec.

This is the command line I entering:
D:odbcTimeClockUpdatesinReleaseTimeKeepingNo nLogouts.exe

When I run this job the job fails. When I look at the job history, the only information I get is the date and time, user that ran the job and the fact that it failed. I haven't been able to get any CmdExec job to run at all. Can anyone tell me what I'm doing wrong?

Facts.
1. This exact same command is used by my network administrator using windows scheduler on the server. The only reason he wants me to create an sql server job is because it's mostly sql functions.
2. I know the Sql Server agent is running, because I have other jobs that are run.
3. I have verified that I have permission to run the file because I can go to the actual directory and run the exe.
4. Do I need to enclose my command in quotes i.e. “D:odbcTimeClockUpdatesinReleaseTimeKeepingN onLogouts.exe”
5. the path of the file I need to run is the path on the server and not the path on my local machine.

If you need any other information, please let me know
Thanks for you help
GEM

View 7 Replies View Related

Dtexec - Can Run In A Job (CmdExec) But Not From Xp_cmshell

Nov 15, 2007



Hi all,

I've working a while, not at full time, but seeking the solution...Here what I want to do and what I've done till now:

I want to build a sql job, so I can run a package (witch loads 2 excel sheets into 2 tables) passing "dynamic" parameters, like convert(varchar,getdate(),112) in the format YYYYMMDD. From what I've found, I can do this with an Stored Procedure, which first set this variable, building a statement so it can be run by xp_cmdshell. For example:

EXEC master.dbo.xp_cmdshell 'DTEXEC /SQ PACKAGE /SET "Package.Variables[DAY].Value";20070101'

And this statement runs with no problem in the SP until it reaches the step of loading the Excel Sheets into tables. Here it gives an error. It's about the JET driver. From what I've read in the forum and from the output error the problem seems to be that this statement executes the dtexec.exe 64bits, even the suggestion to change the property Run64BitRuntime set to False, it stills running from the dtexec.exe 64bits.


So, I changed the statement to point to dtexec.exe 32bits:

EXEC master.dbo.xp_cmdshell 'C:Program Files (x86)Microsoft SQL Server90DTSBinnDTExec.exe /SQ PACKAGE /SET "Package.Variables[DAY].Value";20070101'

But executing this statement it does not even run. The errors are:
'C:Program' is not recognized as an internal or external command
operable program or batch file

This was very wird to me, because this was very mentioned by the moderators.

So, I copy this same statement and created a job with a step type of "Operating System (CmdExec)" and it runs great...With no problem with the extraction from excel source.

Now my questions are:
1. Why the step job CmdExec recognizes the path of dtexec.exe 32bits ('C:Program Files (x86)Microsoft SQL Server90DTSBinnDTExec.exe ), but trying to run with xp_cmdshell it gives the error mencioned above. And if there is another way to set dtexec.exe 32bits besides this way?

2. If I cannot run it throught xp_cmdshell, how could I pass a parameter like convert(varchar,getdate(),112) in the format YYYYMMDD instead of the static parameter 20070101.


Thanks in advance.
Marco Francisco (Portugal)

View 9 Replies View Related

Cmdexec Subsystem Failure

Mar 24, 2006



I have a scheduled job that has been running fine for 2 years, but this week I keep getting the following error:

0x469A75B7998F8142A910FA7E9983CCDF

has caused an exception in the CmdExec subsystem and has been terminated.



the enterprise manager shows that the job failed, but the app still shows up in task manager.

any suggestions?



thanks

View 1 Replies View Related

CmdExec "COPY" Command Fail To Run

Oct 11, 2000

Hi:

I want to copy a backup from the production server to another server
periodically. The following is the DOS command and it works in DOS propmt
d: is the local drive and g: is the mapping server
---------------------------------------------------
"copy d:ackupackup_CustomerDB.dat g:mssqlackupackup_on_3Wednesdayackup_CustomerDB .dat"

I try to use the above command in the executive task with CmdExec as type,
if failed. Then try on
"cmd c/ copy d:ackupackup_CustomerDB.dat g:mssqlackupackup_on_3Wednesdayackup_CustomerDB .dat"

this time, it started to run with no error. But it run 40 miniutes and I cancelled it, since it should only run 10 minuts.

thanks for the help
David

View 1 Replies View Related

Using CmdExec To Execute Dtexec In Sqlagent

Apr 12, 2008

I'm a bit confused. On the command line of the job step property I entered dtexec /SQL... and got an error saying file not found, I assumed dtexec itself couldnt be found. So I tried /SQL .... by itself and got something that looked more like a security error. If I make the step property type "ssis" job appears to run fine, I receive my pkg's on success (rather than on failure) email but I know everything isnt fine because even if no data is ETL'd, first executable is supposed to (and always has in client) insert a row into an audit table and it doesnt. If I set job step "type" to t-sql and simply db email myself with t-sql command, everything is fine.

The first question is "Wouldnt dtexec need to be specified, how else could sqlagent know what I'm trying to run?" If answer is yes, what's wrong with my syntax or environment?

View 9 Replies View Related

Operationg System Command (CmdExec) Job Failing

Nov 15, 2006

I have sql 2000 job that has been setup as a "Operating System Command (CmdExec) job. I am logged into the SQL Server as DomainNameSQLAdmin this domain account is part of the Administrator group on the SQL Server that the job in running on. This account has SysAdmin rights and is also starting the MSSQLSERVER Service and SQLSERVERAGENT Service on the same machine.

The job just copies files from one directory to another, here's the code.

D:
cd MSSQLBACKUPAPAP_Primary
xcopy *.* D:MSSQLBACKUPAP /s/y/d

When run as a job, with the owner of the job being DomainNameSQLAdmin the job fails with the following error message: Executed as user: DomainNameSQLAdmin. The process could not be created for step 1 of job 0x822E9AD29DCAAF4196369A46C7FE212A (reason: Access is denied). The step failed.

Here's the weird part if I open a command window on the sql server and run the batch it works fine.

I even tried executing the commands via xp_cmdshell but that didn't work either, I recieved the message: (1 row(s) affected) with the output being NULL and the file was never copied.

Anyone have an idea whats going on?

View 4 Replies View Related

SQL2K CmdExec Proxy Account Setup

Aug 15, 2007

Hi, I have the following setup:

- Win 2K Server, SP4
- SQL Srv 2K, SP4
- A 'DEV' domain, with an 'Administrator' account with all possible rights on the system

I need to configure a CmdExec proxy account in order to allow non-sys-admin users to execute the master.dbo.xp_CmdShell procedure.

When attempting to do this via QA as follows:


EXEC master.dbo.xp_sqlagent_proxy_account N'SET',
N'DEV', -- agent_domain_name
N'Administrator', -- agent_username
N'password' -- agent_password

...I get the following error:


"The system cannot find the path specified."



When attempting to do this via QA as follows (note: only change is adding domain to agent_username arg):


EXEC master.dbo.xp_sqlagent_proxy_account N'SET',
N'DEV', -- agent_domain_name
N'DEVAdministrator', -- agent_username
N'password' -- agent_password

...I get the following error:


"Error executing extended stored procedure: Specified user can not login"




I have tried this through Enterprise Manager and get identical results, of course.

I have also tried all of the following:
- different OS user accounts, including local system accounts with local admin rights;
- assigning the OS account to a SQL login with System Admin role/rights;
- specifically assigning the above SQL login with EXEC rights on the master.dbo.xp_CmdShell procedure;
- verifying local security policy settings, as per the following link: http://support.microsoft.com/?id=283811;
- pulling out my hair and banging my head against the wall.

Can anyone H E L P ? ! ! !

Thanks,

Joe

View 6 Replies View Related

Configuration Files Do Not Work In CmdExec Mode

Oct 18, 2006

I have created an Integration Services package on my development machine. The package contains a configuration file witch let's say is stored in c:projectsMyIntegrationServicesProjectmyConfigfile.dtsConfig (on my dev machine).

Then I have another "Production" machine where I import the SSIS package into an SQL database. I then create an sql-job with only one step, to run my SSIS package. This works fine if I configure the step to be an "SQL Integration services package" and configure it to use my configurationfile.

However I would like to configure this package as a CmdExec step. In the commandline, I specify /CONFIGFILE "d:....myConfigfile.dtsConfig" (the correct path on the prod machine). But it seems to be ignored, because when I execute the package I get an error telling me that the configuretion file c:projectsMyIntegrationServicesProjectmyConfigfile.dtsConfig cannot be found.

What I try to say is, it seems like it ignors the config-file I specify on the command-line and tries to reach the config-file on a location that's probably stored somewhere in the SSIS package from the time it was created on my development machine.

Is there a way around this?

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved