Tuesday, June 5, 2018

Linux booting process

What is booting process?
  • Booting process in a Linux installation involves multiple stages, includes execution of boot-loader, initialization of firmware, startup and loading of a Linux kernel image and executions d daemons and scripts.
 What is mean by Daemons?
  • Daemons is a computer program that runs in the computer background process, rather than being under the interactive or end user. The process name of daemons ends with the letter d.  
  • For example sshd is a daemons that serves incoming ssh connections.

"When you press the power button at the time POST(power on self test) program is called itself. it check the all connected devices like mouse, keyboard are working properly or not."
6 stages are included in booting process :-
  1.  BIOS (Basic Input/Output system)
  • BIOS perform some integrate check 
  • It searches, loads and executes the boot loader program
  • It looks for boot loader in Floppy disk, CD ROM, HDD(hard disk drive). You can press any key during the BIOS setup to change the sequence of boot.
  • Once boot loader program is detected and executed the control goes to the MBR.

    2. MBR(Master boot recorder)
  • MBR is located in 1st sector of bootable disk. Typically /dev/sda or /dev/hda
  • The size of MBR is 512 bytes. These 512 bytes are divided into 3 components:-
    • primary bootloader info in 1st  446 bytes
    • Partition table information in next 64 bytes
    • MBR validation check in last 2 bytes
  • MBR contains the information about GRUB
  • When MBR loads and executesthe GRUB boot loader.

      3. GRUB
  • GRUB stand for Grand Unified Bootloader.
  • If you have multiple kernel images already installed on your machine/system , you can choose which one you want to executed.
  • GRUB displayed the splash screen  and it wait for few seconds if you not select any image it executes the default one.
  • GRUB have knowledge about the file system 
  • The location of grub file is in linux "/etc/grub/grub.conf".
  • So GRUB just loads and executes the kernel and initrd images.

     4. Kernel
  • It mounts the root file system as specified in "root=" in grub.conf
  • it executes the /sbin/init program 
  • NIT was the first program to be executed in linux kernel, so its process id is 1
  • Do 'ps -ef | grep init'
  • init is used by kernel as a temporary root file system until kernel booted and root file system is mounted.

      5. Init
  • Chech in /etc/inittab file to decide the Linux run level
  • There are total 6 run levels are available 
    • 0 - halt
    • 1 - Singel user mode
    • 2 - Multi-user, Without NFS
    • 3.- Full multiuser mode
    • 4 - unused
    • 5 - x11
    • 6 - Reboot    
  • Generally the default run level is 3 or 5 

     6. Runlevel program   
  • When the linux system booting up, at the time various services getting started.
  • Depending on the your default init level setting  will executes 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/  

That is happens during the booting process. I hope you clear the booting process.

Thank You...!😃😃😃
 

Saturday, June 2, 2018

What is Operating system and Linux

1.What is operating system ?
  • An operating system is the program that initially loaded into the computer boot program and manage all the other computer programs.
  • And other programs called applications / application (like Microsoft office, VLC etc.).
  • The application program make use of the operating system by making request for services through defined API(Application program interface).

2. What is Linux?
  • Linux is a family of free and open source operating system build around the Linux kernel.
  • Linux was originally developed for personal computers based on the Intel x86 architecture. 
  • Linux is also  leading operating system on servers and mainframe computers. 

3.  What is Open Source?
  • Open source refers to any program whose source code is made easily available for use and the modification as a user or as a developer. 
  • So basically the open source code is developed for public contribution and made for free available.

4. Difference between Open source and Close source?
  • Open source :- 
      • Open source software is distributed under the licensing agreement which allow to be share, modify and view the code by other users and organization.
      • Open source slightly more user-friendly language.
      • Don’t make the mistake of assuming that OSS is always free. Many software creators release their programs free of charge but then make very good money selling services and support.

  • Close source :- 
      • Closed source software can be defined as proprietary software distributed under a licensing agreement to authorized users with private modification, copying, and republishing restrictions.


Thank You...!😀😀😀
Save Tree
Save Tree

Linux booting process

What is booting process? Booting process in a Linux installation involves multiple stages, includes execution of boot-loader, initializ...