11.10 chkconfig:管理开机服务
2024-09-08 06:16:25
chkconfig 命令是Redhat系列的Linux系统中的系统服务管理工具,它可以用于查询和更新不同的运行等级下系统服务的启动状态。
chkconfig命令的参数选项及说明
--list 显示不同运行级别下服务的启动状态
--add 添加一个系统服务
--del 删除一个系统服务
--level 指定运行级别
以下是运行级别说明。
0:关机。
1:单用户模式。
2:没有网络的多用户模式。
3:完全的多用户模式。
4:没有使用的级别。
5:图形界面多用户模式。
6:重启。
了解chkconfig原理。
chkconfig 的原理是在 runlevel级别的 /etc/rc.d/rc*.d目录中将对应服务做一个以S或K开头的软链接。
[root@linuxprobe ~]# ll /etc/rc.d/rc3.d/
total 0
lrwxrwxrwx. 1 root root 20 Jan 28 21:13 K50netconsole -> ../init.d/netconsole
lrwxrwxrwx. 1 root root 17 Jan 28 21:13 S10network -> ../init.d/network
下面只对rc3.d目录做实验,chkconfig的--level2345是同时对re2.d、rc3.d、re4.d、rc5.d这4个目录进行操作的。
centos 7 下面使用systemctl list-unit-files 查看自启任务
[root@linuxprobe ~]# systemctl list-unit-files
UNIT FILE STATE
proc-sys-fs-binfmt_misc.automount static
dev-hugepages.mount static
dev-mqueue.mount static
proc-fs-nfsd.mount static
proc-sys-fs-binfmt_misc.mount static
sys-fs-fuse-connections.mount static
sys-kernel-config.mount static
sys-kernel-debug.mount static
tmp.mount disabled
var-lib-nfs-rpc_pipefs.mount static
brandbot.path disabled
systemd-ask-password-console.path static
最新文章
- 理解CSS边框border
- SQL SERVER 2008复制数据库时发生执行SQL Server代理作业错误
- windows7安装GitBash和GitGui
- .NET 3.5 安装错误的四个原因及解决方法
- Zxing兼容2.3等低版本
- DOM查找元素
- POJ 2051
- U3D中IOS平台泛型方法尽少使用
- start apache2 failed in Ubuntu
- 51nod1406 与查询
- AsyncTask简单获取网络图片的例子
- [BEC][hujiang] Lesson02 Unit1:Working life ---Reading
- 想让安卓 APP 如丝般顺滑?
- new Date() iso不支持兼容性问题
- Implement Queue using Stacks 解答
- Java 用Freemarker完美导出word文档(带图片)
- 【NOIP2017 OFO(下)】
- 零基础开发一款微信小程序商城
- mysql索引优化-order/group
- 如何在生产环境禁用swagger
热门文章
- Day01_04_Java标识符命名规范
- Java封装接口统一返回数据模板
- 12- APP接口测试以及接口文档的分析
- 【接口设计】用户积分排行榜功能-Redis实现
- hdu4560 不错的建图,二分最大流
- hdu4720 三角形的外接圆
- 如何在jQuery的Ajax调用后管理一个重定向请求
- Error starting userland proxy: /forwards/expose/port returned unexpected status: 500.
- Log4j讲解
- python模块一之faker模块