Home > Database > Mysql Tutorial > body text

SQL Server SQL Agent服务使用教程小结

WBOY
Release: 2016-06-07 17:57:12
Original
1494 people have browsed it

SQL Server SQL Agent服务使用教程小结

1.在查询分析器理启动或停止SQL Agent服务
  启动
  use master
  go
  xp_cmdshell 'net start SQLSERVERAGENT'
  停止
  use master
  go
  xp_cmdshell 'net stop SQLSERVERAGENT'
  将服务的启动从手工方式改为自动启动方式
  exec xp_cmdshell 'scm -Action 7 -Service mssqlserver -SvcStartType 2'
  直接用命令行执行引号内的内容也可以。
  2、启动不正常原因和处理
  表面上看SQL Server agent 服务启动正常,但在查看作业的属性与作业历史记录时都出现如下错误:
  错误14258:当SQLServerAgent正在启动时,无法执行此操作。请稍后再试。
  可能原因:
  选择了"使用 Windows NT 纤程",具体原因不明。
  解决方法:
  企业管理器--右键SQL实例--属性--处理器--取消选择"使用 Windows NT 纤程"
  然后重新启动sql服务
  修改了系统密码
  解决方法:
  a. 我的电脑--控制面板--管理工具--服务--右键 MS SQLServer--属性--登陆--登陆身份--选择"本地系统帐户"
  或:
  b.我的电脑--控制面板--管理工具--服务--右键 MS SQLServer--属性--登陆--登陆身份--选择"此帐户"--选择 administrator ,密码和确认密码中输入你的administrator密码.
  两者的区别:
  选择第一种方式,以后修改了administrator密码,不用再调整(但要求登陆操作系统的是系统管理员)
  数据库非法DOWN机出现故障
  解决方法:
  用安装光盘重新安装,然后选择‘高级选项'—‘重建',然后一路下去……
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!