主页 > 知识库 > SQL Server 2005的cmd_shell组件的开启方法

SQL Server 2005的cmd_shell组件的开启方法

热门标签:沧州营销外呼系统软件 创业电销机器人 浙江地图标注 沈阳智能外呼系统代理 九鹿林外呼系统怎么收费 海南自动外呼系统价格 松原导航地图标注 电销机器人虚拟号码 舞钢市地图标注app

SQL Server中的cmd_shell组件功能强大,几乎可通过该组建实现Windows系统的所有功能,正因此,这个组件也是SQL Server的最大安全隐患。SQL Server 2000中这个组件是默认开启的,而SQL Server 2005中这个组件默认作为此服务器安全配置的一部分而被关闭。有时我们需要用到该组件,开启此组件的相关语句如下:

复制代码 代码如下:

--To allow advanced options to be changed.

EXEC sp_configure 'show advanced options', 1
GO

--To update the currently configured value for advanced options.
RECONFIGURE
GO -- To enable the feature.

EXEC sp_configure 'xp_cmdshell', 1
GO
--To update the currently configured value for this feature.
RECONFIGURE
GO


为了保证数据库服务器的安全,建议在使用完毕后关闭该组件,关闭该组件的相关语句如下:

复制代码 代码如下:

--To allow advanced options to be changed.

EXEC sp_configure 'show advanced options', 1
GO

--To update the currently configured value for advanced options.
RECONFIGURE
GO -- To enable the feature.

EXEC sp_configure 'xp_cmdshell', 0
GO
--To update the currently configured value for this feature.
RECONFIGURE
GO

标签:咸宁 台湾 宝鸡 商洛 海口 公主岭 日喀则 西藏

巨人网络通讯声明:本文标题《SQL Server 2005的cmd_shell组件的开启方法》,本文关键词  SQL,Server,2005,的,cmd,shell,;如发现本文内容存在版权问题,烦请提供相关信息告之我们,我们将及时沟通与处理。本站内容系统采集于网络,涉及言论、版权与本站无关。
  • 相关文章
  • 下面列出与本文章《SQL Server 2005的cmd_shell组件的开启方法》相关的同类信息!
  • 本页收集关于SQL Server 2005的cmd_shell组件的开启方法的相关信息资讯供网民参考!
  • 推荐文章