Centos7设置服务开机自启动

栏目: 服务器 · 发布时间: 6年前

内容简介:步骤1:查看crond.serivce服务的自启动状态此时crond.serivce的自启动状态为disabled步骤2:开启crond.serivce服务自启动

一、设置crond.serivice服务为开机自启动

步骤1:查看crond.serivce服务的自启动状态

[root@localhost ~]# systemctl is-enabled crond.service
disabled

此时crond.serivce的自启动状态为disabled

步骤2:开启crond.serivce服务自启动

[root@localhost ~]# systemctl enable crond.service
[root@localhost ~]# systemctl is-enabled crond.service
enabled

列出所有的启动文件:

systemctl list-unit-files

列出所有状态为enable的启动文件

systemctl list-unit-files | grep enable

关闭crond.serivce的自启动状态

systemctl disable crond.service

二、开启和关闭crond.service服务

步骤1:查看crond.service的启动状态

systemctl status crond.service

开启crond.service服务命令

systemctl start crond.service

停止crond.service服务命令

systemctl stop crond.service

参考连接:

http://blog.51cto.com/mrxiong2017/2084790


以上所述就是小编给大家介绍的《Centos7设置服务开机自启动》,希望对大家有所帮助,如果大家有任何疑问请给我留言,小编会及时回复大家的。在此也非常感谢大家对 码农网 的支持!

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

Data Structures and Algorithms

Data Structures and Algorithms

Alfred V. Aho、Jeffrey D. Ullman、John E. Hopcroft / Addison Wesley / 1983-1-11 / USD 74.20

The authors' treatment of data structures in Data Structures and Algorithms is unified by an informal notion of "abstract data types," allowing readers to compare different implementations of the same......一起来看看 《Data Structures and Algorithms》 这本书的介绍吧!

Base64 编码/解码
Base64 编码/解码

Base64 编码/解码

XML、JSON 在线转换
XML、JSON 在线转换

在线XML、JSON转换工具

HEX CMYK 转换工具
HEX CMYK 转换工具

HEX CMYK 互转工具