diff options
Diffstat (limited to 'topics/boot.txt')
-rw-r--r-- | topics/boot.txt | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/topics/boot.txt b/topics/boot.txt new file mode 100644 index 0000000..3d03935 --- /dev/null +++ b/topics/boot.txt @@ -0,0 +1,63 @@ +BIOS + firmware image on ROM chip + ROM is either a dual in-line package or plastic leaded chip carrier + POST + initializes HW, e.g. memory, video card, keyboard, USB hosts + finds a bootable device (HDD, ODD, USB flash drive, etc.) + reads MBR and executes stage 1 boot loader +boot loader, e.g. GNU GRUB + may offer user OS list and/or some other interactive IX (e.g. CLI) + will load a kernel, e.g. Linux, into memory and begin its execution +Linux + initializes memory, interrupts, etc. + may mount initial ramdisk + loads and schedules init and kernel threads +initial ramdisk + finds root filesystem + loads required drivers and runs required utilities to mount root fs + e.g. for RAID, LVM2, ext4 + checks for a suspend-to-disk virtual memory image and resumes if found + look at initrd on Debian: + $ gunzip -c /boot/initrd.img-`uname -r` | cpio --extract + warning: will extract to current working directory +init + multiple implementations + GNU/Linux: + System V-style init + systemd + Upstart + runit + OpenRC + Initng + BSDs: + own lightweight and modular daemon + BusyBox/Linux: + own lightweight daemon + SysV-style: + runlevels + 0 - halt + 1 - single-user mode + 2-5 - multi-user mode + 6 reboot + reads /etc/inittab + default runlevel + actions of runlevels + Ctrl+Alt+Del behavior + programs to control TTYs (e.g. /sbin/getty) + etc. + runs initialization scripts + `/etc/rcN.d/* start`, where N = runlevel + links to /etc/init.d/* + cron, servers, ACPI daemon, Network Manager, DMs, etc. +getty + prints /etc/issue, unless disabled + prompts for username + calls /bin/login +login + prompts for password + loads user environment + starts user's default shell (e.g. /bin/bash) +display manager + starts X.org server + prompts for user name and password + starts window manager and desktop shell |