Trying to use linked server for the first time and having some problems.
I have 2 servers "ServerA" and "ServerB". From ServerA I want to be able to
access data from ServerB. I ran the following on ServerA
USE master
GO
EXEC sp_addlinkedserver 'ServerB', N'SQL Server'
GO
Then I ran the following SQL on ServerA
SELECT * FROM SERVERB.DBNAME.dbo.TABLENAME
And I get the following message:
Server: Msg 18456, Level 14, State 1, Line 1
Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'.
Can someone tell me how I can get past this problem?
Thanks in advance!What security type are you using?
Standard or Windows?
Your sp_addlinkedserver will default to use "current security credentials"
to authenticate to serverb.
You should try adding your linked server passing an SQL
authentication/Valid Windows account depending on your security type.
e.g. sp_addlinkedsrvlogin ServerB ,false ,null , SQLUSER, USERPASSWORD"
Immy
"TJTODD" <Thxomasx.Toddy@.Siemensx.com> wrote in message
news:ed748v7TEHA.3420@.TK2MSFTNGP09.phx.gbl...
> Trying to use linked server for the first time and having some problems.
> I have 2 servers "ServerA" and "ServerB". From ServerA I want to be
able to
> access data from ServerB. I ran the following on ServerA
> USE master
> GO
> EXEC sp_addlinkedserver 'ServerB', N'SQL Server'
> GO
> Then I ran the following SQL on ServerA
> SELECT * FROM SERVERB.DBNAME.dbo.TABLENAME
> And I get the following message:
> Server: Msg 18456, Level 14, State 1, Line 1
> Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'.
> Can someone tell me how I can get past this problem?
> Thanks in advance!
>
>|||Thanks Immy...sp_addlinkedsrvlogin was exactly what I needed!
"Immy" <imtiaz_ullah@.hotmail.com> wrote in message
news:u8xksz7TEHA.1472@.TK2MSFTNGP12.phx.gbl...
> What security type are you using?
> Standard or Windows?
> Your sp_addlinkedserver will default to use "current security
credentials"
> to authenticate to serverb.
> You should try adding your linked server passing an SQL
> authentication/Valid Windows account depending on your security type.
> e.g. sp_addlinkedsrvlogin ServerB ,false ,null , SQLUSER, USERPASSWORD"
> Immy
> "TJTODD" <Thxomasx.Toddy@.Siemensx.com> wrote in message
> news:ed748v7TEHA.3420@.TK2MSFTNGP09.phx.gbl...
problems.[vbcol=seagreen]
> able to
>
No comments:
Post a Comment