Fedora Linux Support Community & Resources Center

Go Back   FedoraForum.org > Fedora 17/18 > Using Fedora
FedoraForum Search

Forgot Password? Join Us!

Using Fedora General support for current versions. Ask questions about Fedora and it's software that do not belong in any other forum.

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 8th June 2012, 02:32 PM
tech291083 Offline
Registered User
 
Join Date: Sep 2006
Posts: 992
linuxfirefox
Difference between EFI and boot partition

Hi,

I have Fedora 16 32+ bit installed on my pc and here is the screenshot of a program called Disk Utility which basically shows partitions etc. But I have one question here. What is EFI system partition? Is it the same as boot partition? What is BIOS boot partition?

Here is what I get in a terminal.

Code:
[james@localhost ~]$ su
Password: 
[root@localhost james]# fdisk -l

WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted.


Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders, total 156301488 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x4e474e47

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1   156301487    78150743+  ee  GPT

Disk /dev/mapper/VolGroup-lv_swap: 5536 MB, 5536481280 bytes
255 heads, 63 sectors/track, 673 cylinders, total 10813440 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/VolGroup-lv_swap doesn't contain a valid partition table

Disk /dev/mapper/VolGroup-lv_root: 49.3 GB, 49325015040 bytes
255 heads, 63 sectors/track, 5996 cylinders, total 96337920 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/VolGroup-lv_root doesn't contain a valid partition table

Disk /dev/mapper/VolGroup-lv_home: 24.6 GB, 24628953088 bytes
255 heads, 63 sectors/track, 2994 cylinders, total 48103424 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/VolGroup-lv_home doesn't contain a valid partition table
Code:
[root@localhost james]# df -h
Filesystem                    Size  Used Avail Use% Mounted on
rootfs                         46G  6.5G   38G  15% /
devtmpfs                      2.0G     0  2.0G   0% /dev
tmpfs                         2.0G  244K  2.0G   1% /dev/shm
tmpfs                         2.0G   42M  2.0G   3% /run
/dev/mapper/VolGroup-lv_root   46G  6.5G   38G  15% /
tmpfs                         2.0G   42M  2.0G   3% /run
tmpfs                         2.0G     0  2.0G   0% /sys/fs/cgroup
tmpfs                         2.0G     0  2.0G   0% /media
/dev/sda2                     497M  101M  372M  22% /boot
/dev/mapper/VolGroup-lv_home   23G   16G  6.7G  70% /home

Code:
[root@localhost james]# vgdisplay
  --- Volume group ---
  VG Name               VolGroup
  System ID             
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  4
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                3
  Open LV               3
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               74.03 GiB
  PE Size               32.00 MiB
  Total PE              2369
  Alloc PE / Size       2369 / 74.03 GiB
  Free  PE / Size       0 / 0   
  VG UUID               uocxyY-QFHM-u8XV-Kkmf-CKrX-pY5y-0SKmMp

Code:
[root@localhost james]# lvdisplay
  --- Logical volume ---
  LV Name                /dev/VolGroup/lv_swap
  VG Name                VolGroup
  LV UUID                y1tvC6-aKyc-kYZu-5kz7-08On-f55g-nTse5H
  LV Write Access        read/write
  LV Status              available
  # open                 2
  LV Size                5.16 GiB
  Current LE             165
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:0
   
  --- Logical volume ---
  LV Name                /dev/VolGroup/lv_home
  VG Name                VolGroup
  LV UUID                KeVvvo-wwgF-aH8E-49UV-9O3v-ZDl3-3rGAyk
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                22.94 GiB
  Current LE             734
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:2
   
  --- Logical volume ---
  LV Name                /dev/VolGroup/lv_root
  VG Name                VolGroup
  LV UUID                O0KVrX-V5Vr-4FdM-AiPR-ufvo-VEnz-1SMGqB
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                45.94 GiB
  Current LE             1470
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:1
   
[root@localhost james]#
Thanks
__________________
fedoralinuxcommands.blogspot.com


All the forces in the world are not so powerful as an idea whose time has come - Victor Hugo
Reply With Quote
  #2  
Old 8th June 2012, 02:38 PM
tech291083 Offline
Registered User
 
Join Date: Sep 2006
Posts: 992
linuxfirefox
Re: Difference between EFI and boot partition

Here are the images, thanks.
Attached Thumbnails
Click image for larger version

Name:	BIOS Boot Partition.png
Views:	278
Size:	96.5 KB
ID:	23224   Click image for larger version

Name:	EFI System Partition.png
Views:	232
Size:	106.6 KB
ID:	23225  
__________________
fedoralinuxcommands.blogspot.com


All the forces in the world are not so powerful as an idea whose time has come - Victor Hugo
Reply With Quote
  #3  
Old 8th June 2012, 04:09 PM
Gareth Jones Offline
Official Gnome 3 Sales Rep. (and Adminstrator)
 
Join Date: Jul 2011
Location: Leamington Spa, UK
Age: 30
Posts: 1,716
linuxfirefox
Re: Difference between EFI and boot partition

You only need one or the other normally.

If your system uses BIOS to start-up, you need a BIOS boot partition for GRUB (the Fedora boot-loader) to store itself in. BIOS loads and executes the first 512 bytes of the first hard-disk (the master boot record). 512 bytes isn't enough space for a modern file-system driver code, so GRUB installs a minimal stage 1 loader that loads the rest from the larger BIOS boot partition. The stage 2 loader loaded from there can then read the Linux /boot file-system and boot Linux.

If your system uses UEFI instead of BIOS, you need an EFI system partition. UEFI can read certain file-systems itself, and uses files on a dedicated partition to load the boot-loader from instead of the hard-disk's master boot record.
Reply With Quote
  #4  
Old 8th June 2012, 06:50 PM
aurabindo Offline
Registered User
 
Join Date: Dec 2011
Location: Kerala,India
Posts: 45
linuxubuntufirefox
Re: Difference between EFI and boot partition

Quote:
Originally Posted by Gareth Jones View Post
You only need one or the other normally.
BIOS loads and executes the first 512 bytes of the first hard-disk (the master boot record). 512 bytes isn't enough space for a modern file-system driver code,
Isnt it the first 440 bytes rather that 512 ? Anyway, 72 bytes isnt much of a concern

UEFI isnt much mature. But it has many advantages than the BIOS, which is 30 year old stuff. There are some other posts on the installation forum about UEFI by srs5694

http://forums.fedoraforum.org/showthread.php?t=280770
Reply With Quote
  #5  
Old 10th June 2012, 08:12 PM
Gareth Jones Offline
Official Gnome 3 Sales Rep. (and Adminstrator)
 
Join Date: Jul 2011
Location: Leamington Spa, UK
Age: 30
Posts: 1,716
linuxfirefox
Re: Difference between EFI and boot partition

Quote:
Originally Posted by aurabindo View Post
Isnt it the first 440 bytes rather that 512 ? Anyway, 72 bytes isnt much of a concern
Yes, the end of the MBR is used for the traditional DOS partition table, so cannot be used by the stage-1 boot-loader, which must be even smaller than 512 bytes. I couldn't remember the actual number off-hand. Also, BIOS traditionally doesn't know about partition tables, so it still loads the full 512 bytes.

Quote:
UEFI isnt much mature. But it has many advantages than the BIOS, which is 30 year old stuff. There are some other posts on the installation forum about UEFI by srs5694
Whilst BIOS is clearly showing its age, it's still a matter of some debate in the free/open-source software world as to whether UEFI is a move in the right direction... Unfortunately there probably won't be much choice, at least until OpenBoot (formerly LinuxBIOS) matures.

---------- Post added at 08:12 PM ---------- Previous post was at 08:06 PM ----------

Quote:
Originally Posted by tech291083 View Post
As far as I am aware all the OS need BIOS to boot. Please let me know if anything other than the BIOS is used to start-up.
That depends on your machine unfortunately.

Quote:
I do not know as to how to make my system use UEFI. I am not aware of the changes to be made and the advantages/disadvantages associated with it.
If your machine has the option of both, stick with BIOS for now. UEFI support isn't really mature and can be problematic.

Quote:
I am a bit confused here as to what is meant by a dedicated partition. You mean a boot partition where Grub was installed by the use during installation. Here a dedicated boot partition needs to be created and that needs to be other than the default MBR, right?
UEFI generally loads files from a vFAT-formatted ~256 MiB partition in order to boot. I don't know the details I'm afraid.
Reply With Quote
  #6  
Old 8th June 2012, 07:47 PM
chrismurphy Offline
Registered User
 
Join Date: May 2010
Posts: 867
macoschrome
Re: Difference between EFI and boot partition

Quote:
Originally Posted by tech291083 View Post
What is EFI system partition? Is it the same as boot partition?
A ~200MB EFI System partition is created only for UEFI systems. They also get a ~500MB boot partition. They are not the same thing.

There is a bug in anaconda that causes parted to set a boot flag for boot partitions on GPT disks, and this causes the partition type GUID to be that of EFI System partition. Meaning it will appear you have two EFI System partitions.

Quote:
What is BIOS boot partition?
Created by anaconda on BIOS (not UEFI) hardware, when creating new GPT disks, to store the GRUB2 core.img.


Quote:
[root@localhost james]# fdisk -l
fdisk does not support GPT. You should use parted -l or you should use gdisk -l to get partition information on GPT disks.
Reply With Quote
  #7  
Old 8th June 2012, 09:33 PM
srs5694 Offline
Registered User
 
Join Date: Jan 2011
Location: Woonsocket, RI
Posts: 377
linuxfirefox
Re: Difference between EFI and boot partition

Chrismurphy has covered most of what's relevant here. I'll add this:

Because of the bug that chrismurphy mentioned, you (tech291083) have a Linux /boot partition that's incorrectly identified on the disk as being an EFI System Partition (ESP). This isn't a problem for Linux, which ignores partition type codes for the most part; but it could cause problems down the road if you use an OS or utility that does use type codes and that does something with ESPs that you'd rather not be done (such as create a new FAT32 filesystem on it). Thus, you may want to correct this matter. You can do so in a number of ways (pick one):
  • Type "parted /dev/sda toggle 2 boot" as root.
  • Launch GParted, right-click on /dev/sda2, and select "Manage Flags" from the menu. Uncheck the "boot" flag and click the "Close" button.
  • Type "sgdisk -t 2:8300 /dev/sda" as root.

There are variants on these and other possibilities, too. Some of these may require installing additional software, such as GParted for the second or gdisk for the third. (Note that the sgdisk program is part of the gdisk package.) After making this change, you should verify that it "took" by using the partitioning tool of your choice (but not fdisk, which doesn't understand your partition table) to verify that it's been done. In Palimpsest Disk Utility (whose screen shots you posted), you should see the "Partition Type" label change from "EFI System Partition" to "Unknown" or "Linux Basic Data Partition," depending on which method you used to make the change.
Reply With Quote
  #8  
Old 10th June 2012, 06:22 PM
tech291083 Offline
Registered User
 
Join Date: Sep 2006
Posts: 992
windows_7ie
Re: Difference between EFI and boot partition

Quote:
You only need one or the other normally.
Ok, I never knew this and it will help me in future.

I have few queries, please forgive me for the level of technical ignrance I possess.

Quote:
If your system uses BIOS to start-up, you need a BIOS boot partition for GRUB (the Fedora boot-loader) to store itself in.
As far as I am aware all the OS need BIOS to boot. Please let me know if anything other than the BIOS is used to start-up.

Quote:
BIOS loads and executes the first 512 bytes of the first hard-disk (the master boot record). 512 bytes isn't enough space for a modern file-system driver code, so GRUB installs a minimal stage 1 loader that loads the rest from the larger BIOS boot partition. The stage 2 loader loaded from there can then read the Linux /boot file-system and boot Linux.
Yes, I agree with this process, as I have remember having read this some where else as well.

Quote:
If your system uses UEFI instead of BIOS, you need an EFI system partition.
I do not know as to how to make my system use UEFI. I am not aware of the changes to be made and the advantages/disadvantages associated with it.

Quote:
UEFI can read certain file-systems itself, and uses files on a dedicated partition to load the boot-loader from instead of the hard-disk's master boot record.
I am a bit confused here as to what is meant by a dedicated partition. You mean a boot partition where Grub was installed by the use during installation. Here a dedicated boot partition needs to be created and that needs to be other than the default MBR, right?

Thanks.
__________________
fedoralinuxcommands.blogspot.com


All the forces in the world are not so powerful as an idea whose time has come - Victor Hugo
Reply With Quote
  #9  
Old 10th June 2012, 08:20 PM
srs5694 Offline
Registered User
 
Join Date: Jan 2011
Location: Woonsocket, RI
Posts: 377
linuxfirefox
Re: Difference between EFI and boot partition

Quote:
Originally Posted by tech291083 View Post
As far as I am aware all the OS need BIOS to boot. Please let me know if anything other than the BIOS is used to start-up.
Until recently, the vast majority of x86 and x86-64 PCs have used firmware known as the Basic Input/Output System (BIOS) to control hardware initialization and the earliest parts of the system boot process. BIOS isn't the only option for this, though. For instance, PowerPC-based Macs used something called Open Firmware for this purpose. Of more relevance to my and chrismurphy's comments, many modern PCs (and Intel-based Macs) use something called the Extensible Firmware Interface (EFI) or its second-generation variant, the Unified EFI (UEFI). EFI is entirely different from BIOS and requires different boot loaders; however, most modern EFI implementations for x86 and x86-64 PCs include a BIOS compatibility mode that enables them to boot using the old BIOS methods. Currently, the industry is transitioning from BIOS to EFI, and that's creating a lot of headaches.

Quote:
I do not know as to how to make my system use UEFI. I am not aware of the changes to be made and the advantages/disadvantages associated with it.
Not all PCs can boot in EFI mode, but most models introduced since mid-2011 can do so. Unfortunately, one of the problems with the BIOS-to-EFI transition is that the various makers of firmware haven't come up with anything even remotely resembling a common user interface, or even common rules for when to boot a computer using EFI mode vs. BIOS mode. Thus, switching from one mode to another requires understanding details of your firmware's design that the manufacturers don't document in their user-level documentation. To figure out these details, you may have to perform experiments.

As to advantages and disadvantages, the following are (or may be) true:
  • EFI-mode booting is sometimes faster than BIOS-mode booting. This is more likely to be true of the most modern EFI implementations -- but some manufacturers are still shipping earlier implementations that lack this advantage.
  • The very latest EFI versions support Secure Boot, which is a controversial technology that's intended to provide protection against some types of malware. Unfortunately, it can also complicate installing Linux, particularly if you want to customize your kernel. There are whole threads on this topic filled with both reasoned comments and wild conspiracy theories.
  • EFI-mode booting uses boot loaders that are stored as files in a filesystem, thus making boot loader maintenance easier than with BIOS-mode booting, which uses boot loaders that are stored (in part) as binary blobs written to "magic" parts of a disk or filesystem rather than as ordinary files.
  • EFI-mode booting involves storing data on boot loaders in NVRAM, which in conjunction with the previous item makes it possible to install and manage multiple boot loaders.
  • Most EFI implementations provide a boot manager that enables you to select from among any boot loaders you've installed; however, these in-firmware boot managers are usually pretty underwhelming in terms of features and flexibility, so you may end up using a separate boot manager as your primary boot program.
  • Most older OSes (DOS, most versions of Windows prior to Vista, OS/2, BeOS, FreeBSD, etc.) can't boot in EFI mode. Thus, if you want to dual-boot with such an OS, you may have to boot everything in BIOS mode. (Switching between BIOS-mode and EFI-mode booting is often awkward enough that it's not practical to do it on a boot-by-boot basis.)
  • Windows ties its boot mode to the partition table type: It will only boot in BIOS mode on MBR disks, and it will only boot in EFI mode on GPT disks. This has implications for disk size, since MBR tops out at 2 TiB (assuming a 512-byte sector size). Fortunately, OSes like Linux and FreeBSD are more flexible; they can boot in BIOS mode from GPT disks. A few buggy BIOS implementations require quirky workarounds to boot from GPT disks.

Quote:
Quote:
Originally Posted by chrismurphy
UEFI can read certain file-systems itself, and uses files on a dedicated partition to load the boot-loader from instead of the hard-disk's master boot record.
I am a bit confused here as to what is meant by a dedicated partition. You mean a boot partition where Grub was installed by the use during installation. Here a dedicated boot partition needs to be created and that needs to be other than the default MBR, right?
EFI uses a partition that is its partition, much as Linux's /boot or root (/) partition is a Linux partition, to store EFI drivers, boot loaders, and other files. This partition is known as the EFI System Partition (ESP). Because the ESP holds boot loaders, it's normal for OSes to write to it to store their boot loaders, and sometimes OS kernels, boot-related configuration files, etc. GRUB stores its executable on the ESP, and depending on how it's set up, GRUB configuration files can go there, too. Normally, an OS should write very little to the ESP -- just its own boot loader and anything the boot loader needs in order to work.

Note that the MBR is not a partition; it's just the first sector (normally 512 bytes) of the hard disk. On an MBR disk, though, the MBR includes definitions of all the disk's primary partitions. (Note two uses of "MBR" -- to refer to the first sector of the disk, and to refer to the partition table contained in that sector. The MBR also holds the first-stage boot loader for a BIOS-based computer.)
Reply With Quote
Reply

Tags
boot, difference, efi, partition

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
NTFS boot partition unable to boot after shrinking from Fedora Live CD mccollou Installation and Live Media 1 16th October 2011 08:41 PM
Is a boot partition ( /boot ) needed for hard drive install ? jenaniston Using Fedora 5 28th July 2011 10:37 PM
Boot Failure w Grub installed to non-MBR partition w/Windows 7 dual boot kamikazepipes Installation and Live Media 14 3rd January 2010 12:19 AM
What's the difference of the two FC8's at the boot screen? Roasted Using Fedora 1 10th December 2007 04:35 AM
Difference between u-boot & Bootstrap rgurjar Using Fedora 1 1st November 2007 05:23 PM


Current GMT-time: 02:21 (Sunday, 26-05-2013)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat