The Boot Process, INIT and Runlevel Programs, and Shutdown Flashcards
This is the order of the boot process in a Linux machine.
BIOS, MBR, GRUB, Kernel, INIT, Runlevel
The function of BIOS is this.
Searches, loads, and executes the boot loader program
A master boot record’s primary function is this.
It loads and executes the GRUB boot loader.
GRUB stands for…
Grand Unified Bootloader
GRUB can be edited through this file.
/boot/grub/grub.conf
GRUB chooses and loads what?
The kernel.
The kernel starts up this program.
/sbin/init
What are the runlevels in a regular Linux system and their attributes?
0 - halt (shutdown) 1 - single user mode w/ no networking 2 - multiuser mode w/ no NFS 3 - Full multiuser mode in command line 4 - Unused 5 - Full multiuser mode in GUI 6 - Restart
INIT turns over control to…
Runlevel scripts
Depending on your default init level setting, the system will execute the programs from one of the following directories
Run level 0 – /etc/rc.d/rc0.d/ Run level 1 – /etc/rc.d/rc1.d/ Run level 2 – /etc/rc.d/rc2.d/ Run level 3 – /etc/rc.d/rc3.d/ Run level 4 – /etc/rc.d/rc4.d/ Run level 5 – /etc/rc.d/rc5.d/ Run level 6 – /etc/rc.d/rc6.d/
All startup files are found in this folder.
/etc/init.d
How do you stop or start a service?
service NAME start/stop
How can you determine whether a service will be on or off the next time the computer starts?
chkconfig –list NAME will show you what runlevel the service starts at.
chkconfig NAME on/off will start or stop a service the next time the computer starts.
How do you properly shut down a Linux machine from the command prompt?
init 0
shutdown -h
shutdown -h now
How can you delay a shutdown for 10 minutes?
shutdown -h +10