Wednesday, March 28, 2012
Job System Table
Three questions:
(1) Is there a table (a system table?) on sql server 2000 that will
give you a list of the jobs on the database and when they are
scheduled? Also,
(2) Is there a table on SQL server 2000 that will give you the list of
DTS packages?
(3) Does SQL server track dependencies between jobs and stored
procedures? That is does it store a reference to objects that a stored
procedure or DTS package uses? If so is this information available in
a table?
Thanks for the helpBonifide,
1 and 2 - yes. Download the following...it will help answer these questions
and maybe more.
SQL Server System Table Map
http://www.microsoft.com/sql/techinfo/productdoc/2000/systables.mspx
HTH
Jerry
"bonifide" <jeffsutthoff@.hotmail.com> wrote in message
news:1129748256.102327.303020@.o13g2000cwo.googlegroups.com...
> Hello,
> Three questions:
> (1) Is there a table (a system table?) on sql server 2000 that will
> give you a list of the jobs on the database and when they are
> scheduled? Also,
> (2) Is there a table on SQL server 2000 that will give you the list of
> DTS packages?
> (3) Does SQL server track dependencies between jobs and stored
> procedures? That is does it store a reference to objects that a stored
> procedure or DTS package uses? If so is this information available in
> a table?
> Thanks for the help
>|||Look in the MSDB DB for sysjobs, sysjobsschedules, sysjobsteps, sysdtspackages
http://sqlservercode.blogspot.com/
"bonifide" wrote:
> Hello,
> Three questions:
> (1) Is there a table (a system table?) on sql server 2000 that will
> give you a list of the jobs on the database and when they are
> scheduled? Also,
> (2) Is there a table on SQL server 2000 that will give you the list of
> DTS packages?
> (3) Does SQL server track dependencies between jobs and stored
> procedures? That is does it store a reference to objects that a stored
> procedure or DTS package uses? If so is this information available in
> a table?
> Thanks for the help
>|||Comments Inline
"bonifide" <jeffsutthoff@.hotmail.com> wrote in message
news:1129748256.102327.303020@.o13g2000cwo.googlegroups.com...
> Hello,
> Three questions:
> (1) Is there a table (a system table?) on sql server 2000 that will
> give you a list of the jobs on the database and when they are
> scheduled? Also,
There are multiple tables in msdb that together contain this information.
For jobs\databases, you will need to link sysjobsteps (for the database
information) and sysjobs. You will have to add sysjobservers if you are
using multi-server job administration. See the SQL 2000 System table map
for details.
> (2) Is there a table on SQL server 2000 that will give you the list of
> DTS packages?
msdb.dbo.sysdtspackages
> (3) Does SQL server track dependencies between jobs and stored
> procedures? That is does it store a reference to objects that a stored
> procedure or DTS package uses? If so is this information available in
> a table?
No. SQL Server 7.0 and higher use late bindings so you can create objects
that refer to other objects that may not exist yet. There are some semsible
exceptions such as you cannot create a trigger on a table that does not
exist, but job steps can refer to nonexistent objects indefinitely.
> Thanks for the help
>
--
Geoff N. Hiten
Senior Database Administrator
Microsoft SQL Server MVP
Job System Table
Three questions:
(1) Is there a table (a system table?) on sql server 2000 that will
give you a list of the jobs on the database and when they are
scheduled? Also,
(2) Is there a table on SQL server 2000 that will give you the list of
DTS packages?
(3) Does SQL server track dependencies between jobs and stored
procedures? That is does it store a reference to objects that a stored
procedure or DTS package uses? If so is this information available in
a table?
Thanks for the helpBonifide,
1 and 2 - yes. Download the following...it will help answer these questions
and maybe more.
SQL Server System Table Map
http://www.microsoft.com/sql/techin.../systables.mspx
HTH
Jerry
"bonifide" <jeffsutthoff@.hotmail.com> wrote in message
news:1129748256.102327.303020@.o13g2000cwo.googlegroups.com...
> Hello,
> Three questions:
> (1) Is there a table (a system table?) on sql server 2000 that will
> give you a list of the jobs on the database and when they are
> scheduled? Also,
> (2) Is there a table on SQL server 2000 that will give you the list of
> DTS packages?
> (3) Does SQL server track dependencies between jobs and stored
> procedures? That is does it store a reference to objects that a stored
> procedure or DTS package uses? If so is this information available in
> a table?
> Thanks for the help
>|||Look in the MSDB DB for sysjobs, sysjobsschedules, sysjobsteps, sysdtspackag
es
http://sqlservercode.blogspot.com/
"bonifide" wrote:
> Hello,
> Three questions:
> (1) Is there a table (a system table?) on sql server 2000 that will
> give you a list of the jobs on the database and when they are
> scheduled? Also,
> (2) Is there a table on SQL server 2000 that will give you the list of
> DTS packages?
> (3) Does SQL server track dependencies between jobs and stored
> procedures? That is does it store a reference to objects that a stored
> procedure or DTS package uses? If so is this information available in
> a table?
> Thanks for the help
>|||Comments Inline
"bonifide" <jeffsutthoff@.hotmail.com> wrote in message
news:1129748256.102327.303020@.o13g2000cwo.googlegroups.com...
> Hello,
> Three questions:
> (1) Is there a table (a system table?) on sql server 2000 that will
> give you a list of the jobs on the database and when they are
> scheduled? Also,
There are multiple tables in msdb that together contain this information.
For jobs\databases, you will need to link sysjobsteps (for the database
information) and sysjobs. You will have to add sysjobservers if you are
using multi-server job administration. See the SQL 2000 System table map
for details.
> (2) Is there a table on SQL server 2000 that will give you the list of
> DTS packages?
msdb.dbo.sysdtspackages
> (3) Does SQL server track dependencies between jobs and stored
> procedures? That is does it store a reference to objects that a stored
> procedure or DTS package uses? If so is this information available in
> a table?
No. SQL Server 7.0 and higher use late bindings so you can create objects
that refer to other objects that may not exist yet. There are some semsible
exceptions such as you cannot create a trigger on a table that does not
exist, but job steps can refer to nonexistent objects indefinitely.
> Thanks for the help
>
Geoff N. Hiten
Senior Database Administrator
Microsoft SQL Server MVP
Job System Table
Three questions:
(1) Is there a table (a system table?) on sql server 2000 that will
give you a list of the jobs on the database and when they are
scheduled? Also,
(2) Is there a table on SQL server 2000 that will give you the list of
DTS packages?
(3) Does SQL server track dependencies between jobs and stored
procedures? That is does it store a reference to objects that a stored
procedure or DTS package uses? If so is this information available in
a table?
Thanks for the help
Bonifide,
1 and 2 - yes. Download the following...it will help answer these questions
and maybe more.
SQL Server System Table Map
http://www.microsoft.com/sql/techinf...systables.mspx
HTH
Jerry
"bonifide" <jeffsutthoff@.hotmail.com> wrote in message
news:1129748256.102327.303020@.o13g2000cwo.googlegr oups.com...
> Hello,
> Three questions:
> (1) Is there a table (a system table?) on sql server 2000 that will
> give you a list of the jobs on the database and when they are
> scheduled? Also,
> (2) Is there a table on SQL server 2000 that will give you the list of
> DTS packages?
> (3) Does SQL server track dependencies between jobs and stored
> procedures? That is does it store a reference to objects that a stored
> procedure or DTS package uses? If so is this information available in
> a table?
> Thanks for the help
>
|||Look in the MSDB DB for sysjobs, sysjobsschedules, sysjobsteps, sysdtspackages
http://sqlservercode.blogspot.com/
"bonifide" wrote:
> Hello,
> Three questions:
> (1) Is there a table (a system table?) on sql server 2000 that will
> give you a list of the jobs on the database and when they are
> scheduled? Also,
> (2) Is there a table on SQL server 2000 that will give you the list of
> DTS packages?
> (3) Does SQL server track dependencies between jobs and stored
> procedures? That is does it store a reference to objects that a stored
> procedure or DTS package uses? If so is this information available in
> a table?
> Thanks for the help
>
|||Comments Inline
"bonifide" <jeffsutthoff@.hotmail.com> wrote in message
news:1129748256.102327.303020@.o13g2000cwo.googlegr oups.com...
> Hello,
> Three questions:
> (1) Is there a table (a system table?) on sql server 2000 that will
> give you a list of the jobs on the database and when they are
> scheduled? Also,
There are multiple tables in msdb that together contain this information.
For jobs\databases, you will need to link sysjobsteps (for the database
information) and sysjobs. You will have to add sysjobservers if you are
using multi-server job administration. See the SQL 2000 System table map
for details.
> (2) Is there a table on SQL server 2000 that will give you the list of
> DTS packages?
msdb.dbo.sysdtspackages
> (3) Does SQL server track dependencies between jobs and stored
> procedures? That is does it store a reference to objects that a stored
> procedure or DTS package uses? If so is this information available in
> a table?
No. SQL Server 7.0 and higher use late bindings so you can create objects
that refer to other objects that may not exist yet. There are some semsible
exceptions such as you cannot create a trigger on a table that does not
exist, but job steps can refer to nonexistent objects indefinitely.
> Thanks for the help
>
Geoff N. Hiten
Senior Database Administrator
Microsoft SQL Server MVP
Job Step
The job step is of type Operating System Command. This step kicks of an
executable.
Can you help me with a solution?
Thanks,
ChrisHow about creating a second step that has different parameters. Then create
a second job that runs prior to this job. In this second job, you can check
to see if it is Sunday and then enable appropriate step on first job and
disable the other one (and vice versa).
"csl" <kcl1998@.hotmail.com> wrote in message
news:uCOv4089HHA.3548@.TK2MSFTNGP06.phx.gbl...
>I have a job step that needs to run with a different parameter on Sunday.
> The job step is of type Operating System Command. This step kicks of an
> executable.
> Can you help me with a solution?
> Thanks,
> Chris
>|||Hi,
I do this with three job steps. Job step 2 has the 6 days a week command,
and job step 3 has the sunday command. In job step one I put a statement
that calls RAISERROR('whatever', 16, 1) on Sunday. Then I set up step one to
go to step 2 on success and step 3 on failure. Both steps 2 and 3 quit
reporting success on success and quit reporting failure on failure.
Or, just create two SQL Agent jobs. One runs weekly on Mon-Sat, and the
other runs weekly on Sun.
--
Thank you,
Daniel Jameson
SQL Server DBA
Children's Oncology Group
www.childrensoncologygroup.org
"Dragon" <noSpam_Badill@.hotmail.com> wrote in message
news:uk2aK689HHA.4584@.TK2MSFTNGP03.phx.gbl...
>
> How about creating a second step that has different parameters. Then
> create a second job that runs prior to this job. In this second job, you
> can check to see if it is Sunday and then enable appropriate step on first
> job and disable the other one (and vice versa).
> "csl" <kcl1998@.hotmail.com> wrote in message
> news:uCOv4089HHA.3548@.TK2MSFTNGP06.phx.gbl...
>>I have a job step that needs to run with a different parameter on Sunday.
>> The job step is of type Operating System Command. This step kicks of an
>> executable.
>> Can you help me with a solution?
>> Thanks,
>> Chris
>>
>
Friday, March 23, 2012
Job problem
I have a job where in one of the steps I'm coping a
database backup file from one server to the other using
an operating system command xcopy. The command I'm using
is below, but the job keeps failing on this step. The
error I get is "The job failed. The Job was invoked by
User TST-SQL\VDURAN. The last step to run was step 3
(copyfile).".
The command works fine if I execute from the actual
command prompt of the source server. My destination
server directory is shared and I have set my permssions
to full control for everyone. Please help.
xcopy d:\backups\TestBackup\OrdersDB.bak
\\duran\DBBackups\
TIA,
VicWhat is the exact error for step 3 ? Is this using a CmdExec job step ?
If you look at the step history you should see the exit code for the step
and the error.
If the file exists you will want to use the /Y switch for xcopy to allow
overwring of the file although this would generally hang the step if this
was the issue. How about just using copy /Y does this work ?
I take it that the SQLService account is running under a domain account ?
--
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Vic" <vduran@.specpro-inc.com> wrote in message
news:009c01c3d535$d23fb7c0$a101280a@.phx.gbl...
> Hello,
> I have a job where in one of the steps I'm coping a
> database backup file from one server to the other using
> an operating system command xcopy. The command I'm using
> is below, but the job keeps failing on this step. The
> error I get is "The job failed. The Job was invoked by
> User TST-SQL\VDURAN. The last step to run was step 3
> (copyfile).".
> The command works fine if I execute from the actual
> command prompt of the source server. My destination
> server directory is shared and I have set my permssions
> to full control for everyone. Please help.
> xcopy d:\backups\TestBackup\OrdersDB.bak
> \\duran\DBBackups\
>
> TIA,
> Vic|||Is it possible that you need to supply the actual path of
the xcopy command? Also, you may want to create the job
step to execute a command (.cmd) file rather than the
command itself. This would allow you to do some type of
eror code processing. It's been a long time since I've
done that in DOS batch files, but it should be doable.
Most likely you either have a path problem or a
permissions problem though.
I know this is a rather vague response, but hopefully it
will lead to something.
Matthew Bando
BandoM@.CSCTGI(remove).com
>--Original Message--
>Hello,
> I have a job where in one of the steps I'm coping a
>database backup file from one server to the other using
>an operating system command xcopy. The command I'm
using
>is below, but the job keeps failing on this step. The
>error I get is "The job failed. The Job was invoked by
>User TST-SQL\VDURAN. The last step to run was step 3
>(copyfile).".
> The command works fine if I execute from the actual
>command prompt of the source server. My destination
>server directory is shared and I have set my permssions
>to full control for everyone. Please help.
>xcopy d:\backups\TestBackup\OrdersDB.bak
>\\duran\DBBackups\
>
>TIA,
>Vic
>.
>|||Hello there.
I got kind of a similar issue with few jobs. To pin point
to the culprit, I set the DTS package to log the whole
process.
I found out which steps in my DTS package were failing and
not the generic SQL message from the job history, which
never says exactly what happened.
I have quite a few stpes in each job that uses windows
tasks. Two of those needs some time to be completed.
The first one, unzips a daily file to be run by other
steps to copy or update some tables.
The second step, copies the unzipped files to a different
server.
I applied two solutions for those command steps.
1. For the unzip command, I added an activeX step, which
loops while the file is being used by the DTS. Problem
solved here.
2. For the copy unzipped files to a different server (I
had to copy instead of moving files due to some internal
applications), I did take the step off the DTS and
schedule it to run a few minutes after the main job is
completed. Problem solved! for good.
Set the DTS log first to see exactly where your DTS is
failing, I bet is the move step (same thing happened to
me) I hope this helps. Good luck
>--Original Message--
>Hello,
> I have a job where in one of the steps I'm coping a
>database backup file from one server to the other using
>an operating system command xcopy. The command I'm using
>is below, but the job keeps failing on this step. The
>error I get is "The job failed. The Job was invoked by
>User TST-SQL\VDURAN. The last step to run was step 3
>(copyfile).".
> The command works fine if I execute from the actual
>command prompt of the source server. My destination
>server directory is shared and I have set my permssions
>to full control for everyone. Please help.
>xcopy d:\backups\TestBackup\OrdersDB.bak
>\\duran\DBBackups\
>
>TIA,
>Vic
>.
>
Wednesday, March 21, 2012
Job next run times don't update
on the next run times for the jobs do not update, the only
way to get them to update is to stop and restart the agent?Hi David,
Thank you for using MSDN Newsgroup! It's my pleasure to assist you with your issue.
First of all, I would like to confirm my understanding of your issue.
From your description, I understand that you would like to know if stop and restart the agent is
the ONLY way to update the jobs' next run times. Have you successfully update the run time
with this method?
Based on my experience, even though you re-start the Agent, the jobs' run times will not be
updated because SQL calls getlocaltime() API of the Operating System to schedule jobs.
What's more, I'm unsure of what causes you changed the system clock, except for the
Daylight Savings Time Change. If the "Daylight Savings Time Change" is not the scenario on
your side. Could you specify more on the scheduled jobs and how you change the system
clock so that we will be clearer what happened on your side. Thanks in advance!
During a Daylight Savings Time change, there is no need to stop the SQL Server services
since it does not utilize the current date and time for any critical functionality that would result in
data integrity issues.
"SQL Server" scheduled jobs to handle daylight saving's time with the following two methods
to track job schedules:
1. Scheduling can be done on a polled basis, scanning all jobs for the time they should be run,
e.g. daily at 1:05am. This would find and run the job a second time when the clock is set back
to 1am.
2. Scheduling can be done on a queued basis, where jobs are queued according to the next
time they should be run and dequeued once they are executed at that time (and enqueued at
their new next time). This way they will only be run a single time, the first time the date/time is
encountered.
"SQL Server Agent" uses the SECOND queued method for its job scheduling. It uses the
sysjobschedules table which has the next_run_date and next_run_time columns which get
updated periodically by SQL Server Agent.
Since the next run time is reset every time a job is run, the job will not be run multiple times if the
clock is set back. This is fine for jobs that run only once a day or less often. It is probably what
you expect will happen; the job will not be run a second time.
However, if you have a job that executes once an hour or more frequently, you probably do
want it to continue to run on the same schedule even if the clock has been turned back.
Perhaps your job cleans out a table every 5 minutes :-) ; you'd expect it to clean out the table
every 5 minutes regardless of whether the clock has been set back.
But with SQL Server, when the job is run at 1:58am (for example), the next run time will be set to
2:03, which now will not happen for over an hour once the clock is set back to 1:00am. And of
course, in the Spring when the clocks are moved forward, there is a different problem where
the times between 2am and 3am never occur, probably skipping any jobs that were
scheduled during that time. I haven't tested this.
David, does that answer your question? If there is anything more I can assist you with, please
feel free to post it in the group.
Best regards,
Billy Yao
Microsoft Online Partner Support
----
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
Please reply to newsgroups only. Thanks.
Monday, March 19, 2012
Job failure notifications for non-administrative users
good. However, I don't wish to give them System Administrator
privileges, and when they create their jobs, the check box to "e-mail
operator" in the job notifications tab is greyed out. Is this a
feature? I'm having difficulty finding documentation on it, or even any
mention, where a distinction is made between administrators and
standard users.
Other than setting up the notifications myself after the jobs are
created, is there any way around this issue? This is on SQL 2000 EE,
service pack 3a, running on Windows 2K Advanced Server.
Thanks,
Steve
Hi Steve,
A distinction is made between administrators and standard users?
This depends of as configured the Services SQL Server Agent, the account is
"Local System" or is a administrator account o User Email Account?.
If is "Local System", this can you problem.
Hermilson Tinoco
"Steve" wrote:
> Some of my power users create their own SQL Agent jobs. All well and
> good. However, I don't wish to give them System Administrator
> privileges, and when they create their jobs, the check box to "e-mail
> operator" in the job notifications tab is greyed out. Is this a
> feature? I'm having difficulty finding documentation on it, or even any
> mention, where a distinction is made between administrators and
> standard users.
> Other than setting up the notifications myself after the jobs are
> created, is there any way around this issue? This is on SQL 2000 EE,
> service pack 3a, running on Windows 2K Advanced Server.
> Thanks,
> Steve
>
|||SQL Server Agent is running under the same account as the SQL Server, a
domain account set up to be a local administrator.
Note that as an administrator I can add notifications to both my own
jobs and my users' jobs; it's just the users that can't add
notifications to their own jobs.
Steve
Job failure notifications for non-administrative users
good. However, I don't wish to give them System Administrator
privileges, and when they create their jobs, the check box to "e-mail
operator" in the job notifications tab is greyed out. Is this a
feature? I'm having difficulty finding documentation on it, or even any
mention, where a distinction is made between administrators and
standard users.
Other than setting up the notifications myself after the jobs are
created, is there any way around this issue? This is on SQL 2000 EE,
service pack 3a, running on Windows 2K Advanced Server.
Thanks,
SteveHi Steve,
A distinction is made between administrators and standard users'
This depends of as configured the Services SQL Server Agent, the account is
"Local System" or is a administrator account o User Email Account?.
If is "Local System", this can you problem.
Hermilson Tinoco
"Steve" wrote:
> Some of my power users create their own SQL Agent jobs. All well and
> good. However, I don't wish to give them System Administrator
> privileges, and when they create their jobs, the check box to "e-mail
> operator" in the job notifications tab is greyed out. Is this a
> feature? I'm having difficulty finding documentation on it, or even any
> mention, where a distinction is made between administrators and
> standard users.
> Other than setting up the notifications myself after the jobs are
> created, is there any way around this issue? This is on SQL 2000 EE,
> service pack 3a, running on Windows 2K Advanced Server.
> Thanks,
> Steve
>|||SQL Server Agent is running under the same account as the SQL Server, a
domain account set up to be a local administrator.
Note that as an administrator I can add notifications to both my own
jobs and my users' jobs; it's just the users that can't add
notifications to their own jobs.
Steve
Monday, March 12, 2012
Job fails after system IP Change
not have a static IP currently, but has had the same IP from my provider
for over 6 months. Recently my IP finally changed and my SQL job
started failing immediatly after. My job owner is setup as my local
Windows user account. I tried changing the owner to get the job working
again to no avail. Then I recreated the job and the job worked fine.
My question is, what ties the job to the old IP when the original job is
created? Is there a way around this?
--MB
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!What kind of error did you have ?
And what is the steps this job is performing ?
I mean what particularly performing local package ?
Regards
---
All information provided above AS IS.
"Michael Baker" <michael_baker@.advantexmail.net> wrote in message
news:uckAcr7oDHA.2588@.tk2msftngp13.phx.gbl...
> I have a job that runs a local package on my sql server. My server does
> not have a static IP currently, but has had the same IP from my provider
> for over 6 months. Recently my IP finally changed and my SQL job
> started failing immediatly after. My job owner is setup as my local
> Windows user account. I tried changing the owner to get the job working
> again to no avail. Then I recreated the job and the job worked fine.
> My question is, what ties the job to the old IP when the original job is
> created? Is there a way around this?
> --MB
>
> *** Sent via Developersdex http://www.developersdex.com ***
> Don't just participate in USENET...get rewarded for it!|||Here is the error from the Job history:
Executed as user: HOME\SYSTEM. DTSRun: Loading... Error:
-2147467259 (80004005); Provider Error: 17 (11) Error string:
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or
access denied. Error source: Microsoft OLE DB Provider for SQL
Server Help file: Help context: 0. Process Exit Code 1.
The step failed.
There is just one step to perform, so it failed on the first step.
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Friday, March 9, 2012
job failed (SSIS). Executed as user: SRVDESASQL2005\SYSTEM.
I've made SSIS using domain security and after that it has been scheduled by
Sql Server Agent. But that job fails and looking into history job I read:
"Executed as user: SRVDESASQL2005\SYSTEM. The package execution failed. The
step failed."
Mssql Server agent is being used for local system. Is there the problem?
Nevertheles the aforementioned user have sy
Does anyone ever faced this kind of issue?
Thanks in advance,This issue is already solved.
Please post DDL, DCL and DML statements as well as any error message in
order to understand better your request. It''''s hard to provide information
without seeing the code. location: Alicante (ES)
"Enric" wrote:
> Hi everyone,
> I've made SSIS using domain security and after that it has been scheduled
by
> Sql Server Agent. But that job fails and looking into history job I read:
> "Executed as user: SRVDESASQL2005\SYSTEM. The package execution failed. T
he
> step failed."
> Mssql Server agent is being used for local system. Is there the problem?
> Nevertheles the aforementioned user have sy
> Does anyone ever faced this kind of issue?
> Thanks in advance,
>
>
>
>
>|||Just curious.. what was the reason. Was it because SSIS accessed some
resource in the network for whcih the local user didn't have access'
"Enric" wrote:
> This issue is already solved.
> --
> Please post DDL, DCL and DML statements as well as any error message in
> order to understand better your request. It''''s hard to provide informati
on
> without seeing the code. location: Alicante (ES)
>
> "Enric" wrote:
>
job failed (SSIS). Executed as user: SRVDESASQL2005\SYSTEM.
Hi everyone,
I've made SSIS using domain security and after that it has been scheduled by Sql Server Agent. But that job fails and looking into history job I read:
"Executed as user: SRVDESASQL2005\SYSTEM. The package execution failed. The step failed."
Mssql Server agent is being used for local system. Is there the problem?
Nevertheles the aforementioned user have sysadmin role.
Does anyone ever faced this kind of issue?
Thanks in advance,
Check out this kb article, which digs into scheduling and permissions problems, and the way to troubleshoot them:
http://support.microsoft.com/kb/918760
|||Effectively I was setting local system as user for the service so that...
Thanks anyway.
Job Execution Information not written to system tables
Hello Chaps
Intermittent problem with the SQL Agent job history not getting written to the history table. Background:
Today we noticed the account SQL Agent runs under cropping up in sp_who2. A quick check of the activity monitor said nothing was running. We ran a trace and, based on the SQL being executed, had a word with one of the developers who confirmed they had manually executed one of the jobs.
There was no record anywhere that the job had run. There has been an issue with this particular job, when executed by this user, not showing up in history before but, as mentioned, this had been intermittent and we thought that a restart of the service had sorted it.
Stuff run to try to track the job:
EXEC sp_help_jobactivity @.job_name = 'MyJob'
EXEC sp_help_jobhistory @.job_name = 'MyJob'
SELECT *
FROM dbo.sysjobhistory
WHERE job_id = 'MyJob GUID'
The first returned a row with no details in the columns indicating activity (e.g. last_executed_step_date and other columns were null).
sp_help_jobhistory had some historical records but nothing since mid last month.
sysjobhistory correlated with sp_help_jobhistory as you would expect.
Right clicking the job in SSMS and viewing history correlated with sp_help_jobhistory (i.e. some records but nothing since mid-June).
We edited the SQL in the job step and got the developer to rerun the job and, typically, everything appeared as it should in all the above result sets.
Obviously this is tricky to track down since it has been intermittent but does anyone recognise anything that I have described above? I have of course googled but there doesn't really seem to be anything about it.
We have considered there may be a problem in MSDB and may try running CHECKDB to see if anything comes up but somehow I doubt it will.
Ta!I have never seen this.
perhaps you dev was trying to clean up after himself? ;)|||I have never seen this.
perhaps you dev was trying to clean up after himself? ;)I'll take this opportunity to rebuke you for posting totally irrelevent information. Boo! :p
.....
and coincidently bump my post ;)|||I'll take this opportunity to rebuke you for posting totally irrelevent information. Boo! :p
.....
and coincidently bump my post ;)
What are your job history retention settings? What's the maximum number of rows of history total and per job?
By default, I believe that the settings for job history retention are 1000 rows total and 100 rows per job. It's one of the first things I change when setting up a new server. My "default" settings are 10,000 rows total and 1,000 rows per job. Sometimes I feel that even this is not enough.
Also, are there other jobs (such as replication) that run with a great deal of frequency? Like once per minute or so? This would have the tendency of "hogging" the history table.
Ta (or whatever it is you Brits say),
hmscott|||Thanks for responding :)
Yeah - our settings were at the default. However we don't run many jobs (no replication, no "sniffers" running every minute). I checked the number of records in the tables when we had the problem and neither the total nor per job numbers had quite hit the limit. I did up them just to be sure. AFAIK (and I would be shocked if it was otherwise) these work on a LIFO basis though anyway.
Whoop whooop (or whatever you Yanks say :D)|||Thanks for responding :)
You're welcome; I didn't see it the first time around or I would have said something.
AFAIK (and I would be shocked if it was otherwise) these work on a LIFO basis though anyway.
You are correct. I have, however, seen some situations where the history gets overwritten rather quickly. I wasn't certain how long after job execution you were looking in the history tables.
The only other thing I can suggest is to run a trace on a job that completes normally (and writes history to the history tables) and then run another trace on the job with which you are having issues.
Whoop whooop (or whatever you Yanks say :D)
No, no, you obviously have no understanding of us d@.mn Yankees. We say things like, "Reach for the sky, partner!" or "This here forum ain't big enough for the two of us" or, sometimes, "Make mine a double latte soy skinny harmless, and my friend Serge here will have a half-caf grande with legs. Oooo, is that diamond in your ear real?"
:D
Regards,
hmscott|||By the way poots, I wiki'd Pootle Flump and came across the following entry:
The Flumps (http://en.wikipedia.org/wiki/The_Flumps) :shocked:
Now I am afraid I will be having nightmares for the next month.
[shudder /]
:D
hmscott|||By the way poots, I wiki'd Pootle Flump and came across the following entry:
The Flumps (http://en.wikipedia.org/wiki/The_Flumps) :shocked:
Now I am afraid I will be having nightmares for the next month.
[shudder /]To help your nightmares along, I am the one in the white hat :)
Ta re trace. It is tricky catching it from the beginning since it is intermittent. We did run profiler whilst it was running this time but there seemed to be nothing unusual going on...
Job Execution Error - Please Help
I have started having a problem with my SQL Server 2005 SSIS system and it has become a nightly event. What is happening is that sometime in the evening before 7:30 the server gets into a state in which any SSIS job that attempts to run, fails. The error message that SSIS reports is:
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80040E14 Description: "Could not bulk load because SSIS file mapping object 'Global\DTSQLIMPORT ' could not be opened. Operating system error code 8(Not enough storage is available to process this command.). Make sure you are accessing a local server via Windows security.".
I can bounce the SQL Server service and then packages run normally.
I will be greatful to anyone who can help with this error.
Best Regards,
Mark Redman.
Just searching I see this KB about server configuration.
"Err Msg: Not Enough Server Storage Is Available to Process This Command"
http://support.microsoft.com/kb/225782/en-us
Hope that helps
|||This Error has been solved. It turned out that all of the jobs were using the SQL Server destination with a named instance. Even though the destination was the local server, it appears that unless you use the <Local> designation, the server believes that you are going to a remote machine. Once I changed all of the destinations to an OLEDB connection, the errors disappeared.Job Execution Error - Please Help
I have started having a problem with my SQL Server 2005 SSIS system and it has become a nightly event. What is happening is that sometime in the evening before 7:30 the server gets into a state in which any SSIS job that attempts to run, fails. The error message that SSIS reports is:
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80040E14 Description: "Could not bulk load because SSIS file mapping object 'Global\DTSQLIMPORT ' could not be opened. Operating system error code 8(Not enough storage is available to process this command.). Make sure you are accessing a local server via Windows security.".
I can bounce the SQL Server service and then packages run normally.
I will be greatful to anyone who can help with this error.
Best Regards,
Mark Redman.
Just searching I see this KB about server configuration.
"Err Msg: Not Enough Server Storage Is Available to Process This Command"
http://support.microsoft.com/kb/225782/en-us
Hope that helps
|||This Error has been solved. It turned out that all of the jobs were using the SQL Server destination with a named instance. Even though the destination was the local server, it appears that unless you use the <Local> designation, the server believes that you are going to a remote machine. Once I changed all of the destinations to an OLEDB connection, the errors disappeared.Wednesday, March 7, 2012
Job Change History
the system tables in msdb but I don't see how to tell who is doing it.
Only when.
On Feb 26, 2:29Xam, songstre <songs...@.gmail.com> wrote:
> Anyone know how to tell who is changing a db maintenance plan? I found
> the system tables in msdb but I don't see how to tell who is doing it.
> Only when.
Please check who has invoked the job last time if somebody is
modifying the job the he may want to execute also . With the help of
job history you can find who has invoked the job last time.
Assuming the person doesn't have direct access to server.
Thanks
Ajay Rengunthwar
MCTS
|||On Feb 25, 11:03Xpm, Ajay Rengunthwar <aju...@.gmail.com> wrote:
> On Feb 26, 2:29Xam, songstre <songs...@.gmail.com> wrote:
>
> Please check who has invoked the job last time if somebody is
> modifying the job the he may want to execute also . With the help of
> job history you can find who has invoked the job last time.
> Assuming the person doesn't have direct access to server.
> Thanks
> Ajay Rengunthwar
> MCTS
It was last executed by NT AUTHORITY\SYSTEM on a schedule. So this
doesn't help much.
|||Hi,
I'm always wondering is it possible to check?
Regards,
anxcomp
Job Change History
the system tables in msdb but I don't see how to tell who is doing it.
Only when.On Feb 26, 2:29=A0am, songstre <songs...@.gmail.com> wrote:
> Anyone know how to tell who is changing a db maintenance plan? I found
> the system tables in msdb but I don't see how to tell who is doing it.
> Only when.
Please check who has invoked the job last time if somebody is
modifying the job the he may want to execute also . With the help of
job history you can find who has invoked the job last time.
Assuming the person doesn't have direct access to server.
Thanks
Ajay Rengunthwar
MCTS|||On Feb 25, 11:03=A0pm, Ajay Rengunthwar <aju...@.gmail.com> wrote:
> On Feb 26, 2:29=A0am, songstre <songs...@.gmail.com> wrote:
> > Anyone know how to tell who is changing a db maintenance plan? I found
> > the system tables in msdb but I don't see how to tell who is doing it.
> > Only when.
> Please check who has invoked the job last time if somebody is
> modifying the job the he may want to execute also . With the help of
> job history you can find who has invoked the job last time.
> Assuming the person doesn't have direct access to server.
> Thanks
> Ajay Rengunthwar
> MCTS
It was last executed by NT AUTHORITY\SYSTEM on a schedule. So this
doesn't help much.|||Hi,
I'm always wondering is it possible to check?
--
Regards,
anxcomp
Job and Stored Procedure Problems
Proc 1, cycles through the system table and pulls out the names of all DB's.
Proc 2 is called by Proc 1, after it grabs 1 of the database names. It then
performs a type of backup based on a flag:
F = Full, D = Differential, and T = Transaction Logs.
I capture any errors and return them to Proc 1, so I can formulate an email
giving status.
At the end of Proc 1, I generate an email and ship off, giving the status of
each of the backups.
The process works just fine, if you do the TSQL statement through a query
window, reporting the status of the backup or error message. The problem I
am having, is when i schedule the job. To test it, I took one of my DB's
offline. When I run it through the Query Window, all errors and successes
report just fine.
When I run it through the Job, it fails at the offline database and kills
the entire job. Since the email isn't sent till the end of proc 1, the
email is never being generated, because upon failure of proc 2, it aborts
the entire job with an error.
It still backs up all the databases, just doesn't finish the email portion
of the process.
I've played with the job options, to continue to next step, even though one
doesn't exist, exit with success, doesn't do it, I've even played with SET
XACT_ABORT OFF
Thanks.Hi Kevin
You should be checking the status of the database in sysdatabases to exclude
offline one.
John
"Kevin Antel" wrote:
> I've written 2 stored procedures.
> Proc 1, cycles through the system table and pulls out the names of all DB'
s.
> Proc 2 is called by Proc 1, after it grabs 1 of the database names. It th
en
> performs a type of backup based on a flag:
> F = Full, D = Differential, and T = Transaction Logs.
> I capture any errors and return them to Proc 1, so I can formulate an emai
l
> giving status.
> At the end of Proc 1, I generate an email and ship off, giving the status
of
> each of the backups.
> The process works just fine, if you do the TSQL statement through a query
> window, reporting the status of the backup or error message. The problem
I
> am having, is when i schedule the job. To test it, I took one of my DB's
> offline. When I run it through the Query Window, all errors and successes
> report just fine.
> When I run it through the Job, it fails at the offline database and kills
> the entire job. Since the email isn't sent till the end of proc 1, the
> email is never being generated, because upon failure of proc 2, it aborts
> the entire job with an error.
> It still backs up all the databases, just doesn't finish the email portion
> of the process.
> I've played with the job options, to continue to next step, even though on
e
> doesn't exist, exit with success, doesn't do it, I've even played with SET
> XACT_ABORT OFF
> Thanks.
>
>
Friday, February 24, 2012
jdbc permissions
as I'm trying to connect Tomcat 5 to MSDE, according to the help system, I
have to give the jdbc driver some read/write perms, but as the java is
actually a servlet, there is no codebase being used.
Anyone got any ideas on where I can set the permissions?Make sure you give sql permissions to the sql user you are
using in your servlet to connect to sql server. There is
no concept of giving read/write permissions to a jdbc
driver.
Let us know if you need more clarification on this or how
to do it.
hth.
>--Original Message--
>seems precious few answers in the jdbc group...
>as I'm trying to connect Tomcat 5 to MSDE, according to
the help system, I
>have to give the jdbc driver some read/write perms, but
as the java is
>actually a servlet, there is no codebase being used.
>Anyone got any ideas on where I can set the permissions?
>.
>|||<anonymous@.discussions.microsoft.com> wrote in news:1493501c3fa41
$8cbdc0d0$a301280a@.phx.gbl:
well, this is the page from the helpfile thats caused me to ask:
''
Using the SQL Server 2000 Driver for JDBC on a Java 2 Platform
----
--
When using the SQL Server 2000 Driver for JDBC on a Java 2 Platform with
the standard security manager enabled, you must give the driver some
additional permissions. Refer to your Java 2 Platform documentation for
more information about the Java 2 Platform security model and
permissions.
You can run an application on a Java 2 Platform with the standard
security manager using:
"java -Djava.security.manager application_class_name"
where application_class_name is the class name of the application.
Web browser applets running in the Java 2 plug-in are always running in a
Java Virtual Machine with the standard security manager enabled. To
enable the necessary permissions, you must add them to the security
policy file of the Java 2 Platform. This security policy file can be
found in the jre/lib/security subdirectory of the Java 2 Platform
installation directory.
To use JDBC data sources, all code bases must have the following
permissions:
// permissions granted to all domains
grant {
// DataSource access
permission java.util.PropertyPermission "java.naming.*", "read,write";
// Adjust the server host specification for your environment
permission java.net.SocketPermission "*.microsoft.com:0-65535",
"connect";
};
To use insensitive scrollable cursors, and perform client-side sorting of
some DatabaseMetaData ResultSets, all code bases must have access to
temporary files. If access to temporary files is not available, the
driver may throw an exception indicating that it is unable to set up a
static cursor cache.
For JDK 1.1 environments, access to "current working directory" must be
granted.
For Java 2 environments, access to the temporary directory specified by
the VM configuration must be granted.
The following is an example of permissions being granted for the C:\TEMP
directory:
// permissions granted to all domains
grant {
// Permission to create and delete temporary files.
// Adjust the temporary directory for your environment.
permission java.io.FilePermission "C:\\TEMP\\-", "read,write,delete";
};
'''
> Make sure you give sql permissions to the sql user you are
> using in your servlet to connect to sql server. There is
> no concept of giving read/write permissions to a jdbc
> driver.
> Let us know if you need more clarification on this or how
> to do it.
>
via the tomcat log, its failing to load the jdbc driver, but whether its
authentication or unable to find the driver, I'm not sure
> hth.
>>--Original Message--
>>seems precious few answers in the jdbc group...
>>as I'm trying to connect Tomcat 5 to MSDE, according to
> the help system, I
>>have to give the jdbc driver some read/write perms, but
> as the java is
>>actually a servlet, there is no codebase being used.
>>Anyone got any ideas on where I can set the permissions?
>>.
>|||I apologige for it. There is nothing special you need to
do on sql server side. I will post more if I can find more
information on this.
Thanks.
>--Original Message--
><anonymous@.discussions.microsoft.com> wrote in
news:1493501c3fa41
>$8cbdc0d0$a301280a@.phx.gbl:
>well, this is the page from the helpfile thats caused me
to ask:
>''
>Using the SQL Server 2000 Driver for JDBC on a Java 2
Platform
>----
--
>--
>When using the SQL Server 2000 Driver for JDBC on a Java
2 Platform with
>the standard security manager enabled, you must give the
driver some
>additional permissions. Refer to your Java 2 Platform
documentation for
>more information about the Java 2 Platform security model
and
>permissions.
>You can run an application on a Java 2 Platform with the
standard
>security manager using:
>"java -Djava.security.manager application_class_name"
>where application_class_name is the class name of the
application.
>Web browser applets running in the Java 2 plug-in are
always running in a
>Java Virtual Machine with the standard security manager
enabled. To
>enable the necessary permissions, you must add them to
the security
>policy file of the Java 2 Platform. This security policy
file can be
>found in the jre/lib/security subdirectory of the Java 2
Platform
>installation directory.
>To use JDBC data sources, all code bases must have the
following
>permissions:
>// permissions granted to all domains
>grant {
>// DataSource access
>permission
java.util.PropertyPermission "java.naming.*", "read,write";
>// Adjust the server host specification for your
environment
>permission java.net.SocketPermission "*.microsoft.com:0-
65535",
>"connect";
>};
>To use insensitive scrollable cursors, and perform client-
side sorting of
>some DatabaseMetaData ResultSets, all code bases must
have access to
>temporary files. If access to temporary files is not
available, the
>driver may throw an exception indicating that it is
unable to set up a
>static cursor cache.
>For JDK 1.1 environments, access to "current working
directory" must be
>granted.
>For Java 2 environments, access to the temporary
directory specified by
>the VM configuration must be granted.
>The following is an example of permissions being granted
for the C:\TEMP
>directory:
>// permissions granted to all domains
>grant {
>// Permission to create and delete temporary files.
>// Adjust the temporary directory for your environment.
>permission java.io.FilePermission "C:\\TEMP\\-
", "read,write,delete";
>};
>'''
>
>
>
>> Make sure you give sql permissions to the sql user you
are
>> using in your servlet to connect to sql server. There
is
>> no concept of giving read/write permissions to a jdbc
>> driver.
>> Let us know if you need more clarification on this or
how
>> to do it.
>via the tomcat log, its failing to load the jdbc driver,
but whether its
>authentication or unable to find the driver, I'm not sure
>
>> hth.
>>--Original Message--
>>seems precious few answers in the jdbc group...
>>as I'm trying to connect Tomcat 5 to MSDE, according to
>> the help system, I
>>have to give the jdbc driver some read/write perms, but
>> as the java is
>>actually a servlet, there is no codebase being used.
>>Anyone got any ideas on where I can set the permissions?
>>.
>>
>.
>