分析自己的linux启动代码

来源:互联网 发布:手机网站 源码 编辑:程序博客网 时间:2024/04/28 04:56

1,rcS

#!/bin/sh## rcSCall all S??* scripts in /etc/rcS.d in#numerical/alphabetical order.## Version:@(#)/etc/init.d/rcS  2.76  19-Apr-1999  miquels@cistron.nl#PATH=/sbin:/bin:/usr/sbin:/usr/binrunlevel=Sprevlevel=Numask 022export PATH runlevel prevlevel#挂载fstab下的所有选项/bin/mount -a#加载模块/sbin/udevd --daemon#needed for telnet to work properly/bin/mkdir /dev/pts/bin/mount n /dev/pts -t devpts#Make sure proc is mounted#[ -d "/proc/1" ] || mount /procecho -e '\000\000\000\000' > /proc/sys/kernel/hotplug##See if system needs to be setup. This is ONLY meant to#be used for the initial setup after a fresh installation!##if [ -x /sbin/unconfigured.sh ]#then#  /sbin/unconfigured.sh#fi##Source defaults.##. /etc/default/rcS##Trap CTRL-C &c only in this shell so we can interrupt subprocesses.#检测中断信号量,忽略?trap ":" INT QUIT TSTP##Call all parts in order.#执行下一脚本exec /etc/init.d/rc S##For compatibility, run the files in /etc/rc.boot too.##[ -d /etc/rc.boot ] && run-parts /etc/rc.boot##Finish setup if needed. The comment above about#/sbin/unconfigured.sh applies here as well!##if [ -x /sbin/setup.sh ]#then#  /sbin/setup.sh#fi


0 0
原创粉丝点击