最終更新:2021-02-15 (月) 05:01:28 (1437d)
chkconfig
Top / chkconfig
chkconfig --list chkconfig httpd on
メモ
- CentOS 6まで
- CentOS 7はsystemd(systemctl)
- systemctl enable name.service
- systemctl disable? name.service
設定ディレクトリ
追加
- chkconfig --add
動作
- スクリプトをchkconfigで登録すると、/etc/rc[ランレベル].d/ 配下へ、/etc/init.d/へおいたスクリプトのシンボリックリンクが作成されます
- Linux/etc/rc0.d?
- Linux/etc/rc1.d?
- Linux/etc/rc2.d?
- Linux/etc/rc3.d?
- Linux/etc/rc4.d?
- Linux/etc/rc5.d?
- Linux/etc/rc6.d?
サービスの操作
Ubuntuに入ってない場合の代替
systemctlへの転送 (CentOS 7とか)
# chkconfig httpd on 情報:'systemctl enable httpd.service'へ転送しています。 ln -s '/usr/lib/systemd/system/httpd.service' '/etc/systemd/system/multi-user.target.wants/httpd.service'