提示:文章写完后,目录可以自动生成,如何生成可参考右边的帮助文档
一、Linux关闭开机自启服务
chkconfig查看存在的任务
(base) [root@hd01 smartsense-activity]# chkconfig
Note: This output shows SysV services only and does not include native
systemd services. SysV configuration data might be overridden by native
systemd configuration.
If you want to list systemd services use 'systemctl list-unit-files'.
To see services enabled on particular target use
'systemctl list-dependencies [target]'.
ambari-agent 0:off 1:off 2:on 3:on 4:on 5:on 6:off
ambari-server 0:off 1:off 2:off 3:off 4:off 5:off 6:off
hst 0:off 1:off 2:off 3:on 4:on 5:on 6:off
netconsole 0:off 1:off 2:off 3:off 4:off 5:off 6:off
network 0:off 1:off 2:on 3:on 4:on 5:on 6:off
关闭自动启动的任务
systemctl disable hst
二、如果是原生 systemd 服务,则可以使用 systemctl list-unit-files命令查看
查看自动启动任务
systemctl list-unit-files
关闭自动启动
systemctl disable