系統管理
1752815 會員
6273 線上
108789 解決方案
發表新文章

怎樣整合到chkconfig

 
watermelonyu
教授

怎樣整合到chkconfig

# chkconfig --list可以看到下列的output,所以可以利用on ,off來enable or disable 該script的運作與否

dc_client 0:off 1:off 2:off 3:off 4:off 5:off 6:off

mdmonitor 0:off 1:off 2:on 3:on 4:on 5:on 6:off

network 0:off 1:off 2:on 3:on 4:on 5:on 6:off

crond 0:off 1:off 2:on 3:on 4:on 5:on 6:off

apmd 0:off 1:off 2:on 3:on 4:on 5:on 6:off





我自己也寫了一個start script放在rc4.d and rc5.d

我想把它辦法整合到chkconfig 裡面,做得到嗎?怎樣做?

# ls -al |grep joey

lrwxrwxrwx 1 root root 20 May 5 17:21 S96joey -> ../init.d/joey

# cd ../rc5.d

# ls -al |grep joey

lrwxrwxrwx 1 root root 20 May 5 20:02 S96joey -> ../init.d/joey
2則回覆 2
watermelonyu
教授

怎樣整合到chkconfig

你當然可以把自己的 service 加進去, 只要用



#chkconfig --add joey



就可以了, 當然, 再用 chkconfig 檢查一次自己加的 service 有沒有在 list 裏面, 有需要的話再改執行的 run level

watermelonyu
教授

怎樣整合到chkconfig

那是不是我將

chkconfig --level 12345 joey off掉之後

在rcX.d 的動作全部不會執行囉