Solved

Needed files to boot Linux

Posted on 2013-10-31
4
570 Views
1 Endorsement
Last Modified: 2013-11-06
Good Day

Is somebody having a graphic with filenames, services and other stuff needed to boot Linux.
I need one to teach our junior System Engineers.

Thanks
1
Comment
Question by:awawada
  • 2
  • 2
4 Comments
 
LVL 20

Accepted Solution

by:
Daniel McAllister earned 250 total points
ID: 39617636
"Linux" is actually only the kernel... all the other stuff you see (esp if you have a GUI login) is custom-built by a combination of the distro you've chosen and the user selections made during installation.

In general, the Linux boot process looks something like this (for RHEL and other SYS-V derivatives):
 - Boot loader (BIOS, UEFI, etc) determines hardware config
 - Boot loader loads secondary boot loader (GRUB, LILO, ntldr.dll, etc.)
    NOTE: Some boot loaders (like UEFI) can bypass the secondary boot loader... that's why its there!
 - Kernel detects hardware & loads drivers -- including filesystems
 - Kernel executes initialization scripts based on /etc/inittab

Once you reach this far, every system will be different... different distros yes, but even different installations!

I hope this helps!

Dan
IT4SOHO
0
 
LVL 40

Assisted Solution

by:noci
noci earned 250 total points
ID: 39620977
One small addition...

If the kernel uses initramfs ( an initial ramdisk f.e. for auto detecting hardware, encrypted root fs. support  etc.)
Then grub loads the initramfs too, for lilo & (U)EFI support  the kernel needs to be built with a copy of that RAMFS built in.
0
 
LVL 20

Assisted Solution

by:Daniel McAllister
Daniel McAllister earned 250 total points
ID: 39622055
noci,

The requirement for an initram filesystem has been deprecated since the early days of GRUB. The purpose was to provide or "auto-load" drivers for devices that were necessary for the system boot to continue.

However, using an initramfs can still be necessary if you have devices needed for booting (like RAID controller drivers, or other odd storage systems -- or a boot fs that is not standard) that are not in the compiled kernel.

Even so, a custom-built kernel can easily remove the need for the initramfs in modern Linux. (I haven't used one personally since the 2.6 kernel came out in RHEL 4).

While not a bad addition to the discussion, I was hesitant to include it because the question appears to apply (so far) only the "generic case" for booting Linux... and since we're talking all flavors of all distributions of Linux (perhaps even Android!), I thought it best to apply KISS and report most everything else as "distro specific" -- even though many have common elements.

Dan
IT4SOHO
0
 
LVL 40

Assisted Solution

by:noci
noci earned 250 total points
ID: 39624318
@IT4SOHO,

I run all my laptops and some computer systems and one USB stick based linux with encrypted disks.
For those use cases an initramfs is needed to provide for the scripting needed to unlock the rootfs, that support cannot be easily built into the kernel. I agree that KISS is a sound principle, in the case of mobile systems imho encrypted disks are a requirement and the support of initramfs should be mentioned.
I agree that it does complicate things a little, especialy in the (U)EFI case.

Kind regards,
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question