有木有一款Upstart下类似sysv-rc-conf的工具啊!
-
- 帖子: 60
- 注册时间: 2013-02-01 1:39
有木有一款Upstart下类似sysv-rc-conf的工具啊!
RT。sysv-rc-conf 真的很方便很强大。但是最新Ubuntu都是upstart,用不了。有木有类似的好用的工具管理开机启动?
-
- 论坛版主
- 帖子: 18279
- 注册时间: 2009-08-04 16:33
Re: 有木有一款Upstart下类似sysv-rc-conf的工具啊!
1. Upstart / Sysinit (Runlevel) 可以同時並存
viewtopic.php?p=3151212#p3151212
2. 如果是 15.10 可以從 開機選單 選擇 Upstart
3. 也可以改變開機選單 預設為 Upstart 讓 Systemd 變成 選項
https://wiki.ubuntu.com/SystemdForUpsta ... it_systems
viewtopic.php?p=3151212#p3151212
2. 如果是 15.10 可以從 開機選單 選擇 Upstart
3. 也可以改變開機選單 預設為 Upstart 讓 Systemd 變成 選項
https://wiki.ubuntu.com/SystemdForUpsta ... it_systems
-
- 帖子: 60
- 注册时间: 2013-02-01 1:39
Re: 有木有一款Upstart下类似sysv-rc-conf的工具啊!
谢谢讲解,poloshiao 写了:1. Upstart / Sysinit (Runlevel) 可以同時並存
viewtopic.php?p=3151212#p3151212
2. 如果是 15.10 可以從 開機選單 選擇 Upstart
3. 也可以改變開機選單 預設為 Upstart 讓 Systemd 變成 選項
https://wiki.ubuntu.com/SystemdForUpsta ... it_systems
认真读完了https://wiki.ubuntu.com/SystemdForUpstartUsers这篇文章,又看了
浅析 Linux 初始化 init 系统,第 3 部分: Systemd
对ubuntu linux启动方式有了深一步了解,
systemd的启动服务脚本都在/lib/systemd/system/下,
Upstart的启动在/etc/init/下
sysvinit在/etc/init.d/,由rcX.d/里头链接过来。
下面这个对照表很有用。
Sysvinit 命令 Systemd 命令 备注
service foo start systemctl start foo.service 用来启动一个服务 (并不会重启现有的)
service foo stop systemctl stop foo.service 用来停止一个服务 (并不会重启现有的)。
service foo restart systemctl restart foo.service 用来停止并启动一个服务。
service foo reload systemctl reload foo.service 当支持时,重新装载配置文件而不中断等待操作。
service foo condrestart systemctl condrestart foo.service 如果服务正在运行那么重启它。
service foo status systemctl status foo.service 汇报服务是否正在运行。
ls /etc/rc.d/init.d/ systemctl list-unit-files --type=service 用来列出可以启动或停止的服务列表。
chkconfig foo on systemctl enable foo.service 在下次启动时或满足其他触发条件时设置服务为启用
chkconfig foo off systemctl disable foo.service 在下次启动时或满足其他触发条件时设置服务为禁用
chkconfig foo systemctl is-enabled foo.service 用来检查一个服务在当前环境下被配置为启用还是禁用。
chkconfig –list systemctl list-unit-files --type=service 输出在各个运行级别下服务的启用和禁用情况
chkconfig foo –list ls /etc/systemd/system/*.wants/foo.service 用来列出该服务在哪些运行级别下启用和禁用。
chkconfig foo –add systemctl daemon-reload 当您创建新服务文件或者变更设置时使用。
telinit 3 systemctl isolate multi-user.target (OR systemctl isolate runlevel3.target OR telinit 3) 改变至多用户运行级别。