Linux+ Guide to Linux Certification Chapter Nine System Initialization.

  • Published on
    15-Jan-2016

  • View
    212

  • Download
    0

Embed Size (px)

Transcript

<ul><li><p>ObjectivesSummarize the major steps necessary to boot a Linux systemConfigure the LILO boot loaderConfigure the GRUB boot loaderDual boot Linux with the Windows operating system using LILO, GRUB, and NTLOADERUnderstand how the init daemon initializes the system at boot time</p></li><li><p>The Boot ProcessPower On Self Test (POST)Initial series of tests run when a computer is powered on to ensure that hardware components are functionalMaster Boot Record (MBR)Small program normally located on the first sector of the first hard disk drive used to define partitions and a boot loaderBoot loaderProgram used to load an operating system</p></li><li><p>The Boot ProcessActive partitionPartition that the MBR points to/bootDirectory that contains the kernel and boot-related filesVmlinuz-The Linux kernel file</p></li><li><p>The Boot ProcessDaemonA Linux system process that provides a certain serviceInit (initialize) daemonThe first process started by the Linux kernelIt is responsible for starting and stopping other daemons</p></li><li><p>The Boot ProcessFigure 9-1: The boot process</p></li><li><p>Boot LoadersThe primary function of boot loaders during the boot process is to load the Linux kernel into memoryBoot loaders may perform other functions as wellThe two most common boot loaders:LILOGRUB</p></li><li><p>LILOFigure 9-2: LILO boot loader screen</p></li><li><p>LILO/etc/lilo.confThe LILO configuration fileTable 9-1: Common /etc/lilo.conf keywords</p></li><li><p>LILOTable 9-1 (continued): Common /etc/lilo.conf keywords</p></li><li><p>LILOTable 9-1 (continued): Common /etc/lilo.conf keywords</p></li><li><p>LILOAlmost any hardware information may be passed to the kernel via the append= keywordThe format of the information depends on the type of hardware involvedTo uninstall LILO from an active partition or the MBR, you may use the lilo u command</p></li><li><p>LILOTable 9-2: LILO error codes</p></li><li><p>GRUBGRand Unified Bootloader (GRUB)Resembles common UNIX boot loadersMore recent than the LILO boot loaderFirst major part of the GRUB loader typically resides on the MBRThe remaining parts of the boot loader reside in the /boot/grub directory</p></li><li><p>GRUBFigure 9-3: GRUB boot loader screen</p></li><li><p>GRUB/boot/grub/grub.confThe GRUB configuration fileGRUB root partitionThe partition containing the second stage of the GRUB boot loader and the /boot/grub.conf file</p></li><li><p>GRUBNormally, GRUB allows users to manipulate the boot loader during system startupTo prevent this, you may optionally password protect GRUB modifications during boot timegrub-md5-crypt commandUsed to generate an encrypted password for use in the /etc/grub/grub.conf file</p></li><li><p>GRUBFigure 9-4: GRUB configuration boot loader screen</p></li><li><p>GRUBFigure 9-5: GRUB prompt boot loader screen</p></li><li><p>GRUBFigure 9-6: GRUB boot loader help screen</p></li><li><p>GRUBRecall that you are required to choose a boot loader during installationGrub-install commandCommand used to install the GRUB boot loader</p></li><li><p>Using LILO or GRUB to Dual Boot other Operating SystemsDual bootConfiguration where two or more operating systems exist on the hard disk of a computerIf you are using LILO or GRUB to dual boot another operating system in addition to Linux, it is easiest if Linux is installed after the other operating system has been installed</p></li><li><p>Using LILO or GRUB to Dual Boot other Operating SystemsFigure 9-7: Partitioning for a dual boot system</p></li><li><p>Using LILO or GRUB to Dual Boot other Operating SystemsFigure 9-8: Choosing a boot loader for a dual boot system</p></li><li><p>Using FIPSFirst non-destructive Interactive Partition Splitter (FIPS)Program used to create a new partition out of the free space on an existing FAT16 or FAT32 partitionResizing the Windows partition using FIPS will preserve the Windows operating system on the Windows partition yet allow for free space to install Linux</p></li><li><p>Using FIPSGuidelines/limitations to using FIPS:Version 2.0 of FIPS supports the FAT16 and FAT32 filesystems onlyFIPS will only work with primary Windows partition and will not resize logical drives within extended partitionsFIPS works by splitting the Windows partition into two primary partitionThere must be sufficient free space within the existing Windows to allow for the installation of Linux once the partition for FIPS to use</p></li><li><p>Using a Windows Boot Loader to Dual Boot LinuxNTLOADERBoot loader available with Windows NT/2000/XPCan be used to display a screen at boot time that prompts you to choose an operating system to bootSimilar to LILO and GRUB</p></li><li><p>Using a Windows Boot Loader to Dual Boot LinuxFigure 9-9: Configuration screen to put GRUB or LILO to the boot partition</p></li><li><p>Using a Windows Boot Loader to Dual Boot LinuxIt is important to create a boot disk when prompted to do so during the installationBoot.iniThe file used to configure NTLOADER</p></li><li><p>Using a Windows Boot Loader to Dual Boot LinuxFigure 9-10: Dual boot operating system choice screen at start up</p></li><li><p>Linux InitializationOnce a boot loader loads the Linux operating system kernel into memory, the kernel resumes control and executes the first daemon process on the system called init/etc/inittabThe configuration file for the init daemon</p></li><li><p>RunlevelsRunlevelTerm that defines a certain type and number of daemons on a Linux systemSince the init daemon is responsible for starting and stopping daemons and hence changing runlevels, runlevels are often called initstates as well</p></li><li><p>RunlevelsTable 9-3: Linux runlevels</p></li><li><p>RunlevelsTable 9-3 (continued): Linux runlevels</p></li><li><p>Runlevelsrunlevel commandCommand used to display the current and most recent previous runlevelinit commandCommand used to change the operating system from one runlevel to anothertelinit commandAn alias to the init command</p></li><li><p>The /etc/inittab FileWhen the init daemon needs to change the runlevel of the system by starting or stopping daemons, it consults the /etc/inittab file/etc/rc.d/rc.sysinitThe first script executed during system startup</p></li><li><p>The /etc/inittab FileFigure 9-11: System startup as a result of /etc/rc.d/rc.sysinit</p></li><li><p>The /etc/inittab FileFigure 9-12: System startup as a result of /etc/rc.d/rc*.d</p></li><li><p>The /etc/inittab FileMingettyProgram used to display a login prompt on a character-based terminal/etc/rc.d/rc.localFinal script executed during system startup</p></li><li><p>The /etc/inittab FileFigure 9-13: The Linux initialization process</p></li><li><p>Configuring Daemon Startup/etc/rc.d/rc*.dThe directories used to start and kill daemons in each runlevel/etc/rc.d/init.dThe directory in which most daemons are located</p></li><li><p>Configuring Daemon StartupFigure 9-14: Results of ntsysv --level 5 command</p></li><li><p>Chapter SummaryBoot loaders are typically loaded by the system BIOS from the MBR or the first sector of the active partition of a hard diskThe boot loader is responsible for loading the Linux kernelThe LILO boot loader uses the /etc/lilo.conf configuration file, whereas the GRUB boot loader uses the /boot/grub/grub.conf configuration fileYou may use the LILO or GRUB boot loader to dual boot Linux and the Windows operating system</p></li><li><p>Chapter SummaryThe FIPS utility may be used to split a FAT16 or FAT32 partition in order to create enough space to install LinuxThere are seven standard runlevels used to categorize a Linux system based on the number and type of daemons loaded in memoryThe init daemon is responsible for loading and unloading daemons using its configuration file /etc/inittabDaemons are typically stored in the /etc/rc.d/init.d directory and loaded at system startup from entries in the /etc/rc.d/rc*.d directories</p></li></ul>

Recommended

View more >