January 6, 2006 at 8:22 am
I have several jobs that fail for unknown reasons. These jobs have many steps and I would like to be able to debug or trace these steps to determine exactly where the failure occurs. I suspect that I can use sql profiler, however; I don't understand how to build a profile to watch a job. Any suggested reading material or direction would be appreciated.
Thank you,
Chris
January 8, 2006 at 7:49 am
Hi Chris,
One tip that you may not have realised (apologies if you have) is that when you right click on the job in the jobs listing and select 'Job History', you get a list of the previous results and whether they failed or not.
On the top of that dialog box, is a tick box which will allow you to see the results of the individual steps within the job, along with the result of each step. Often there will be an error message indicating why it failed.
Hope that helps,
Martin
January 9, 2006 at 8:10 am
1. You could change the job step type to Operating System Command (CmdExec) and use Osql.exe utility to send the results to an output file.
2. Check SQL server error log as well as sql server agent error log to see if any errors were logged there.
3. Is SQL Server Agent running an account that has the required permissions? For example if your job requires to go across the network, or you want to notify operators through e-mail or pagers, you must set the account the SQLServerAgent service runs under to be a member of the Domain Users group.
Hope that helps.
Vik.
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply