命令行更改服务启动方式
来源:百度文库 编辑:神马文学网 时间:2024/04/29 15:41:41
大家都知道开启和停止服务要用命令net start servicename和net stop servicename吧
但是怎么才能在命令行下设置一个服务的启动状态呢?比如说禁用它?
系统自带的东东里可能有,但是我没研究过,我只说pstools里带的psservice命令
在命令行下输入psservice/?命令可以看到使用说明:
Usage: psservice [\\Computer [-u Username [-p Password]]]
Cmd is one of the following:
query Queries the status of a service
config Queries the configuration
start Starts a service
stop Stops a service
restart Stops and then restarts a service
pause Pauses a service
cont Continues a paused service
depend Enumerates the services that depend on the one specified
find Searches for an instance of a service on the network
这是psservice命令的参数列表,但是今天我们用到的是这个列表里没有出现的一个参数: setconfig
比如说要禁用Uninterruptible Power Supply服务(UPS),我们知道它的服务名称是UPS,那么只要输入以下命令:
psservice setconfig ups disabled
就可以把这个服务禁用掉了
其中的disabled可以换成auto和demand,分别是对应自动和手动
但是怎么才能在命令行下设置一个服务的启动状态呢?比如说禁用它?
系统自带的东东里可能有,但是我没研究过,我只说pstools里带的psservice命令
在命令行下输入psservice/?命令可以看到使用说明:
Usage: psservice [\\Computer [-u Username [-p Password]]]
Cmd is one of the following:
query Queries the status of a service
config Queries the configuration
start Starts a service
stop Stops a service
restart Stops and then restarts a service
pause Pauses a service
cont Continues a paused service
depend Enumerates the services that depend on the one specified
find Searches for an instance of a service on the network
这是psservice命令的参数列表,但是今天我们用到的是这个列表里没有出现的一个参数: setconfig
比如说要禁用Uninterruptible Power Supply服务(UPS),我们知道它的服务名称是UPS,那么只要输入以下命令:
psservice setconfig ups disabled
就可以把这个服务禁用掉了
其中的disabled可以换成auto和demand,分别是对应自动和手动
命令行更改服务启动方式
命令行注册服务
Windows终端服务和远程桌面Web方式访问及端口更改方法
怎样从Windows命令行启动MySQL__MySql_eNet硅谷动力
命令行删除windows系统服务办法一:
命令行删除windows系统服务办法一:
命令行
Workstation服务启动故障
TOMCAT5在WINDOWS下的系统服务相关的命令行
命令行下防火墙的配置和ssh服务安装配置
TOMCAT5在WINDOWS下的系统服务相关的命令行
命令行方式下访问控制面板项目的方法
IIS 服务不能自动启动
首先要启动rstatd服务
首先要启动rstatd服务
Linux ftp服务启动方法
诺基亚拟效仿LG巧克力更改手机命名方式
Google主动更改第三方视频收录方式
更改屏幕保护程序关联方式、黑屏的几个原因
更改屏幕保护程序关联方式、黑屏的几个原因
BIOS设置USB方式启动
CMD命令行高级教程[收集整理] - DOS讨论区 - 启动盘制作技术区 - 无忧启动论坛...
CMD命令行高级教程[收集整理] - DOS讨论区 - 启动盘制作技术区 - 无忧启动论坛...
中国的3G服务有望明年启动