Show Table of Contents
F.2.5. ジョブの定義
デフォルト設定の場合、今まで init デーモンは sysvinit パッケージで提供されていました。この場合、システムが起動すると init デーモンにより
/etc/inittab スクリプトが実行され各ランレベルで定義されているシステムプロセスが開始されていました。今後、デフォルト設定では upstart パッケージで提供されるイベント駆動の init デーモンが使用されるようになります。特定の イベント が発生すると、init デーモンは /etc/event.d ディレクトリーに格納されている ジョブ を処理するようになります。init はこのようなイベントでシステムの起動を認識することになります。
各ジョブは通常、プログラムを1つ指定し、そのプログラムを開始/停止する為の init を引き起こすイベントを指定します。一部の ジョブは タスク として構築されており、これはアクションを実行して、その後は他のイベントがジョブを再度引き起こすまで停止します。その他のジョブは サービス として構築されていて、これは他のイベント (または ユーザー) がそれを止めるまで init が実行を続けます。
例えば、
/etc/events.d/tty2 ジョブは、システムの開始時からシャットダウンまで、または別のイベント (ランレベルの変更など) がジョブを停止するまで、tty2 上の仮想ターミナルを維持するサービスです。このジョブは、ジョブが実行中に予想外に停止した場合に init が仮想ターミナルを再開するように構築されています。
# tty2 - getty # # This service maintains a getty on tty2 from the point the system is # started until it is shut down again. start on stopped rc2 start on stopped rc3 start on stopped rc4 start on started prefdm stop on runlevel 0 stop on runlevel 1 stop on runlevel 6 respawn exec /sbin/mingetty tty2

Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.