الفريق العربي للبرمجةأرشيف المنتديات · 2000 – 2023
نسخة أرشيفية للقراءة فقط — التسجيل والمشاركة مغلقان، والمحتوى محفوظ كما كان.

Linux Boot up

مغلق
بدأه GreenHat في 13 يوليو 2004 · 0 رد · 810 مشاهدة · في نظام تشغيل Unix & Linux
مشاركة: واتساب X فيسبوك تيليجرام
#1

Boot up

5.1 Steps

BIOS loads first stage boot loader from the first sector of available disks (floppy, hard drive, cd-rom, etc.)

First stage boot loader then loads the second stage boot loader.

Second stage boot loader allows user to choose what kernel to boot.

Chosen kernel then booted and devices are initialized.

Kernel then executes init process.

Init starts services according to /etc/inittab:

rc.sysinit - System initialization scripts

Mounts /proc.

Configures Kernel parameters (via sysctl)

Configures system clock.

Sets host name.

Initialize USB and HID devices.

Configure PnP.

Determines module dependencies.

Setup any RAID devices.

Performs file system checks if needed.

Mounts file systems.

Starts user quotas.

Enable process accounting.

Starts swap.

Initialize serial ports.

Dump boot messages to /var/log/dmesg

Much more....

rc - Configures services based on runlevel

Stop services that begin with "K" in /etc/rcX.d where X is the runlevel.

Start services that begin with "S" in /etc/rcX.d where X is the runlevel.

rc.local - Configures any system specific information (deprecated).

Other, runlevel specific services started according to /etc/inittab.

mingetty (except for runlevel 1).

xdm (runlevel 5).

5.2 /etc/inittab

This file contains information needed by init to configure the system. Entries in the file have a specific format:

id:runlevel:style:command to run

id - A 1-4 character field the creates a unique identifier for the entry.

runlevel - Specifies the runlevel(s) that the entry applies to.

style - Specifies how the command is executed.

respawn - Process is restarted if it ever dies.

wait - Process is started once when the specified runlevel is entered. Init will wait for it to finish before proceeding.

once - Process will be executed once when the specified runlevel is entered.

boot - Process will be executed during system boot (runlevel field is ignored).

bootwait - Same as boot, except init will wait for it to complete before continuing.

initdefault - Specifies default run level (command field ignored).

sysinit - Process executed during boot before any boot or bootwait entries.

powerwait - Process executed when power goes down. Init waits for it to complete.

powerfail - Same as powerwait, except init doesn't wait for it to complete.

powerokwait - Executed when power is restored. Init waits for it to complete.

powerfailnow - Executed when battery on UPS is almost dead.

ctrlaltdel - Process executed when init receives SIGINT signal (CTRL+ALT+DEL was pressed).

command - Specifies process to execute.

5.3 Viewing boot up information.

Boot information displayed during boot up is stored in /var/log/dmesg.

Use 'dmesg' command to view.

5.4 Run Levels

0 - Halt (Don't set default runlevel to this!)

1 - Single User mode

2 - Multi-user mode without NFS

3 - Full multi-user mode

4 - Unused

5 - X11 (with networking)

6 - Reboot (Don't set default runlevel to this!)

5.5 Default Run Levels

Workstation/Laptop = 5

Server = 3

Custom with X = 5

Custom w/o X = 3

post-45-1089744924_thumb.jpg

هذا الموضوع مغلق.

مواضيع مشابهة