Re: bcp error
From: John (John_at_discussions.microsoft.com)
Date: 01/14/05
- Next message: Kevin McDonnell [MSFT]: "RE: SQL Server login with hostname masking"
- Previous message: Andrew J. Kelly: "Re: bcp error"
- In reply to: Andrew J. Kelly: "Re: bcp error"
- Next in thread: Andrew J. Kelly: "Re: bcp error"
- Reply: Andrew J. Kelly: "Re: bcp error"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Fri, 14 Jan 2005 13:43:05 -0800
I executed the following:
xp_sqlagent_proxy_account n'get'
It returned an account. I checked the account and it was a member of the
sysadmin role.
To me, it seems like it should be working.
"Andrew J. Kelly" wrote:
> Whether it is a job or not still has the requirement of who is trying to
> execute xp_cmdshell will determine what account gets used. IN SQL 2000 if
> that user is a member of the sa role it will use the account that SQL Agent
> is running under. If not it will attempt to use the account that is set for
> the Proxy account of SQL Agent. The proxy account most likely does not have
> the right permissions. From BOL under xp_cmdshell:
>
> When xp_cmdshell is invoked by a user who is a member of the sysadmin fixed
> server role, xp_cmdshell will be executed under the security context in
> which the SQL Server service is running. When the user is not a member of
> the sysadmin group, xp_cmdshell will impersonate the SQL Server Agent proxy
> account, which is specified using xp_sqlagent_proxy_account. If the proxy
> account is not available, xp_cmdshell will fail. This is true only for
> Microsoft® Windows NT® 4.0 and Windows 2000. On Windows 9.x, there is no
> impersonation and xp_cmdshell is always executed under the security context
> of the Windows 9.x user who started SQL Server.
>
> --
> Andrew J. Kelly SQL MVP
>
>
> "John" <John@discussions.microsoft.com> wrote in message
> news:6C2F8E62-E43B-49AD-8815-C37A56A2FA6E@microsoft.com...
> >I don't know if this helps answer your question, but it does not run as a
> > job. It is running through a stored procedure. DBO is the ower of the
> > stored procedure.
> >
> > "Andrew J. Kelly" wrote:
> >
> >> Who is the owner of the job? If it is not sa then you will use the
> >> account
> >> setup for the Proxy. See this:
> >> http://www.support.microsoft.com/?id=269074
> >>
> >> --
> >> Andrew J. Kelly SQL MVP
> >>
> >>
> >> "John" <John@discussions.microsoft.com> wrote in message
> >> news:213D9833-AFC6-4122-8BCC-DFEB1BAF945D@microsoft.com...
> >> >I am getting an error that I can't open the host file when running bcp
> >> > through a tsql statement. When I set the path to a local drive on the
> >> > sql
> >> > server the utility runs. However, when I set the path to a unc path
> >> > that
> >> > the
> >> > server and service account both have permission to then it won't run.
> >> >
> >> > Any ideas on what I should try to fix this problem?
> >>
> >>
> >>
>
>
>
- Next message: Kevin McDonnell [MSFT]: "RE: SQL Server login with hostname masking"
- Previous message: Andrew J. Kelly: "Re: bcp error"
- In reply to: Andrew J. Kelly: "Re: bcp error"
- Next in thread: Andrew J. Kelly: "Re: bcp error"
- Reply: Andrew J. Kelly: "Re: bcp error"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|