I recently was doing some development on my local machine and needed to pull data from a linked server. I set up the linked server and everything was working great. Executing queries to pull the data to my machine was fine, but a problem arose when I needed to execute a stored procedure from the other server.
First of all, to call a stored procedure from a linked server you need to use a four part qualifier.
EXEC ServerName.DatabaseName.Owner.StoredProcedure PARAMETERS
Using AdventureWorks2008 on the server MYPROD would look like this:
EXEC MYPROD.AdventureWorks2008.dbo. uspGetBillOfMaterials 1, ‘01/01/2008’
The error I ran into when I tried to execute the stored procedure was this: ‘Server ‘SERVERNAME’ is not configured for RPC.’ There could be a couple of issues with this. The easiest one to check is to see if the linked server was configured to allow RPC. If you open the linked server properties and go to the Server Options tab, there is an option for RPC and RPC Out. RPC Out needs to be set to True in order to execute a stored procedure that is stored on the linked server. RPC allows stored procedure call from the linked server whereas RPC Out allows stored procedure calls to go out to the linked server.
The other thing to check is if the server is even configured to allow RPC. To check this run sp_helpserver and it will display a list of settings in the STATUS column. If you do not see RPC, RPC Out listed there they are not enabled and setting your linked server up correctly won’t help the situation any. If they are not listed and you would like to enable them the following commands will do that. Again, using our MYPROD server example:
exec sp_serveroption @server=’Linkserver_name’, @optname=’rpc’, @optvalue=’TRUE’;
exec sp_serveroption @server=’Linkserver_name’, @optname=’rpc out’, @optvalue=’TRUE’;
From now on, as long as everything is configured correctly, you will be able to execute stored procedures to and from linked servers.
Reprinted from :
http://www.bradleyschacht.com/server-servername-is-not-configured-for-rpc/
【SQLServer】Server ‘SERVERNAME’ is not configured for RPC
来源:这里教程网
时间:2026-03-02 11:16:44
作者:
编辑推荐:
- 【SQLServer】Server ‘SERVERNAME’ is not configured for RPC03-02
- Sqlserver分析死锁问题03-02
- 【SQLServer】The provider supports the interface03-02
- SQL SERVER中SQL优化03-02
- 台式电脑在没有无线网卡的情况下如何上网03-02
- A significant part of sql server process memory has been paged out03-02
- 国家有关信息化机房定级、选址规定03-02
- 【Case】cannot resolve the collation conflict between "xxx" and "xxx"03-02
下一篇:
相关推荐
-
雷神推出 MIX PRO II 迷你主机:基于 Ultra 200H,玻璃上盖 + ARGB 灯效
2 月 9 日消息,雷神 (THUNDEROBOT) 现已宣布推出基于英
-
制造商 Musnap 推出彩色墨水屏电纸书 Ocean C:支持手写笔、第三方安卓应用
2 月 10 日消息,制造商 Musnap 现已在海外推出一款 Oce
热文推荐
- 【SQLServer】Server ‘SERVERNAME’ is not configured for RPC
- Sqlserver分析死锁问题
Sqlserver分析死锁问题
26-03-02 - 台式电脑在没有无线网卡的情况下如何上网
台式电脑在没有无线网卡的情况下如何上网
26-03-02 - A significant part of sql server process memory has been paged out
- 国家有关信息化机房定级、选址规定
国家有关信息化机房定级、选址规定
26-03-02 - 【Case】cannot resolve the collation conflict between "xxx" and "xxx"
- 出现操作系统错误 1330(此帐户的密码已过期。)
出现操作系统错误 1330(此帐户的密码已过期。)
26-03-02 - SQL Server Report Service网页页面显示英文问题
SQL Server Report Service网页页面显示英文问题
26-03-02 - 通过链接服务器把一台服务器的数据insert到另一台服务器上
通过链接服务器把一台服务器的数据insert到另一台服务器上
26-03-02 - 【SQLServer】SQLServer使数据库脱机offline
【SQLServer】SQLServer使数据库脱机offline
26-03-02
