SQL Server2008 xp_cmdshell啟用

1. 查看系统数据库参数配置: select * from sys.configurations where name='xp_cmdshell'

 

修改系统数据库参数:   

  语法格式:
     sp_configure [ @configname= ] 'hadoop connectivity',  
             [ @configvalue = ] { 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 }  [;]  
    RECONFIGURE  [;] 

2.通过命令方式,启动xp_cmdshell:

sp_configure 'show advanced options',1
reconfigure
go
sp_configure 'xp_cmdshell',1
reconfigure
go

 

注:sp_configure具体使用参考:https://msdn.microsoft.com/zh-cn/library/ms188787.aspx

 

posted @ 2019-04-10 10:25  A大洋芋  阅读(457)  评论(0编辑  收藏  举报