Multi-booting

Last updated
GRUB, with entries for Ubuntu and Windows Vista, an example of dual booting GRUB with ubuntu and windows vista.png
GRUB, with entries for Ubuntu and Windows Vista, an example of dual booting

Multi-booting is the act of installing multiple operating systems on a single computer, and being able to choose which one to boot. The term dual-booting refers to the common configuration of specifically two operating systems. Multi-booting may require a custom boot loader.

Contents

Usage

Multi-booting allows more than one operating system to reside on one computer; for example, if a user has a primary operating system that they use most frequently and an alternate operating system that they use less frequently. Multi-booting allows a new operating system to configure all applications needed and migrate data before removing the old operating system, if desired. Another reason for multi-booting can be to investigate or test a new operating system without switching completely.

Multi-booting is also useful in situations where different software requires different operating systems. A multi-boot configuration allows a user to use all of their software on one computer. This is often accomplished by using a boot loader such as NTLDR, LILO, or GRUB which can boot more than one operating system.

Multi-booting is also used by software developers when multiple operating systems are required for development or testing purposes. Having these systems on one machine is a way to reduce hardware costs.

Multi-booting also allows a user to switch between private and work dedicated systems to maintain access integrity and separation between the two user environments, even if the same operating system is used for each of them.

A possible alternative to multi-booting is virtualization, where a hypervisor is used to host one or more virtual machines running guest operating systems.

Technical issues

Number of operating systems per volume (logical drive)

In an OS/2 dual-boot configuration, the C drive can contain both DOS and OS/2. The user issues the BOOT command [1] from the DOS or OS/2 command line to do the necessary copy, move and rename operations and then reboot to the specified system on C:. Other systems provide similar mechanisms for alternate systems on the same logical drive.

Number of operating systems per storage device

In a multi-boot computer each of the multiple operating systems can reside on its own storage device, or some storage devices might contain more than one operating system in different partitions. The boot loader in or loaded by the MBR displays a menu of logical drives and loads the selected boot loader from the PBR of that drive.

An example of a computer with one operating system per storage device is a dual-booting computer that stores Windows on one disk drive and Linux on another disk drive. In this case a multi-booting boot loader is not strictly necessary because the user can choose to enter BIOS configuration immediately after power-up and make the desired drive first in the boot-order list. However, it is more convenient to have a multi-booting boot loader on one of the drives, set BIOS once to always start booting from (i.e. load the boot loader from) that drive, and then allow the user to choose an operating system from that boot loader's menu. No special disk partitioning is necessary when each operating system has its own dedicated disk drive.

An example of a computer with multiple operating systems per storage device is a dual-booting computer that stores both Windows and Linux on the same disk drive but where the BIOS in the system does not let the user boot individual drives and partitions. In this case a multi-booting boot loader is necessary. Also, the disk must be partitioned to give each operating system its own partition on the disk drive. This is necessary because each system has its own set of files and operating instructions. Also, when a completely separate operating system is used partitions may need to be formatted to a different format. For example, if a user intends to install both Windows and Linux, then the Windows partition will be most likely formatted in the NTFS format as Windows cannot run off of ext4, and the Linux partition will most likely be formatted in the ext4 file format as Linux cannot run off of NTFS. However, if a user intends to dual-boot two versions of Windows (i.e. Windows 7 and Windows Vista) or two versions of Linux (i.e. Linux Mint and Ubuntu Linux), then the same file system (e.g. NTFS or ext4) can be used across both drives and partitions.

Partitioning

The basic concept involves partitioning a disk to accommodate each planned installation, usually including separate partitions for boot, root, data storage and backups.[ citation needed ]

MBR loader

An MBR loader, such as Air-Boot, replaces the standard boot code in track 0 with code that displays a selection menu and loads the selected system. Some, e.g., Air-Boot, can be configured either automatically or by the user at boot time, rather than requiring an external configuration menu.

Linux boot loaders

Linux loaders such as GRUB and LILO, can reside in the MBR or in a PBR. They use configuration files in /boot to control their selection menus,

OS/2 Boot Manager

The OS/2 Boot Manager must be installed in a primary partition. The OS/2 partitioning utilities can configure up to four systems in the menu, each of which can be either in a primary partition or in a logical volume within the extended logical partition. It is possible to include a boot loader such as GRUB in the OS/2 Boot Manager menu, and it is possible to include the OS/2 Boot Manager in the menu for another boot loader. Newer loaders such as Air-Boot, GRUB and LILO offer more flexibility.

Microsoft Windows and Linux

One popular multi-boot configuration is to dual-boot Linux and Windows operating systems, each contained within its own partition. Windows does not facilitate or support multi-boot systems, other than allowing for partition-specific installations, and no choice of boot loader is offered. However, most current Linux installers accommodate dual-booting (although some knowledge of partitions is desirable). Commonly installations proceed without incident but upon restart, the boot loader will recognize only one of the two operating systems. [2]

There are some advantages to installing a Linux boot manager/loader (usually GRUB) as the primary bootloader pointed to by the master boot record. Windows operating systems will be found by properly installed Linux bootloaders, but Windows boot managers do not recognize Linux installations (nor does Windows deal natively with Linux file systems). The MBR boot code can be backed up and restored with dd, available on System Rescue CD.

It is often recommended that Windows be installed to the first primary partition. The boot loaders of both Windows and Linux identify partitions with a number derived by counting the partitions. (Note, both Windows and Linux count the partitions according to the ordering of the partitions in the partition table, which may be different from the order of the partitions on the disk.) Adding or deleting a partition at the end of a hard drive will have no effect on any partitions prior to it. However, if a partition is added or deleted at the beginning or middle of a hard drive, the numbering of subsequent partitions may change. If the number of the system partition changes, it requires boot loader reconfiguration in order for an operating system to boot and function properly.

Windows must be installed into a primary partition (and in older systems this must be the first partition). Linux can be installed into a partition in any position on the hard drive and can also be installed into logical partitions (within the extended partition). If Linux is installed into a logical partition within the extended partition, it is unaffected by changes in the primary partitions.

Neutral MBR

An alternative to storing GRUB in the MBR is keeping Windows' or other generic PC boot code in the MBR, and installing GRUB or another bootloader into a primary partition other than that of Windows, thus keeping the MBR neutral. [3] Operating system selection at boot time consequently depends on the bootloader configured within the primary partition that has the boot or "active" flag set on its partition table entry, which could be a bootloader of DOS, OS/2, eComStation, ArcaOS [4] or BSD, in addition to Linux or Windows.

With the boot flag set on the Windows primary, the Windows Boot Manager can be used to chainload another installed bootloader through use of a program like EasyBCD. [5] This means the active partition's boot manager will first prompt the user for selection what OS to boot, then load another if necessary, such as GRUB, even a bootloader installed to a logical partition, and then GRUB will load the Linux kernel as it normally would were GRUB installed to the MBR.

The active partition could also be one that exists for no purpose other than choosing an operating system to boot, such as the boot manager that shipped with IBM's OS/2 Warp and its derivatives.

Apple's Boot Camp

Boot Camp allows owners of Intel-based Apple Macintosh computers to install Windows XP, Vista, 7, 8, and 10 on their Macs. The software was initially available in beta version as a download from Apple's website (which was compatible with Mac OS X version 10.4 (Tiger)), and later came bundled with Mac OS X since version 10.5 (Leopard).

Boot Camp allows non-destructive disk partitioning and resizing of HFS+ filesystems, boot menu options, and an option to burn a CD with necessary device drivers. Since Windows XP is incompatible with Extensible Firmware Interface (the successor to legacy BIOS), the firmware on early Intel Macs needs to be updated to support BIOS emulation first. BIOS emulation is achieved with a compatibility support module (CSM). Apple does not support non-Windows partition formats or drivers so therefore configuring other operating systems is not directly possible through Boot Camp itself. However, any operating system which can utilize the BIOS emulation of Intel Macintosh can be made to work, including non-XP versions of Windows. The Ubuntu Linux distribution is particularly popular for this purpose because they provide an option to use proprietary device drivers along with open source drivers.

See also

Related Research Articles

<span class="mw-page-title-main">Booting</span> Process of starting a computer

In computing, booting is the process of starting a computer as initiated via hardware such as a button on the computer or by a software command. After it is switched on, a computer's central processing unit (CPU) has no software in its main memory, so some process must load software into memory before it can be executed. This may be done by hardware or firmware in the CPU, or by a separate processor in the computer system.

<span class="mw-page-title-main">Disk partitioning</span> Creation of separate accessible storage areas on a secondary computer storage device

Disk partitioning or disk slicing is the creation of one or more regions on secondary storage, so that each region can be managed separately. These regions are called partitions. It is typically the first step of preparing a newly installed disk after a partitioning scheme is chosen for the new disk before any file system is created. The disk stores the information about the partitions' locations and sizes in an area known as the partition table that the operating system reads before any other part of the disk. Each partition then appears to the operating system as a distinct "logical" disk that uses part of the actual disk. System administrators use a program called a partition editor to create, resize, delete, and manipulate the partitions. Partitioning allows the use of different filesystems to be installed for different kinds of files. Separating user data from system data can prevent the system partition from becoming full and rendering the system unusable. Partitioning can also make backing up easier. A disadvantage is that it can be difficult to properly size partitions, resulting in having one partition with too much free space and another nearly totally allocated.

<span class="mw-page-title-main">GNU GRUB</span> Boot loader package

GNU GRUB is a boot loader package from the GNU Project. GRUB is the reference implementation of the Free Software Foundation's Multiboot Specification, which provides a user the choice to boot one of multiple operating systems installed on a computer or select a specific kernel configuration available on a particular operating system's partitions.

NTLDR is the boot loader for all releases of Windows NT operating system from 1993 with the release of Windows NT 3.1 up until Windows XP and Windows Server 2003. From Windows Vista onwards it was replaced by the BOOTMGR bootloader. NTLDR is typically run from the primary storage device, but it can also run from portable storage devices such as a CD-ROM, USB flash drive, or floppy disk. NTLDR can also load a non NT-based operating system given the appropriate boot sector in a file.

<span class="mw-page-title-main">Live CD</span> Complete, bootable computer installation that runs directly from a CD-ROM

A live CD is a complete bootable computer installation including operating system which runs directly from a CD-ROM or similar storage device into a computer's memory, rather than loading from a hard disk drive. A live CD allows users to run an operating system for any purpose without installing it or making any changes to the computer's configuration. Live CDs can run on a computer without secondary storage, such as a hard disk drive, or with a corrupted hard disk drive or file system, allowing data recovery.

<span class="mw-page-title-main">Bootloader</span> Software responsible for starting the Computer and Load other software to the CPU memory

A bootloader, also spelled as boot loader or called bootstrap loader, is a computer program that is responsible for booting a computer. If it also provides an interactive menu with multiple boot choices then it's often called a boot manager.

<span class="mw-page-title-main">UEFI</span> Technical specification for firmware architecture

Unified Extensible Firmware Interface is a specification for the firmware architecture of a computing platform. When a computer is powered on, the UEFI-implementation is typically the first that runs, before starting the operating system. Examples include AMI Aptio, Phoenix SecureCore, TianoCore EDK II, InsydeH2O.

<span class="mw-page-title-main">GUID Partition Table</span> Computer disk partitioning standard

The GUID Partition Table (GPT) is a standard for the layout of partition tables of a physical computer storage device, such as a hard disk drive or solid-state drive, using universally unique identifiers (UUIDs), which are also known as globally unique identifiers (GUIDs). Forming a part of the Unified Extensible Firmware Interface (UEFI) standard, it is nevertheless also used for some BIOSs, because of the limitations of master boot record (MBR) partition tables, which use 32 bits for logical block addressing (LBA) of traditional 512-byte disk sectors.

The Logical Disk Manager (LDM) is an implementation of a logical volume manager for Microsoft Windows NT, developed by Microsoft and Veritas Software. It was introduced with the Windows 2000 operating system, and is supported in Windows XP, Windows Server 2003, Windows Vista, Windows 7, Windows 8, Windows 10 and Windows 11. The MMC-based Disk Management snap-in hosts the Logical Disk Manager. On Windows 8 and Windows Server 2012, Microsoft deprecated LDM in favor of Storage Spaces.

An extended boot record (EBR), or extended partition boot record (EPBR), is a descriptor for a logical partition under the common DOS disk drive partitioning system. In that system, when one partition record entry in the master boot record (MBR) is designated an extended partition, then that partition can be subdivided into a number of logical partitions. The actual structure of that extended partition is described by one or more EBRs, which are located inside the extended partition. The first EBR will always be located on the first sector of the extended partition.

<span class="mw-page-title-main">Boot Camp (software)</span> Built-in macOS software to natively install Microsoft Windows on a Mac.

Boot Camp Assistant is a multi boot utility included with Apple Inc.'s macOS that assists users in installing Microsoft Windows operating systems on Intel-based Macintosh computers. The utility guides users through non-destructive disk partitioning of their hard disk drive or solid-state drive and installation of Windows device drivers for the Apple hardware. The utility also installs a Windows Control Panel applet for selecting the default boot operating system.

<span class="mw-page-title-main">Live USB</span> USB drive with a full bootable operating system

A live USB is a portable USB-attached external data storage device containing a full operating system that can be booted from. The term is reminiscent of USB flash drives but may encompass an external hard disk drive or solid-state drive, though they may be referred to as "live HDD" and "live SSD" respectively. They are the evolutionary next step after live CDs, but with the added benefit of writable storage, allowing customizations to the booted operating system. Live USBs can be used in embedded systems for system administration, data recovery, or test driving, and can persistently save settings and install software packages on the USB device.

<span class="mw-page-title-main">EFI system partition</span> Partition used by Unified Extensible Firmware Interface

The EFIsystem partition or ESP is a partition on a data storage device that is used by computers that have the Unified Extensible Firmware Interface (UEFI). When a computer is booted, UEFI firmware loads files stored on the ESP to start operating systems and various utilities.

<span class="mw-page-title-main">Windows Boot Manager</span> Boot process used in modern Windows NT-based products

The Windows Boot Manager (BOOTMGR) is the bootloader provided by Microsoft for Windows NT versions starting with Windows Vista and Windows Server 2008. It is the first program launched by the BIOS or UEFI of the computer and is responsible for loading the rest of Windows. It replaced the NTLDR present in older versions of Windows.

The Linux booting process involves multiple stages and is in many ways similar to the BSD and other Unix-style boot processes, from which it derives. Although the Linux booting process depends very much on the computer architecture, those architectures share similar stages and software components, including system startup, bootloader execution, loading and startup of a Linux kernel image, and execution of various startup scripts and daemons. Those are grouped into 4 steps: system startup, bootloader stage, kernel stage, and init process. When a Linux system is powered up or reset, its processor will execute a specific firmware/program for system initialization, such as the power-on self-test, invoking the reset vector to start a program at a known address in flash/ROM, then load the bootloader into RAM for later execution. In IBM PC–compatible personal computers (PCs), this firmware/program is either a BIOS or a UEFI monitor, and is stored in the mainboard. In embedded Linux systems, this firmware/program is called boot ROM. After being loaded into RAM, the bootloader will execute to load the second-stage bootloader. The second-stage bootloader will load the kernel image into memory, decompress and initialize it, and then pass control to this kernel image. The second-stage bootloader also performs several operation on the system such as system hardware check, mounting the root device, loading the necessary kernel modules, etc. Finally, the first user-space process starts, and other high-level system initializations are performed.

HyperSpace is an instant-on Linux-based operating system that has been developed by Phoenix Technologies. It is an application environment that can run either independently or side-by-side with a traditional operating system such as Microsoft Windows.

<span class="mw-page-title-main">EasyBCD</span> Software for Microsoft Windows

EasyBCD is a program developed by NeoSmart Technologies to configure and tweak the Boot Configuration Data (BCD), a boot database first introduced in Windows Vista and used in all subsequent Windows releases. EasyBCD can be used to set up multi-boot environments for computers on which some versions of Windows, Linux, BSD and Mac OS X can be simultaneously installed; EasyBCD can also be used for adding entries to bootable tools and utilities, as well as modifying and controlling the behavior of the Windows boot menu. EasyBCD 2.3 introduced additional support for creating and managing entries for UEFI-based Windows entries in the boot menu. As of June 20, 2011 with the release of EasyBCD 2.1, it is no longer free for use in commercial environments which require the purchase of a paid license, however it remains free for home and non-profit use without limitations.

<span class="mw-page-title-main">Windows Setup</span> Installer that prepares a hard disk drive for a Microsoft Windows operating system installation

Windows Setup is an installer that prepares a computer for a Microsoft Windows installation by allowing the user to pick installation settings and copying the files to the drive.

A master boot record (MBR) is a type of boot sector in the first block of partitioned computer mass storage devices like fixed disks or removable drives intended for use with IBM PC-compatible systems and beyond. The concept of MBRs was publicly introduced in 1983 with PC DOS 2.0.

A boot flag is a 1-byte value in a non-extended partition record, within a master boot record. It appears at the beginning of a partition record, as the value 0x80. A value of 0x00 indicates the partition does not have the boot flag set. Any other value is invalid.

References

  1. "OS/2 commands by name", OS/2 command reference (First ed.), IBM, 1999, Switches between the DOS and OS/2 operating systems that are on the same hard disk (drive C).
  2. "Booting problem of Linux in Windows boot loader - [Solved] - Open source software". Tom's Hardware. 15 April 2014. Retrieved 2 April 2018.
  3. "openSUSE Bugs/grub". openSUSE Bugs/grub. 28 January 2010. Retrieved 22 January 2017.
  4. "ArcaOS". Blue Lion, by Arca Noae. 13 November 2016. Retrieved 22 January 2017.
  5. "How to add an entry for a Linux distribution in Windows' boot menu". Linux BSD OS. 21 July 2012. Retrieved 10 July 2016.