Re: Cannot execute DTS package

From: Peter Afonin (peter_at_gudzon.net)
Date: 09/14/04


Date: Tue, 14 Sep 2004 14:16:31 -0700

Thank you very much, Hermit, it worked.

The problem was that when I tried to add 'NT AUTHORITY\NETWORK SERVICE'
manually in Enterprise Mgr - I couldn't find it (I don't understand why),
but when I ran
EXEC sp_grantlogin 'NT AUTHORITY\NETWORK SERVICE' - it worked.

Peter

"Hermit Dave" <hermitd.REMOVE@CAPS.AND.DOTS.hotmail.com> wrote in message
news:uDzkzKpmEHA.1844@TK2MSFTNGP12.phx.gbl...
> good old asp.net.
> Whats happening is that it is trying to execute the Query with context of
NT
> AUTHORITY\NETWORK SERVICE
> since you are using trusted connection.
>
> so either set up the above user to access SQL & the database.
> or just use impersonate identity tag to impersonate a fixed user.
>
> matrix detailing the execution context with asp.net
>
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnnetsec/html/SecNetAP05.asp
>
> code project article which has snippet to allow aspnet account (worker
> process in 2003 runs under Network Server) to the database
> http://www.codeproject.com/cs/database/sql_in_csharp.asp
>
> --
>
> Regards,
>
> Hermit Dave
> (http://hdave.blogspot.com)
> "Peter Afonin" <peter@gudzon.net> wrote in message
> news:uV0th3omEHA.592@TK2MSFTNGP11.phx.gbl...
> > Hello,
> >
> > Our SQL server used to run under System account, and I had no problems
> > executing DTS packages from the ASP.NET:
> >
> > Dim oPkg As DTS.Package
> > oPkg = CreateObject("DTS.Package")
> > oPkg.LoadFromSQLServer("WIN2000", , ,
> > DTS.DTSSQLServerStorageFlags.DTSSQLStgFlag_UseTrustedConnection, , , ,
> > "Import DPCK")
> > oPkg.Execute()
> > oPkg.UnInitialize()
> > oPkg = Nothing
> >
> > Then we switched to the different account, and I cannot execute packages
> > anymore. I tried all accounts, including thos that have full access and
> > rights. If I use
> >
> > DTSSQLStgFlag_UseTrustedConnection
> >
> > I get this error
> >
> > System.Runtime.InteropServices.COMException (0x80040E4D): Login failed
for
> > user 'NT AUTHORITY\NETWORK SERVICE'. at
> > DTS._Package.LoadFromSQLServer(String ServerName, String ServerUserName,
> > String ServerPassword, DTSSQLServerStorageFlags Flags, String
> > PackagePassword, String PackageGuid, String PackageVersionGuid, String
> > PackageName, Object& pVarPersistStgOfHost) at
> > MakeXeroxFiles.MakeFiles.btnMake_Click(Object sender, EventArgs e)
> >
> > If I use the flag DTSSQLStgFlag_Default and specify user name and
> password,
> > I still get similar message:
> >
> > System.Runtime.InteropServices.COMException (0x80040E4D): Login failed
for
> > user 'SPECIALTY\pafo'. at DTS._Package.LoadFromSQLServer(String
> ServerName,
> > String ServerUserName, String ServerPassword, DTSSQLServerStorageFlags
> > Flags, String PackagePassword, String PackageGuid, String
> > PackageVersionGuid, String PackageName, Object& pVarPersistStgOfHost) at
> > MakeXeroxFiles.MakeFiles.btnMake_Click(Object sender, EventArgs e)
> >
> > If I add <identity impersonate="true" /> to the Web.config, I don't get
an
> > error anymore, but the package doesn't execute either.
> >
> > What can I do? I would appreciate your help very much.
> >
> > Thank you,
> >
> >
> > --
> > Peter Afonin
> >
> >
>
>



Relevant Pages

  • Re: Cannot execute DTS package
    ... >> Our SQL server used to run under System account, ... >> String ServerPassword, DTSSQLServerStorageFlags Flags, String ... >> PackagePassword, String PackageGuid, String PackageVersionGuid, String ... >> String ServerUserName, String ServerPassword, DTSSQLServerStorageFlags ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • Re: Two problems sending an E-mail for Outlook 2007 and VB 2005
    ... I'd suspect that you aren't getting a valid Account object, I've used SendUsingAccount with valid Account objects with no problems, although reading that object property only works right in a Send event. ... Dim WordContent As String ... Dim SendPersonName As String ...
    (microsoft.public.outlook.program_vba)
  • Re: Testing Platforms
    ... I think that most of us would just run a separate account on the main ... String "q" ... programming changes relating to data entry screens, report formatting, ... we are current on our support contract) has run hot and cold. ...
    (comp.databases.pick)
  • Re: using multiple locations (network drives) for recorded TV
    ... I have a linksys MCX, ... MCE only needs to continue to record to the standard ... > understand holds more than one string. ... > research I found implied you need to do this for the SYSTEM account not ...
    (microsoft.public.windows.mediacenter)
  • Re: Testing Platforms
    ... I think that most of us would just run a separate account on the main ... String  "q" ... programming changes relating to data entry screens, report formatting, ... we are current on our support contract) has run hot and cold. ...
    (comp.databases.pick)

Quantcast