2

I have a problem on my servers sitting on different domains.

I created a linked server that executes successfully and I can list the catalogue but when I schedule a job to execute I get this error:

Access to the remote server is denied because the current security context is not trusted.

How can I resolve this?

1
  • How did you define the security option from the linked server SECURITY option out of the four options that should be there? Commented Nov 12, 2015 at 7:40

1 Answer 1

1

Condsiderations for linked server security options in SQL Server

(Two things to mention for typical simple configurations)


  • If you have the option set to Be made using the login's current security context then . . .
    • ensure that the security principal (and context) that the job will RUN AS from the SQL Agentjob also has appropriate access to any of the linked server DB(s) which the job will need to access for it's queries, etc.
    • if the security principal is a local SQL login and not a domain or trusted domain account, then be sure that the local SQL account is created with a matching SID on both the linked server SQL Server instance and the SQL Server instance where the job is using the linked server from.

  • If you have the option set to Be made using the security context: then . . .
    • ensure the local SQL login security principal is created with a matching SID on both the linked server SQL Server instance and the SQL Server instance where the job is using the linked server from.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.