Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
所以我在 /etc/rc3.d 中,我想启动所有的“S”脚本并杀死所有的“K”脚本。我正在尝试# ./S* start,但没有看到 start 参数。如何调整我的语法以允许我将开始传递给 Ss 并将停止传递给 Ks?
# ./S* start
不得不提最直接的方式:切换到runlevel 2。
telinit 2
如果出于某种原因您不想这样做,则可以显式循环遍历脚本。
for K in /etc/rc2.d/K*; do "$K" stop; done for S in /etc/rc2.d/S*; do "$S" start; done