What is the Booting Process?

What is the Booting Process?

Booting in Operating System

Operating System Booting is the process of initiating the computer. It can be initiated through hardware, such as pressing a button or the software command. When it is turned on, the CPU has no software installed in its main memory. Therefore, certain processes require loading software into memory prior to running. This could be accomplished using firmware or hardware in the CPU, or by a separate processor inside your computer.

Restarting computers is also known as rebooting. This may happen “hard”, e.g. the power supply for the processor is turned off to on, and “soft boot”, where the power is not interrupted. In some systems, a”soft” boot can also clear the RAM down to zero. 

Soft and hard booting may be initiated via hardware, like a button press or software command. The process of booting is completed when the runtime system that is operating generally the operating system, and a few applications, are reached.

The process of restoring the computer to the state of sleep is not a matter of booting it; however, restoring it to the state of hibernation can. 

In the simplest sense, certain embedded systems don’t require a distinct initial boot sequence and, if they are turned on, they can run operating applications that are stored in the ROM. Every computer system is a state machine and a restart could be the only way for returning to a zero-state after an unintentionally locked state. 

Alongside loading the operating system or stand-alone application, the boot process may be able to load storage dump software to diagnose issues in the operating system.

Booting Process
Booting Process

Sequencing of Booting

The booting sequence is a process of starting up which starts running the system operating on a PC when it is switched on. It is a primary sequence of actions that the computer performs once it is turned on. Every computer comes with an initial boot sequence.

1. Boot Loader Computers that are powered by the central processor unit can only run software that is stored in the memory of the system. Modern operating systems and applications software code and data are stored in nonvolatile memory.

 When a computer is initially started, it has to initially rely solely on the data and code stored in nonvolatile parts of the memory. The operating system isn’t fully loaded when it boots and the hardware is unable to perform complex system actions.

The program that initiates the chain reaction and ends with the operating system loaded is called the bootstrap loader or boot loader. The only task of the boot loader is to load the other programs for an operating system’s be able to start.

2. Boot Devices This is the device on where the operating system is loaded. Modern PC BIOS (Basic Input/output system) supports booting from multiple devices. 

These include a local hard optical drive, disk drive, Floppy drive an interface card for networks, as well as a USB device. The BIOS allows users to set the boot order. When the boot sequence is configured to:

Booting Process
Booting Process
  • CD Drive
  • Hard Disk Drive
  • Network

The BIOS will attempt at first booting from the drive but if that fails it will attempt to start from the drive in the event that that fails, then it will attempt to boot via the network. If this fails, it won’t even boot.

3. Boot Sequence: There’s an established boot sequence that every personal computer uses. The CPU starts by running an instruction inside memory to run the BIOS. The instruction includes the jump instruction, which is then transferred into the BIOS start-up program. 

The program performs self-tests for power-on (POST) to verify that devices that the computer is relying on are working correctly. Then, BIOS runs through the programmed procedure until it locates the bootable device.

 After BIOS finds the device that is bootable, BIOS loads the boot sector and begins execution in the partition for boot. In the case of a drive that is the master boot record (MBR).

The MBR code scans the partition table to find any active partitions. If it finds one then the MBR code is able to load that partition’s boot sector and run it.

 It is usually specifically designed for the operating system; but in the majority of the operating system, its primary job is loading and running the kernel of the operating system, that continues to start up. 

In the event that there is no active partition or the current partition’s boot sector has become not valid. In this case, it is possible that the MBR might load a second boot loader that will choose one partition to load the boot sector that will typically load the appropriate operating kernel for the system.

Types of Booting

Booting Process
Booting Process

There are two kinds of booting that can be found in the operating system.

  1. Cold booting If the system is first started, or it is currently in shutdown state and switches on the power button in order to power up it, the kind of procedure to begin the computer is referred to as cold booting. In cold booting it will follow all the instructions in BIO (BIOS) as well as the Operating System will be automatically installed into the system. This process will take longer than Warm or Hot Booting.
  1. Warm Booting A hot or warm process of booting is the time when computers reach an unresponsive or hung state, and the system is permitted to restart at any time during the on-condition. This is also known as a reboot. There are numerous reasons behind this situation and the only remedy is to reboot your computer. 
  1. Rebooting is often required to install new hardware or software. The system needs to reboot to establish hardware or software configurations, and sometimes systems can behave in a strange manner or not function properly.
  1.  In this case, there must be forced restarted. The most common Ctrl + Alt+Del button is utilized to restart the system. In some systems, the reset button could be accessible to restart the system.

Steps of Booting Process in Operating System

When our computer is turned on, it may be initiated by hardware like the press of a button or through software commands. the computer’s central processing unit (CPU) does not have any software stored in its main memory.

It is the case that there is a procedure that must load the software into the main memory before it is able to be executed. Here are the cores in reset steps for describing the  secure boot procedure in the operating system, for example:

Step 1: After the computer system has been switched on pressing the power switch, BIOS (Basic Input/Output System) runs a variety of functional tests on programs that are stored in ROM. These programs are called POST (Power-on Self-Test) which checks to determine whether the peripherals on the system are functioning properly or not.

Step 2: When the BIOS has completed its pre-boot or functional test it reads the bootable sequences from the CMOS (Common Metal Oxide Semiconductor) and then searches for master boot records within the initial physical segment on the bootable disk according to the boot device sequence defined in the CMOS. For instance when the sequence of the boot device is:

  • Floppy Disk
  • Hard Disk

Step 3. After that, your master boot record will be searched first in a floppy drive. If the drive is not found it will look for the master boot file. If there is no master boot file does not even on the hard disk and that’s when the CDROM drive will look for it. 

If the system can’t read the master boot file using any of these resources, the ROM will display ” No Boot device found and stop the system. When it locates the master boot file from the bootable disk drive an operating system loader often known as Bootstrap loader will be loaded into the boot segment of the bootable drive into memory. The bootstrap loader is a specific program that is found within the sector that is used to boot a drive that is bootable.

Step 4. A bootstrap loader initially loads it with the IO.SYS file. Following this, the MSDOS.SYS file is loaded. It is the primary file for the DOS operating system.

Step 5: Following this, MSDOS.SYS file searches to locate the Command Interpreter in CONFIG.SYS file and, when it does it, it is loaded into memory. If there is no Command Interpreter is defined by the CONFIG.SYS file, then the COMMAND.COM file is loaded as the default Command Interpreter of the DOS operating system.

step 6 the Last file that needs to be downloaded and run is an AUTOEXEC.BAT file which is a set of DOS commands. Following this, the prompt will be displayed. It displays the drive letter of the bootable drive that is displayed on the computer and signifies that the operating system has been installed successfully running on the system via the drive.

What is Dual Booting?

If there are two different operating systems installed on a computer system, this is known as dual booting. Multiple operating systems may be installed on systems. To determine what operating system to boot, you need a boot loader that can recognize multiple file systems and operating systems that could be in that boot disk.

After being loaded, it will start one or more operating systems within the drive. The disk could have multiple partitions, each of which contains an operating system. When a computer is turned on it, a boot manager application shows a menu that allows the user to choose which operating system they wish to utilize.

Essential Windows System Files

When you install an operating system The setup program will create folders and necessary data on system drives. These are the most important Windows systems files.

1. Windows Boot Process

Windows XP, Vista, and 7 OSs turn on and begin to run by using the standard BIOS-MBR approach. While, Microsoft operating systems beginning at Windows 8 and later versions will utilize either the traditional BIOS-MBR method or the newer UEFI GPT method, based on the user’s preference.

Below is the process that happens inside the system once it is turned on.

  1. If the user switches the system on, the CPU sends the Power Good signal to the motherboard and then checks the BIOS firmware.
  2. BIOS initiates with a Power-On Self-Test (POST) which examines if all the components required to boot the system are in place and loads all firmware settings from the nonvolatile memory of the motherboard.
  3. If POST is successful, the add-on adapters run a self-test to ensure integration into the system.
  4. The pre-boot procedure will conclude with POST and will identify the existence of a bootable system disk.
  5. Following POST, the firmware of the computer scans the boot drive then loads the master boot record (MBR) that search for the basic boot information within BCD, which is the boot configuration data (BCD),
  6. MBR triggers Bootmgr.exe which finds Windows loader (Winload.exe) on the Windows boot partition. This activates Winload.exe.
  7. Windows loader is used to boot the kernel of OS ntoskrnl.exe.
  8. When the Kernel is running it will load the Windows loader starts loading HAL.DLL and boot-class device drivers that are marked BOOT START, and the SYSTEM registry hive into memory.
  9. Kernel transfers control of the boot process to Session Manager Process (5MSS.exe) that loads the other drivers and registry hives needed to set up Win32 subsystems run
  10. Session Management Process triggers Winfogon.exe which displays the logon screen to users for authorization
  11. Session Manager Process launches the Service Control Manager that starts all services, the driver for non-essential devices as well as Security subsystem L5ASS.EXE as well as Group policies scripts.
  12. After the user logs in, Windows creates a session for the user.
  13. The Service Control Manager starts the Explorer.exe and then initiates the Desktop Window Manager (DMW) process, which sets the desktop of the user.
Windows Boot Process (Cont’d)

The EFI boot manager manages this UM procedure of boot. It begins with platform firmware initialization. The loader loads UEFI drivers as well as UEFI apps (including UEFI OS boot loaders) to start the platform’s functions. This process loads an OS loader in the final step, and then the OS begins to boot. When the OS gets the commands it stops its UEFI process of booting.

The LIEF boot process is comprised of five phases, and each plays a different function. The five phases include:

  • SEC (Security) Phase

This part of EFI comprises the initialization program that is executed by the system after turning the EFI system on. It controls events for platform resets and also sets the system up to find the PEI, validate it, install and operate the PEI.

  • PEI (Pre-EFI Initialization) Phase

The PEI phase is the one that initializes both the temporary and CPU memory and the boot software volume (BF A. It finds and executes the pre Initialization Modules (PEIMs) that are within the BFV in order to start the initialization of every piece of hardware found in the system. Then, it generates the Hand-Off Block list with the descriptors of all resources found and forwards it to the next phase, i.e. DXE. DXE phase.

  • DXE (Driver Execution Environment) Phase

The majority of the initialization takes place during this phase. Utilizing the Hand-Off Block List (HOBOL) it starts the initialization of the entire system’s physical memory and I/O, as well as MIMO (Memory Mapped Input Output), resources before finally the process of dispatching DXE Drivers within the system.

Firmware Volumes (given in the HOBL). The DXE core creates an array that includes EH Boot Services and EFI Runtime Services. These EFI Boot Services provided are assigning memory as well as loading executable files.

 Its EFI Runtime services are offered to transform memory addresses from virtual to physical, transferring them to the kernel resetting the CPU, and returning to programs running inside the EFI environment or inside the 05 kernels when the CPU is in control of the system.

  • BDS (Boot Device Selection) Phase

In this stage, it is where in this phase, the BD S interprets the boot configuration data and then selects the Boot Policy for later implementation. This phase collaborates with the DXE to determine if driver’s drivers need signature verification.

In this stage, it loads the MBR boot codes into memory for Legacy BIOS Boot or loads the Bootloader program from the EFI partition to enable UEFI Boot. There is also an option to select EFI Shell and/or an application that uses UEFI for the boot Device in the Configuration.

  • RT (Run Time) Phase

The system removes the UEFI program from memory and then transfers that data to OS. When it comes to the UEFI BIOS update, the OS initiates the runtime service by using a tiny portion of memory.

2. Macintosh Boot Process

Here are the steps to follow for the Macintosh boot procedure:

  • The Macintosh boot process begins by activating BootROM initializing the hardware on the system and choosing an operating system to run.
  • After you have powered on your Macintosh, BootROM performs POST (Power-On Self-Test) to test the hardware interfaces needed for startup.
  • In the PowerPC powered Macintosh machines, Open Firmware initializes the other interfaces to the hardware
  • In Intel-powered Macintosh machines, EP initializes the rest of the hardware interfaces
  • After the hardware interfaces are initialized The system then chooses the operating system.
  • If the system has multiple operating systems, it lets the user select the operating system that is suitable for them by pressing the Option key
  • Once the BootROM operation is finished, the control passes to the Boot{ (PowerPC) or boot.efi (Intel) boot loader, which is located in the /System/Library/CoreServices directory
  •   The boot loader loads a pre-linked version of the kernel, which is located at /S System/Library /Caches/com.apple.kernelcachesIn the event that the kernel pre-linked is not present then the boot loader attempts to download the cache file that contains set driver drivers for the device.
  •  the boot loader searches for drivers If the next cache file is also missing, in the /System/Library/Extensions directory
  • In the event that the kernel pre-linked is not present then the boot loader attempts to download the cache file that contains a set of driver drivers for the device.
  • If the next cache file is also missing, the boot loader searches for drivers in the /System/Library/Extensions directory
  • After the drivers that are essential are loaded after which the boot loader can begin the initialization process of the kernel. Math as well as BSD structure of data, in addition to the I/O kits.
  • The I/O kit utilizes devices trees to connect the drivers loaded to the kernel
  • The launched program, which replaced the mach_init procedure is able to run startup items to prepare the system to be used by the user.

3. Linux Boot Process

Booting Process
Booting Process

In the Linux initial boot, the flow of the process begins with the BIOS that seeks out bootable and active devices. The system booted Linux via hard disk where the MBR is an initial boot loader.

The Linux Boot Process consists of three steps. The three stages are in the following order:

  • The BIOS Stage
  • The Bootloader Stage
  • Kernel Stage

1. The BIOS Stage

The initial step that is part of the Linux boot process is the 13105 stage. It is the first step to initialize the hardware prior to this process. The BIOS will retrieve the data, that is stored inside the CMOS chip (Complementary Metal-Oxide Semiconductor) which is a battery-operated memory chip located on the motherboard. It contains information regarding the hardware configuration.

During the boot process, the BIOS will run a Power-On-Self-Test (POST) to verify that all parts of your system’s hardware are operating. When the BIOS ensures everything’s working properly then it will begin looking for the disk or drive which houses the operating system using a standard sequence. If the first device listed isn’t available or not working, it will search for the next device and then the next one, and so on. 

A drive is bootable only if it contains at least the Master Boot Record in its first sector, also known as the boot section. A system’s hard drive serves as the main boot disc, and the optical drive acts as the second boot disk that allows you to boot the operating system using the removable disk the primary hard disk fails.

2. The Bootloader Stage

The bootloader stage consists of the process of loading the Linux kernel as well as an initial memory disk. The kernel helps enable your CPU access to RAM as well as the disk. The second pre-cursor program represents an image of an in-place virtual file system referred to as the initial image, also known as the initial RAMdisk(Random Access Memory).

 The system then prepares to install the main file system. It then locates the device that houses the file system and loads the required modules. The final stage of the bootloader process is loading the kernel into memory.

3. Kernel Stage

After the control shifts from the stage of the bootloader to the Kernel stage, the virtual root system generated by the initrd image is executed by its Linux program. The program creates the actual root system’s filesystem and then removes the initrd image. 

The kernel then scans for new hardware and installs any device drivers that are compatible. Then, it mounts the root file system and starts the init process. Init is able to read inittab from “/etc/inittab” and uses this file to load the other system’s daemons. The system is then prepared and users can sign into the system and begin using it.

 The most commonly used bootloaders that are available for Linux include LILO (Linux Loader) and GRUB (Grand Unified Bootloader). These bootloaders permit users to choose the OS bootloader to use at the boot process.

Challenges During Boot

 1–Electrical Error

An electrical problem is one of the most common reasons for a computer not to boot. Sometimes, the computer isn’t plugged into the wall. Sometimes people forget to plug the computer in when there is a storm or their pets (or children) are playing and the cord was not plugged in.

A never-used light switch was also a reason, which embarrassingly happened to me once. In my case, I was convinced it was an electrical problem and called an electrician. I was embarrassed when he explained that the light switch had been turned off.

You may need to inspect your fuse box or circuit breakers if you have an older home or any other electrical issues. This will ensure that your computer plug is powered.

2–Dead Power Supply

Dead power supplies are closely related to electrical problems. Your computer will not function if your power supply is down. (Note that some server-quality high-end computers have redundant power sources.

Modern power supplies are more robust than ever, but it is possible for your power supply to fail prematurely if it was not powerful enough.

A dead power supply means that your computer doesn’t respond when you press the power button. There are no lights or noises, and they don’t flash. These are the symptoms of a dead computer power supply.

3 – Monitor Problems

Sometimes your computer boots perfectly, but you don’t notice because your monitor isn’t working.

A majority of computer monitors have a small indicator light that indicates they are on. If the light is of the correct color, ensure that your monitor is connected to your computer. These cords can become unplugged at any time, giving the impression that your computer is having trouble booting.

Another option is to borrow a friend’s computer monitor and then start your computer. If the friend’s monitor does not work, you will know that you are having a problem with your computer booting.

4–Bad Disk Drive

Your computer won’t be able to read your operating system, such as Windows if your main drive fails. The computer will then start restarting but stop. It will sometimes display a helpful error message. Other times, it will simply display a cryptic code or no information.

This problem can be solved by purchasing a new hard disk and installing Windows on it. You can recover data from your old drive once you have Windows running. If you’re into geeky things, you might try to fix the boot sector on your hard drive. This is something that will stop your computer from starting up.

5–Disconnected Hardware

This problem has been a problem for me several times when I moved desktop computers around in my car. The computer’s parts aren’t completely screwed or pushed into place, so the car’s movement loosens them. They don’t fall out completely, but they are able to move enough to make them work.

To boot successfully, your computer requires several pieces of hardware. These include computer memory (RAM), and graphics cards (on desktop computers). 

You’ll have trouble booting your computer if any of the essential hardware is disconnected. Even dislodgement of the CPU occurred to me, though I don’t know-how. It was removed during travel.

Your computer might display (or beep!) a cryptic code. To find out the meaning of this error code, you can search Google for it along with your computer model. Open the computer’s case and disconnect the power. Next, place one hand on the metal portion of the case to ground yourself. Then, gently insert every cord and removable part. This should resolve your problem with booting a computer.

Read More:

Data Model In DBMS And Its Types

Top 8 Python Testing Frameworks

Cloud Computing and its 10 Types Of Virtualization

5 Ways to Select the Best Android Spy App

Data Mining in Businesses

Previous articleData Model In DBMS And Its Types
Next articleTop 8 Python Testing Frameworks
Hello, My name is Ruchika and I am a Full Stack Developer from Delhi. I am final year Computer Science student from SLIET University. My technologies are Nodejs, React, MongoDB, and I am also familiar with Python, C, and C++. Apart from technical skills, My hobbies are reading, writing, and traveling. I consider myself a very focused person and I always work towards my goals in a very efficient manner. I am a team player and very optimistic in tough times.



Please enter your comment!
Please enter your name here