April 21, 2004 at 8:44 am
For several days now I have struggled with a seemingly small issue. Getting a DTS package to run when scheduled in SQL Server Agent. I trawled all the forums and read up about the problems with permissions, configuration etc. but my problem would appear to be different. I have outlined the setup, errors etc. below as comprehensively as possible. Any help / insight would be appreciated.
Only one domain login has been used throughout with Local Admin rights on the machine AND sysadmin priv on the SQL Server
The following have been checked to ensure common user login/password:
When executed under SEM the pkg operates successfully
When scheduled and executed under SSA it fails - the log below shows the problem (The log above reflects the same error regardless of whether I have an active session (i.e. I am logged in at a terminal) or if I log off.)
----------------------------------------------------------
Package Steps execution information:
Step 'Drop table [LocalHrWizEmployee].[dbo].[MASTER] Step' succeeded
Step Execution Started: 21/04/2004 12:05:01
Step Execution Completed: 21/04/2004 12:05:01
Total Step Execution Time: 0.359 seconds
Progress count in Step: 0
Step 'Create Table [LocalHrWizEmployee].[dbo].[MASTER] Step' succeeded
Step Execution Started: 21/04/2004 12:05:01
Step Execution Completed: 21/04/2004 12:05:01
Total Step Execution Time: 0 seconds
Progress count in Step: 0
Step 'Copy Data from MASTER to [LocalHrWizEmployee].[dbo].[MASTER] Step' failed
Step Error Source: Microsoft OLE DB Provider for ODBC Drivers
Step Error Description:unavailable database
Step Error code: 80040E4D
Step Error Help File:
Step Error Help Context ID:0
Step Execution Started: 21/04/2004 12:05:01
Step Execution Completed: 21/04/2004 12:05:02
Total Step Execution Time: 0.047 seconds
Progress count in Step: 0
----------------------------------------------------------
I had thought it could be the Interbase/Firebird aspect BUT it runs successfully under SEM ... Day 4 and I need help ....
April 22, 2004 at 2:38 am
I'm sure you've rebooted the box since installing the db drivers. If you haven't it's worth ago.
We had a similar problem with oracle drivers and a reboot did the trick.
J
Thanks Jeet
April 22, 2004 at 4:07 am
I have rebooted, re-installed, tried on 3 different systems - same error. I suspect that the problem is something simple, such as rebooting but at this stage I have exhausted everything that I can think of.
Thanks for the input though.
Neil
April 22, 2004 at 7:35 am
So Interbase 6 is installed on the same server as SQL Server, correct?
April 22, 2004 at 7:44 am
Yes, Interbase is running as a Service.
April 22, 2004 at 7:48 am
So it's not an issue of having the correct drivers on the workstation where the DTS runs fine interactively from EM, but not having the correct drivers on the server, where the DTS executes when it is run as a job.
April 22, 2004 at 7:56 am
Correct. Both the SQL Server and the Interbase Server are running locally as services. The Interbase db and the SQL server db are both located on the local drive so there is no network connections / mapped drives.
I have tried several ODBC drivers as the problem seems to be related to with the SQLServerAgenth making a connection to the Interbase db:
Step Error Source: Microsoft OLE DB Provider for ODBC Drivers
Step Error Description:unavailable database
I am assuming it is the SQLServerAgent as the Enterprise Manager runs the packages without a problem using the same Drivers.
Permissions? Well I am a local Administrator, have the sysadmin priv on SQLServer and all the packages, connections, 'logins' for Enterprise Manager, SQLServerAgent and event eh SQLServerAgent Proxy are all under my login ... so I am a little confused.
April 22, 2004 at 1:39 pm
Did you create the package from your pc or actually sitting at the server? If you created the package at your pc, you probably won't be able to schedule it. I read somewhere that a DTS package looks to the OS where it was originally created.... Whatever the reason, I have found this to be true many times. If I don't create the package on the server itself, it won't run under a schedule.
Linda
April 22, 2004 at 2:48 pm
I would have to disagree with Linda's post.
I have created DTS packages on an WinNT workstation as well as XP, never on the server. I've been successful in scheduling all packages. The issues with jobs failing always stem from permissions of the agent account that the service is run under or the setup of the server being different than what is on the PC, meaning ODBC drivers set up on the PC but not on the server.
April 23, 2004 at 1:21 am
I can only go by my experience but in general packages are sensitive to where they are created - that is not to say they are 'locked' to the machine they were created but when moving them there is a checklist of sorts you have to go through to ensure that they will work when deployed on a new system. There are the obvious ones like the DSNs and drivers but also the way the packages reference connections, e.g. (local) or by explicit name.
Anyway back to the original issue ... to ensure that the issue of location was not a factor I duplicated the setup from scratch on a test box making sure that all db files, services (SQL Server and Interbase), DSNs, Drivers etc. etc. were run locally. The packages were created locally and are being run locally. Everything was being done under the same login which had sysadmin priv + local administrator + was a member of a domain (This should address all the normal issues related to having a lack of permissions and not being able to access or execute certain things). The following were all checked to ensure that they were using the same login with the priv. described above
I can only imagine that the problem lies in some way with the way SQL Server Agent executes. For the reasons I highlighted above I have tried to completely rule out permissions. Assuming that I have done this it possibly suggests that the Agent is trying in some way to make an unusual type of connection to the db via the System DSN that I have setup via the SQL OLE DB Provider for ODBC. Does anyone know if the Agent tries to exclusively open the db OR can only open a connection under certain conditions (excluding permission related reasons).
I am using MDAC 2.8 RTM and SQL Server 2000 SP3 so hopefully I should have the best mature technical platform MS has to offer.
This of course is just a wild theory born from desperation. Has anyone ever successfully used a scheduled package to connect to an Interbase db?
April 23, 2004 at 7:33 am
We pull data from DB2 and it seems like I remember running into an issue where we could not use the "IBM OLE DB Provider for DB2 Servers", but instead had to use the "Other (ODBC Data Source)" connection object in order to successfully extract data from DB2. Maybe its the same type of issue with Interbase??? (But I do not personally have any experience with this system.)
April 23, 2004 at 7:50 am
Unfortunately no improvement. I tried using both an ODBC connection and an OLE DB connection to Interbase, both failed when scheduled but succeeded when run through SEM.
THe OLE DB connection returned the following error:
Step Error Descriptionatabase connection failed.
SQLCODE=-904:
unavailable database
IBCODE=isc_unavailable
Step Error Help File:
Step Error Help Context ID:0
Interbase / MS SQL Server / DTS don't seem to be a popular mix based upon a few searches through google and the forums... perhaps this is why.
April 23, 2004 at 8:06 am
Just for fun... why don't you create a test package (on the server) and put in the piece that is failing and schedule it to run?
Linda
April 23, 2004 at 8:09 am
Have you checked this site?
http://www.ibdatabase.com/index.html
I'm out of ideas if its not a security issue with agent.
April 23, 2004 at 8:20 am
A key point on the website I had seen before. DTS can operate multiple threads/processes - and the default is 4 -the majority of Interbase ODBC drivers don't like this at all, to work around the problem I had to set the number of processes to 1. If you don't the SEM will just hang.
As to the security thing - unless I have missed something I think I have addressed it with my local admin/sysadmin/domain login.
Viewing 15 posts - 1 through 15 (of 18 total)
You must be logged in to reply to this topic. Login to reply