Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Right place to install Linux bootloader Post 302867801 by bakunin on Friday 25th of October 2013 04:41:35 AM
Old 10-25-2013
OK, first a few words about the booting process of a PC. That will make it clearer, hopefully:

When a PC starts, the BIOS holds the first program to be loaded. It scans several busses (IDE-controllers, SCSI-controllers, ...) for prospective devices to boot from and creates a list. Then this is worked from top to bottom (though it is possible to exclude certain devices or rearrange list entries - this is a common option in BIOSes).

Every device found that way - usually disks, USB sticks, CD-ROM-drives, diskette drives and so on - is in turn scanned for a so-called "Master boot record". This is a certain disk block, which contains a boot-loader program - if the disk is bootable. If not, then this space is simply left free and the process tries the next device in its list and searches there for a MBR.

If such a boot-loader is found, it is loaded by the BIOS and started. The boot-loader is NOT an OS by itself, it just loads an OS. GRUB, the older lilo and some other boot-loaders work that way. Usually the boot-loader presents a selection of kernels to boot from and a list of root volumes (aka "partitions" to use as the root of the FS - to mount as "/" in case of Unix-systems, as "C:" in case of DOS/Windows-systems or as "[SYS]" in case of VMS-systems.

Once a kernel image and/or boot partition is selected the boot-loader program tries to pass control to an OS-bootstrap program located in certain parts of the selected partition (this is why you need to flag a partition "active" to boot from - this certain space is set apart) and starts that. This in turn loads the OS kernel and the rest is OS specific. Note, that the whole process up to the initialization of the OS kernel happens in the CPUs "real mode", even for protected mode/virtual mode OSes. They have to switch the CPU into their respective mode of operation themselves.

So, to answer your question: yes, you will have to install the boot loader (perhaps "GRUB", less likely "lilo") to the MBR ("/dev/sda", which signifies the disk, rather than "/dev/sdaX", which denotes a certain partition on that disk), otherwise it will not get executed automatically. You need to do that as root, not as normal user, because files involved in the boot process have mostly permissions set to be accessible only by root.

I hope this helps.

bakunin
These 2 Users Gave Thanks to bakunin For This Post:
 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Is there a place like this for LINUX questions?

Is there some place like this unix.com for linux questions? a forum like area to ask questions? I love this site, i've learned a lot (use unix - solaris, and linux - redhat). Unfortunately redhat.com has gotten rid of their support forums, everything is in a list type format and I don't want to... (6 Replies)
Discussion started by: kymberm
6 Replies

2. Solaris

solaris 10 bootloader

Hi, I'm new to solaris and I have a question about installing solaris 10. Does solaris during install create a /boot partition? And if it does, is it possible to set the bootloader on this partition or will it always be on the MBR? greetz tony (4 Replies)
Discussion started by: topa
4 Replies

3. Red Hat

RedHat BootLoader

Hi, I have Windows XP and RedHat ES both. Last day I format windows due to problems in it, But now the BootLoader that used to come earlier is not coming. My system is directly booting Windows XP. How can I recover RedHat or what I need to do to get back the BootLoader. So that I can use both... (1 Reply)
Discussion started by: somnathbanerjee
1 Replies

4. UNIX for Advanced & Expert Users

Network Bootloader using Linux ...

Hello, I want to find out the best route for setting up a network bootloader where I can have a custom listing of programmable options. Some of the desired options include: Setting up a linux or windows system via the network Troubleshooting utilities (like Knoppix) load via the... (2 Replies)
Discussion started by: ckoeber
2 Replies

5. Solaris

What is the best way to copy data from place to another place?

Dear Gurus, I need you to advice or suggestion about the best solution to copy data around 200-300G from serverA(location A) to serverB(location B). Normally, I will share folder and then copy but it takes too long time(about 2 days). Do you have any suggestion or which way should be... (9 Replies)
Discussion started by: unitipon
9 Replies

6. Boot Loaders

Bootloader Resources

Here is a list of resources for Unix and GNU/Linux bootloaders: GRUB Legacy: The original GRand Unified Bootloader. Now known as GRUB Legacy. GRUB: The latest and greatest. More commonly known as GRUB2. BRUG: Brand-new Universal loadeR from GRUB. Based on GRUB. Adds features like new object... (0 Replies)
Discussion started by: fpmurphy
0 Replies

7. UNIX for Advanced & Expert Users

Linux column(1) from util-linux-ng for Solaris? Which *.pkg to install?

Hi On Linux systems there is a command called "column". column - columnate lists Synopsis column -tx] -c columns] -s sep] file ...] Description The column utility formats its input into multiple columns. Rows are filled before columns. Input is taken from file operands, or,... (3 Replies)
Discussion started by: slashdotweenie
3 Replies

8. UNIX for Dummies Questions & Answers

Unix vs linux in the job place and other questions

hello all, im new to this site...and look forward to corresponding with you all. i am a microsoft kid (sad) currently i work on small networks and repair computers for home and business. i want to better my skill set...but dont want to carry on down the MS route. Basically i want to... (12 Replies)
Discussion started by: j0n1n
12 Replies

9. Ubuntu

How do I re-install my bootloader?

I accidently altered my partition table. Somehow I wiped it out completely and changed the disk label. Before I rebooted I managed to rebuild it the way it originally was using the original structure and label however I need to re-install a new bootloader for the new MBR. I have Ubuntu 14.04TLS... (1 Reply)
Discussion started by: project722
1 Replies
UEFI(8) 						    BSD System Manager's Manual 						   UEFI(8)

NAME
UEFI -- Unified Extensible Firmware Interface bootstrapping procedures DESCRIPTION
The UEFI Unified Extensible Firmware Interface provides boot- and run-time services to operating systems. UEFI is a replacement for the legacy BIOS on the i386 and amd64 CPU architectures, and is also used on arm64 and ia64. The UEFI boot process loads system bootstrap code located in an EFI System Partition (ESP). The ESP is a GPT or MBR partition with a spe- cific identifier that contains an msdosfs(5) FAT file system with a specified file hierarchy. Partition Scheme ESP Identifier GPT C12A7328-F81F-11D2-BA4B-00A0C93EC93B MBR 0xEF The UEFI boot process proceeds as follows: 1. UEFI firmware runs at power up and searches for an OS loader in the EFI system partition. The path to the loader may be set by an EFI environment variable. If not set, the default is /EFI/BOOT/BOOTX64.EFI. The default UEFI boot configuration for FreeBSD installs boot1.efi as /EFI/BOOT/BOOTX64.EFI. 2. boot1.efi locates the first partition with the type freebsd-ufs, and from it loads loader.efi. 3. loader.efi loads and boots the kernel, as described in loader(8). The vt(4) system console is automatically selected when booting via UEFI. FILES
/boot/boot1.efi First stage UEFI bootstrap /boot/boot1.efifat msdosfs(5) FAT file system image containing boot1.efi for use by bsdinstall(8) and the bootcode argument to gpart(8). /boot/loader.efi Final stage bootstrap /boot/kernel/kernel default kernel /boot/kernel.old/kernel typical non-default kernel (optional) SEE ALSO
vt(4), msdosfs(5), boot(8), gpart(8) HISTORY
UEFI boot support first appeared in FreeBSD 10.1. AUTHORS
UEFI boot support was developed by Benno Rice <benno@FreeBSD.org>, Ed Maste <emaste@FreeBSD.org>, and Nathan Whitehorn <nwhitehorn@FreeBSD.org>. The FreeBSD Foundation sponsored portions of the work. CAVEATS
EFI environment variables are not supported by loader(8) or the kernel. boot1.efi loads loader.efi from the first FreeBSD-UFS file system it locates, even if it is on a different disk. boot1.efi cannot load loader.efi from a ZFS(8) file system. As a result, UEFI does not support a typical root file system on ZFS configura- tion. BSD
October 17, 2014 BSD
All times are GMT -4. The time now is 02:55 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy