disk partitioning methods in BIOS/UEFI for one/more systems

disk partitioning methods in BIOS/UEFI for one/more systems

ragy.soltan
ragy.soltan
19 Oct 2020
4088
0

Partitioning a Disk to install one or multiple systems is a crucial process that needs some knowledge in advance in order to figure out what suites you better and on which situations. So we present you in this article to some prerequisite knowledge about things like MBR, GPT, BIOS and EFI that are needed to understand more about disk partitioning and make really good, informed decisions then Guide you through some examples to install a Single or Multi Boot for your PC/Laptop using (Windows 10) and (Ubuntu Linux), but any other system you may like will also work the same.

some prerequisite knowledge:

As a stating point you should know about BIOS (Basic Input-Output system) and UEFI (Unified Extensible Firmware Interface ) as they are the low-level software (Firmware) that is responsible for waking up your computer’s hardware components, ensures they’re functioning properly, and then runs the “BootLoader” that boots Windows or whatever other operating system you have installed. And this process is called "Boot".

bios vs uefi

ِAlthough the UEFI is the modern Firmware yet it is sometimes still referred to as the “BIOS” to avoid confusing people who are used to call this kind of software as BIOS.

So what Firmware is running in your device? If you don’t know the answer, then you may estimate by the time you bought your PC/LapTop device, so if your device came with Windows 7 or Older then it must be running BIOS and if it came with Windows 8/10 then it is running UEFI.

You can be sure by entering your device's firmware and searching in the boot options for anything related to EFI, which will of course indicate that it is UEFI-Firmware. Here are the most common ways to enter firmware from some brands of hardware manufacturers.

access-firmware

Despite the big differences in the look and contents of Firmware from one company to another, and even sometimes from one model to another, there are some common options within the boot menu, such as:

  • UEFI Secure Boot: most likely this is the default with a new PC/Laptop, and it is a secure version of the new boot method (EFI) of the UEFI Firmware that will prevent installing systems which have been maliciously modified or systems that do not have a specific validity to be installed. (should be disabled as it will cause lots of problems to your device).

  • UEFI Boot: Use the new and recommended boot method (EFI) instead of the old BIOS method primarily. ie (set the boot priority this way, and if you can't find a boot in this way, use the old Leagcy method if the [Legacy boot] option is enabled).

  • Legacy Boot: Use the old boot method Bios/MBR instead of the new UEFI method primarily. ie (set the boot priority this way, and if you can't find a boot in this way, use the new method if the [UEFI Boot] option is enabled).

Notes About BIOS & UEFI

BIOS/MBR UEFI/GPT

Uses the Old partition table MBR (Master Boot Record) that has many limitations, but  some operating systems can support the new GPT (GUID Partition Table) on BIOS.

Supports both Partition Tables the old MBR (Master Boot Record) and the new GPT (GUID Partition Table).
(MBR limit) supports only one (Master) boot record for the entire disk, which makes having multible operating system more diffcult. requires at least one one boot partition (called EFI) to store boot files and other configurations for one or multible systems or even one for each system.

(MBR limit) only four "Primary" partitions are allowed which created the need for another type of partitions "Extended" that can hold unlimited number of "Logical" partitions.

no limitations for number of partitions.

(MBR limit) can only boot from drives of 2.1 TB or less. (8 ZIB) no disk limitations, you can even create partitions larger than 2TB.

 


Now lets go through some examples installing systems and dive deeper in partitioning, in these examples i will use a UEFI/GPT in a virtual machine and will descripe the eifference that you should follow if your system is using BIOS/MBR.

  1. create a single-boot system

    For Single Boot whether your system of choice is Linux Or Windows there are a couple of ways to do that.

    The Simplest method ((FoolProof)) would be to have the full disk blank or an UN-Formatted Partition in your disk then choose that space when your system asks where you want your installation to be then hit continue or next to let the system installer auto-create the necessary partitions, including the EFI boot partition.

    On Windows when it asks about "Where do you want to install Windows?", so here you may delete a partition you don't want of old install install or delete all partitions and make clean install by doing nothing than selecting the empty space that is referred to as [Unallocated space] then click the [next] button to let the installer auto-create/format the necessary partitions and begin install.

    win10_easy_install

     

    This will result in creating a partition [Recovery | 500 MB | format: NTFS] that contains the boot files, a small partition [EFI | 100 MB | format: FAT32] that will contain boot files for UEFI/GPT and a Large Partition [C: | with size of almost all of the space that was given to it].

    and if your system is running with BIOS/MBR then you will find only one difference as the installer will not create a EFI partition.

    win10_easy_install_layout

     

    On Linux when it asks about "installation type?", you can select the option "delete everything and install" which will auto partition/format your disk but will remove any old data so make sure you made backup or copied your files to other disk.

    single-boot_linux_easy-install-option1

     

    or you can select the option "install ubuntu alongside windows" that will give you option to shrink a large partition on your disk in order to have some space available for your installation.

    single-boot_linux_easy-install-option0

     

    or you can select the option "Something else" that will give you alot more controll to to make edits to your disk, then you may delete any unwanted partitions to have the full disk space or choose an ampty spce between your existing partitions, and then for simplicity create [EFI partition | 100 MB | format: EFI] neglect this partition if your are on BIOS/MBR, and another partition [ / | with size as big as you want] for the whole system then click [Install Now].

    single-boot_linux_easy-install-option2

     

    This will create a small "EFI" partition if your device is working with UEFI/GPT and another large Partition " / " (Root) that will contain every thing for boot, system and user file and some Linux distributions will also create a “SWAP” partition that is used as an extsion to the ram memory.

    linux_easy-install_layout

     

    But it is not necessary to use the auto partitioning/formatting tool of a system to properly partition your drive and have one or more system installed, and this is what we will show through an example while installing multi-boot syste, i.e a multi-boot for more than one operating system.

     

     

  2. create a multi-boot system

    to have a system with multi-boot you must start with a UEFI/BIOS system which already has Windows installed, and if your device came with a preinstalled windows then you may see a few more partitions that have already seen. And while the details may vary by manufacturer, but typically in addition to the [EFI partition | type: FAT32], it will also have a [Recovery partition | type: NTFS], a partition [Microsoft Reserved | type: unknown], a system partition [C: | type: NTFS] and a partition [Restore | type: NTFS].

    So if you already have Windows installed then in order to create your multi-boot system, you will have to make room on the disk for other OSes like Linux and its partitions [root, var, home, whatever…], but you can share the existing EFI boot partition with Windows if you want.

    You can use any disk partitioning program to shrink a large partition, also most Linux disk/partition management programs are free and able to shrink any Windows partition, but if this partition is the Windows 'C:' partition it is preferred to use the Windows disk management utility to shrink it.

    for this new example we will install the Windows then Linux using the manual and recommended method.

     

    The Recommended Method is to install the system with more partitions in order to have more stability for the system and have also dedicated partitions for your data files so that your data is safer if the system crashes.

    For Windows you can create the first partition [C: | with enough space from 50-100GB | format: NTFS], then create other partitions for your data [D: | with the space you have | format: NTFS], and to do that you can select the empty space to create new a partition to format yourself, after selecting the size (in MB) you want for 'C:', the system will ask you to create small System partitions in addition to the actual Windows install partition 'C:' so click "OK" and repeat the same process by selecting the empty spacy and enter the size of you want for your data Partition, then Leave these small system partitions alone and choose the first large partition for the install.

    You can also use the partition you just created for your files as a shared storage between the two systems that we will install. This is because Linux can handle partitions with Windows formats, but the Windows system does not support other than its formats only.

    win10_recommended-install

     

    the Windows system partitions for BIOS/MBR will be a Partition [System Reserved | 100MB] in addition to [C: partition | with the size you set].

    but for the UEFI/GPT it will be a [Recovery partition | 500MB], [EFI System partition | 100MB], a hidden Partition [MSR" | 16MB] for unknown reason in addition to The fourth [C: partition | with the size you set]. 

    win10_recommended-install_layout

     

    The next step is to Install the second OS (Linux) and if the distribution you choose supports UEFI then it will be able to read and analyze the disk partitioning, and handle the EFI boot partition requirement.

    Some distributions will create a new EFI boot partition, even if there is already one while others will share the existing one, also some distributions may give you more control than others during the process like (modifying the layout by giving the ability to choose to use the existing EFI boot or create new one and setting boot flag if required).

    So now we will start Partitioning the disk in Ubuntu linux with [EFI | 100 MB | format: efi] neglect this Partition if your are on BIOS/MBR, partition for boot files [/boot | 300-500 MB | format: ext4], partition for system files [/ | 8-15 GB | format: ext4], Partition for your data files [/home | with size as large as you need | format: ext4) and Partition [swap | with size normally twice your ram | format: swap].

    linux_recommended-install

     

    After completing the installation here is is a screenshot from inside this Linux system with GParted application for the disk Layout.

    linux_recommended-install_layout

     

    Notes on Multi-Booting:

    • If your PC/Laptop is runnig UEFI then first: make sure UEFI Secure Boot is disabled to save your self a lot of headaches, second: try out your Linux with the Live system to make sure it supports the UEFI firmware.

    • installing Linux from scratch takes about 15 minutes, so if you did assign a lot of space to one system and found that you don't have enough space for another, just do it over.

    • if you have created a partition for files to be viewed between your systems Then you can add that partition to '/etc/fstab' with a mount point like (/home/{your_user}/shared_data).

    • if you intend to install more than one Linux distribution, don’t use any partition that is part of the initial installation of any of the distributions like "/home" between other distributions to avoid a lot of issues.

     

     

  3. Issues with Linux and Windows Multi-Boot

     

    most of the times windows doesn’t like the idea of having another system besides it so with Windows updates you may experience issues with your Linux installation, and this can lead to many issues like:

     

    • UEFI boot priority list has been changed or "reset" if your system uses UEFI this may happen and the easiest way to check that your Linux or the second OS still exists is by hitting the "Boot Select" key while the system is starting up but it may differ form OEM to another but most likely it is F11 or F12, and if you see your second system listed in this menu then you didn’t loose your system and you can even enter the bios to edit the boot order the way it was, but if you did't find your second system boot option then It means that Windows corrupted these boot files.

    • Boot files has been destroyed or wiped out completely If you are using BIOS or UEFI with MBR partition table, or Windows and Linux systems are sharing the same EFI partition, you can use your Linux distribution CD to run a Live-Session and try to repair the boot responsible Program GRUB Boot Manager, but this is a story For another article.

 

 

 

Author Image
ragy soltan

About Author (BIO) I'm an Electric, Electronics & Communication engineer with a lot of Passion towards software technologies, and now i do backend web development with Python and JavaScript, Linux Operations and also Learning Vue (frontend web development) and Artificial intelligence.




0 - comments have been posted.
Add your Comment
Required for comment verification