When trying to execute a remote stored procedure through a linked server called "server_name"  the following error is received:

EXEC server_name.mydatabase.dbo.mysproc

Msg 7411, Level 16, State 1, Line 1
Server 'server_name' is not configured for RPC.


The problem is that RPC is not configured for your linked server (is not a default option). You can see the configured settings for the linked servers by executing exec sp_helpserver on the host  server. 


If 'rpc,rpc out' is not in your results (status column), then the linked server is not configured for RPC.

The following code will allow remote procedures calls through the specified linked server:

exec sp_serveroption @server='server_name', @optname='rpc', @optvalue='true'
exec sp_serveroption @server='server_name', @optname='rpc out', @optvalue='true'


EXEC sp_serveroption 'server_name', 'rpc', 'true'
EXEC sp_serveroption 'server_name', 'rpc out', 'true'  

The option ?Rpc? is used to allow remote procedures calls ?from? the linked server. Whereas,  the option ?Rpc Out? is used to allow remote procedure calls ?to? the linked server. 

You can also do this modification from Management Studio by right clicking on the linked server and choosing Properties:   



Tags: rpc

No feedback yet