Skip to content Skip to main navigation Skip to footer

Linux Installation Notes: Fedora

This article is to provide information for BootIt BM users who are installing the Fedora  distribution of Linux.

Latest version tested:  Fedora 21 Workstation (December 2014 release)

Overall summary: Fedora is a free distribution of Linux, sponsored by Redhat. The installation media uses a graphical installer, which provides a flexible array of partitioning options, including using existing partitions.

Starting with Fedora 18, a newly designed graphical installer was introduced, with significant changes from previous versions. The primary differences from the previous installer are that the partitioning screens have changed substantially, and there is no longer an option to install the Grub2 boot loader to a partition, which is required for it to boot from BootIt BM. The Grub2 choices with the new installer are to install it to the MBR (default), or to not install it at all.

The choice to not install Grub2 at all will result in Fedora not being bootable from BootIt BM after the install (and not bootable under any circumstances, without manual repair steps). The default choice of installing Grub2 to the MBR will result in Fedora being bootable via the MBR, but BootIt BM will be completely overwritten in the process, requiring that it be reinstalled afterwards. In addition, when BootIt BM is overwritten with primaries not limited, this can cause the loss of some primary partitions on HD0.

Since the Fedora installer no longer will install Grub2 to a partition, the recommended install procedure in this article works around this issue by using the following approach:

  • Back up the first track of Drive 0 to a UFD with 'dd' from the live Fedora desktop before starting the install
  • Allow the Fedora installer to install Grub2 to the MBR (the default action) during the install
  • After the install, boot up to Fedora and install Grub2 to a partition with 'grub2-install'
  • After the install, restore the first track of Drive 0 from the UFD with 'dd' from Fedora

Previous versions of this KB article did not install Grub at all during the initial installation, and then provided the steps to install it manually to a partition after the installation completed.  However, that procedure results in an incomplete installation that requires additional manual steps afterwards. Overall, it's an easier task to install Fedora as currently described in this article.

Starting with Fedora 16, Grub2 is used as the boot loader. In Fedora 16 and Fedora 17 there are options available to install it to the MBR (the default action), or to a partition's boot sector. If Grub2 gets installed to the MBR by mistake, it will completely overwrite BootIt BM, including the EMBR area of HD0. This will require that BootIt BM be reinstalled from scratch. This can also cause the loss of some partitions on HD0, if primaries are not limited in BootIt BM. Please see item 1 in the Additional Information section at the end of this article for more information on how to recover from this situation.

Please note that prior to Fedora 16, the Fedora distribution used the Grub legacy boot loader, and it was configured to overwrite only the MBR sector if installed to the MBR.  In this case,  BootIt BM can simply be reactivated by booting from the BootIt BM installation media, and then choosing the Reactivate option. A complete reinstall is not needed.

Warning: Working with partitions and boot loaders while installing any operating system can lead to data loss if mistakes are made. It is therefore highly recommended that all data be backed up before starting an installation.

Additional warning:  There is a significant chance of data loss if you allow the Fedora installer to make any structural partitioning changes while following the recommended steps listed below. This includes creating, deleting, moving, or resizing any partition, or using any of the installer's automatic partitioning modes.  As recommended in the installation procedure below, the safest choice is to create the partitions you need ahead of time in BootIt BM, and then simply choose them during the installation.

Recommended Fedora 21 installation steps for BootIt BM users: 

1. This procedure was written while using the Fedora 21 Workstation, 64-bit, 1.4 GiB Live Image ISO file. Although not specifically tested, the same procedure should also be applicable for the 32-bit Workstation version of the ISO file.

2. Important: Before the Fedora install, create a BootIt BM USB flash drive (UFD) with the included Makedisk utility, even if you don't normally use a UFD to install BootIt BM. The reason for this is to provide a known, convenient external drive to use in the procedure below to save/restore the first track backup file to/from (see steps 12-14 and 41-43). Safely remove the UFD for now, until it is called for in the later steps.

3. Important: Before the Fedora install, install BootIt BM first (if not already installed). With BootIt BM installed, make a note of which hard drive BootIt BM sees as Drive 0 (HD0) in Partition Work. Drive 0 will be the drive first displayed when you open Partition Work, and will be identified by number and size in the Drives drop down list in the upper left. In later steps, you will need to identify Drive 0 by size and/or the partitions it contains, in order to determine which drive it is in Linux. Please note that Drive 0 in BootiT BM will usually be /dev/sda in Linux, but there can be exceptions.

4. Important: Before the Fedora install, create the partitions for Fedora with BootIt BM. Fedora requires a root partition and a swap partition at a minimum. All Linux partitions except the swap partition should be created as Linux Native (type 131/83h). The swap partition should be created as Linux Swap (type 130/82h). Do not be concerned with formatting the partitions at this time. This will be done by the Fedora installer during the installation.

4a. Important: Before the Fedora install, highlight the first partition on Drive 0 in Partition Work, and then click Properties. In Properties, note the Start value in the LBA Information box. This value will usually be either 63 or 2048. If it's 63 (or lower), you will need to include this partition in your Fedora boot menu item in step 5 below, otherwise the beginning of the partition will be overwritten by the Fedora installer when it installs the Grub2 boot loader. Including the first partition in the Fedora boot item will make the installer aware that the partition exists, and it will then not overwrite it. Note that this issue can be avoided by using 1MiB alignment (partitions aligned on 1MiB boundaries) when partitioning the drive. In the BootIt BM Settings dialog, 1MiB alignment can be enabled by checking the "Align on 1MiB Boundaries" option in the Global Geometry and Alignment section.

5. Important: Before the Fedora install, create a boot menu item for Fedora in the Boot Edit dialog in BootIt BM. As explained in step 4a, if the first partition on the drive starts at LBA 63 (or lower), it must be included in the boot item, even if it's not a Fedora partition. Be sure to specify the partition to boot from. This will be the /boot partition if you have one, otherwise it will be the root partition. This will be the partition to install Grub2 to in a later step. Also be sure that all partitions created for Fedora are included in the MBR Details section of Boot Edit.

6. Important: Before the Fedora install, attempt to boot from the Fedora boot menu item created in step 5. This boot attempt will fail, but it will set up the partitions correctly in the MBR partition table so that the Fedora installer will see them as you specified in the Boot Edit dialog.

7. Important:  After step 6, reboot the system from the Fedora installation media, without booting from any other boot items in between.

8. When booting from the Fedora installation media, choose "Start Fedora Live" at the first screen. At the welcome screen,  choose "Try Fedora", and then select "Close" on the next screen. This will take you to the Fedora Live Desktop.

9. On the live desktop, click on "Activities" (upper left) and type "disks" w/o quotes in the text box (top center). That will bring up a Disks icon, which you can click on to open the Disks utility. The Disks utility will show the hard drives on the system, as well as the partitions on each one. Visible partitions on each disk will be as configured in Boot Edit in step 5.

10. Important: In the Disks utility, click on each Hard Disk in the Disk Drives section on the left. As each drive is highlighted, it's size, Linux drive designation, and partition information will be displayed on the right. Use this information to identify which drive was the one seen as Drive 0 in BootIt BM in step 3 above. This will usually be /dev/sda, but there can be exceptions. The Linux drive designation for Drive 0 will be needed in step 13 below, and again in step 42.

11. On the live desktop, open a terminal window by choosing "Activities" (upper left), and then typing "term" w/o quotes in the text box (top center). Click on the terminal icon that appears, to open the terminal window. In the terminal window, type "su" and then press <Enter> to become root.

12. Important: Insert the BootIt BM UFD created in step 2. Once inserted, it will be mounted automatically. Type the command 'df' in the terminal window to display the UFD device and mount path information. For the BootIt BM UFD, the mount path will be "/run/media/liveuser/BOOTITBM". The mount path will be used in the next step.

13. Important: Back up the first 63 sectors of BootItBM Drive 0 to the BootIt BM UFD. To do that, carefully type in and execute the 'dd' command shown below in the terminal window. Be sure to replace 'sdX' with the Linux drive designation, as determined to be Drive 0 in step 10 above (e.g. sda, sdb, etc.):

     dd  if=/dev/sdX of=/run/media/liveuser/BOOTITBM/drive0.bin count=63

     (replace 'sdX' above with the Linux drive determined to be Drive 0 in step 10)

An example of the 'dd' command line, and the resulting output that you can expect to see are shown below.:

[root@localhost liveuser]# dd if=/dev/sda of=/run/media/liveuser/BOOTITBM/drive0.bin count=63
63+0 records in
63+0 records out
32256 bytes (32 kB) copied, 0.00200314 s, 16.1 MB/s

After executing the 'dd' command above, check carefully that there are no error messages. If any errors are shown, check for typos, and recheck the mount path determined in step 10. Once the 'dd' command completes without error, verify that the file drive0.bin exists on the UFD, and that it is the correct size. To do that,  run the following command in the terminal window:

     ls  -l  /run/media/liveuser/BOOTITBM/drive0.bin

The file drive0.bin should be listed, and should be 32,256 bytes in size. This file will be used to restore BootIt BM to the first track after the Fedora installation has completed (steps 41-43).

14. Unmount the Bootit BM UFD by running the following command in the terminal window:

     umount  /run/media/liveuser/BOOTITBM

Verify that it has been unmounted by running 'df' again. The line showing the UFD and its mount path should now be gone. The UFD can be safely removed after being unmounted. Note that you can also use the Eject item on the screen, if available, to unmount/eject the UFD.

15. From the Activities menu, choose the "Install to Hard Drive" item to start the Fedora installation. Proceed through the subsequent screens until you get to the Installation Summary screen.

16. On the Installation Summary screen, select "Installation Destination", which will take you to the Installation Destination screen.

17. Important: The Installation Destination screen should show an icon for each hard drive. The first drive should be /dev/sda, the second drive /dev/sdb, etc.  For BootIt BM Drive 0, and for any other drive(s) containing partitions to be included in the Fedora installation, ensure that a check mark exists just below the hard drive icon. If not, click on the drive to get the check mark to appear. Note that clicking on a drive will toggle the check mark on/off for that drive. To clarify: when finished with this step, BootIt BM Drive 0 (as determined in step 10) should be checked, and each additional drive containing partitions to be included in the Fedora installation should also be checked.

18. On the Installation Destination screen click on "Full disk summary and bootloader" (lower left) to open the Selected Disks dialog. The Selected Disks dialog will list all drives checked in step 17.

19. Important: In the Selected Disks dialog, ensure that BootIt BM Drive 0 (as determined in step 10) is checked as the boot drive in the Boot column. If not, highlight that drive and click on "Set as Boot Device" to set that drive as the one that Grub will be installed to. Click on Close to return to the Installation Destination screen.

20. Important: On the Installation Destination screen, select "I will configure partitioning" in the "Other Storage Options" section. 

21. On the Installation Destination screen click on Done (upper left). This should take you to the Manual Partitioning screen.

22. Important: On the Manual Partitioning screen, select "Standard Partition" from the drop down list on the left.

23. On the Manual Partitioning screen, expand the "Uknown" section of partitions on the left, if not already expanded. In the "Unknown" section, you should see the root and swap partitions (and other Fedora partitions as applicable) that you created in step 4. If you do not see all of the Fedora partitions created in step 4, then you will need to go back and ensure that you followed steps 4 through 7 correctly.

Note: To clarify step 23, the above information is assuming a completely new installation. If one of the drives already contains an existing Fedora installation whose partitions are visible to the Fedora installer (i.e. are loaded in the MBR), there will be another expandable section on the left named "Fedora Linux XX for X86_64" or similar. If you intend to install over the top of the existing installation, then you will need to select your partitions from that section in the steps below, rather than from the "Unknown" section.

24. In the "Uknown" section of partitions, identify and highlight your Fedora root partition. On the right side of the screen, check the Reformat check box.

25. In the File System drop down list, select the file system for the root partition. The ext4 file system is recommended. In the Mount Point box, enter a "/" for root partition. If you want to use a label for the root partition, enter that in the Label box.

26. When satisfied with your selections for the root partition, select Update Settings. That will move the root partition from the "Unknown" section to the "New Fedora 21 Installation" section on the left.

27. Re-expand the "Unknown" section on the left, and then identify and highlight your Fedora swap partition. On the right side of the screen, check the Reformat check box.

28. In the File System drop down list, select "swap" for the file system. If you want to use a label for the swap partition, you can enter that in the Label box.

29. When satisfied with your selections for the swap partition, select Update Settings. That will move the swap partition from the "Unknown" section to the "New Fedora 21 Installation" section on the left.

30. If you are using any additional partitions, such as for /boot or /home, repeat the steps above (i.e. steps 24 through 26) to configure those partitions. Be sure to choose the correct mount points ; i.e. choose /home as the mount point for the /home partition, and /boot as the mount point for the /boot partition. Each additional partition that you configure should end up being listed in the "New Fedora" section on the left of the screen.

31. When finished configuring partitions, carefully review all information on the Manual Partitioning screen. When satisfied with the partition configuration, click on the Done button at the top left of the screen. That will open the Summary of Changes dialog.

32. Carefully review all of the information in the Summary of Changes dialog. If satisfied that all is correct, select Accept Changes to return to the Installation Summary screen. Otherwise, you can select Cancel & Return to return to the Custom Partitioning screen to make changes.

33. If all looks correct on the Installation Summary screen, then select Begin Installation at the bottom right of the screen. That will start the actual installation to the hard drive. You will be prompted to set the root password and create a user while the installation is proceeding. Creating a user at this point is optional, but if creating one, it is suggested that you check the "Make this user administrator" check box. This will enable 'sudo' for that user. If you do not create a user now, you will be prompted to create one on the first boot into Fedora.

34. When installation completes, select Quit at the bottom right. That takes you back to the Fedora Live Desktop. At this point, the Grub2 boot loader has been installed to the MBR, meaning that BootItBM will not appear when you reboot the system. Instead, the system will boot up to the Grub2 menu, from where you can boot into Fedora.

35. Reboot the system up into the new Fedora installation. If the system starts booting from the installation media again, you will have an opportunity to remove the installation media at the Start Fedora Live screen, and then reboot the system again to boot into the new Fedora installation. On the first boot, you will prompted to create a user (if not already done in step 33), and some other items. If creating a user, it is suggested that you  check the "Make this user administrator" check box. This will enable 'sudo' for that user.

36. Important: Once logged into the Fedora desktop, the next step is to manually install Grub2 to the root partition, or to the /boot partition if you have one. To do that, open a terminal window by choosing Activities, then type "term" in the text box. Click on the terminal icon that appears to open the terminal window. In the terminal window, type "su" and then press <Enter> to become root. Enter the root password when prompted to get root privileges.

37. Important: At the prompt, run the 'df' command to list mounted file systems. The list of mounted file systems should include the root partition (/), and the /boot partition (/boot) if you have one. If you don't have a /boot partition, make a note of the partition designation for the root partition, and then continue with step 38. If you do have a /boot partition, then make a note of the partition designation for /boot, and then continue with step 39 instead. Note that the boot loader needs to be installed to same partition that you set up as the partition to boot from in step 5.

38. Important: At the prompt, type the following command to install Grub2 to the root partition. Note that the root partition designation "/dev/sda1" used below is just an example. You will need to know and use your actual root partition designation, as determined in step 37 above.

     grub2-install  --force  /dev/sda1

    (/dev/sda1 above is an example - replace with actual root partition from step 37)

There will be a warning about using blocklists, but as long as you get the message "Installation finished. No error reported" on the last line of the output, that means Grub2 was successfully installed to the partition's boot sector. Skip to step 40 to continue this procedure.

39. Important: At the prompt, type the following command to install Grub2 to the /boot partition. Note that the /boot partition designation "/dev/sda1" used below is just an example. You will need to know and use your actual /boot partition designation, as determined in step 37 above.

     grub2-install  --force  /dev/sda1

     (/dev/sda1 above is an example - replace with actual /boot partition from step 37)

There will be a warning about using blocklists, but as long as you get the message "Installation finished. No error reported" on the last line of the output, that means Grub2 was successfully installed to the partition's boot sector.

40. Important: With the terminal window still open, run the 'grub2-mkconfig' command as shown below to update the grub2 configuration file located at /boot/grub2/grub.cfg.

     grub2-mkconfig  -o  /boot/grub2/grub.cfg

An example of the typical output of this command is shown below for reference:

[root@localhost user]# grub2-mkconfig -o /boot/grub2/grub.cfg
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-3.11.10-301.fc20.x86_64
Found initrd image: /boot/initramfs-3.11.10-301.fc20.x86_64.img
Found linux image: /boot/vmlinuz-0-rescue-4e3706d5223a489b8a6dca270df4cc73
Found initrd image: /boot/initramfs-0-rescue-4e3706d5223a489b8a6dca270df4cc73.img
done

41. Important: With the terminal window still open, insert the BootIt BM UFD that you used in steps 12-14. Once inserted, it will be mounted automatically. Type 'df' in the terminal window to display the UFD device and mount path information. For the BootIt BM UFD, the mount path should be "/run/media/<user>/BOOTITBM"m where <user> is the user name that you are logged in as. The mount path will be used in the next step.

42. Important: Restore the first 63 sectors of BootIt BM Drive 0 from the file drive0.bin that was saved to the BootIt BM UFD in step 13. To do that, carefully type in and execute the 'dd' command shown below in the terminal window. Be sure to replace 'sdX' with the Linux drive designation for Drive 0 as determined in step 10 above (e.g. sda, sdb, etc.).

     dd  if=/run/media/<user>/BOOTITBM/drive0.bin of=/dev/sdX count=63

     (replace 'sdX' above with the Linux drive determined to be Drive 0 in step 10)

An example of the 'dd' command line, and the resulting output and the resulting output that you can expect to see are shown below.:

[root@localhost user]# dd if=/run/media/user/BOOTITBM/drive0.bin of=/dev/sda count=63
63+0 records in
63+0 records out
32256 bytes (32 kB) copied, 0.00566892 s, 5.7 MB/s

After executing the 'dd' command above, check carefully that there are no error messages. If any errors are shown, check for typos, and recheck the UFD mount path as determined in step 41. Then run the 'dd' command again, until it completes without any error messages.

43. Unmount the Bootit BM UFD by running the following command in the terminal window:

     umount  /run/media/<user>/BOOTITBM

Verify that it has been unmounted by running 'df' again. The line showing the UFD and its mount path should now be gone. The UFD can be safely removed after being unmounted. Note that you can also use the Eject item on the screen, if available, to unmount/eject the UFD.

44. On the next reboot, BootIt BM should be back, and you should be able to boot normally into Fedora using the boot item created in step 5.

45. If Fedora does not boot from the BootIt BM menu as expected, recheck that the boot item is correctly configured in Boot Edit. Another important item to check is whether or not the partition that you installed Grub2 to in step 38 (root partition), or step 39 (/boot partition) is considered to be bootable by BootIt BM. To determine this, go to Partition Work, highlight the partition, and select Properties. It should say "Bootable: Yes" in the Additional Information section. If not, the Grub2 boot loader did not get installed in step 38 or 39, or may have gotten installed to the wrong partition. This should be correctable by reinstalling Grub2 to the correct partition - see Item 2 under Additional Information below.

Additional Information:

1. There is a significant chance of data loss if you are not limiting primaries in BootIt BM and you allow the Fedora installer to make any partitioning changes, or to use any of its automatic partitioning methods. The reason for this is that with primaries not limited, the Fedora installer can overwrite partitions that it is not aware of because they are not present in the MBR during the installation. As recommended above, the safest choice is to create the partitions you need ahead of time in BootIt BM, and then assign them during installation.

2. If Fedora does not boot from the BootIt BM menu in step 44 above, you most likely can correct that situation by reinstalling Grub2 to the correct partition. Because BootIt BM has now overwritten Grub2 in the MBR, you will need to follow the procedure in the KB article linked to below, which covers how to get booted into Fedora manually from a Grub2 boot disk, so that you can then reinstall Grub2 with the 'grub2-install' command.

Grub Article #4 - How to reinstall Grub2

3. For Fedora 16 or Fedora 17, installing Grub2 to the MBR by mistake will completely overwrite BootIt BM, including the EMBR area on HD0. This will require that BootIt BM be reinstalled from scratch. If you are NOT limiting primaries in BootIt BM, this situation can also cause some partitions on HD0 to disappear (get deleted), although in most cases, they will be recoverable by using the BootIt BM undelete feature. For more information on this situation, and how to recover from it, please refer to the following KB article:

Grub Article #3 - How to recover from Grub being installed to the MBR

4. For Fedora 15 (or older), Grub legacy is the boot loader, and installing it to the MBR will only require reactivating BootIt BM, by booting from the BootIt BM installation media, and then choosing the Reactivate option. A complete reinstall is not needed. Note that the KB article linked to above (Grub Article #3) also covers this situation.

Was This Article Helpful?

0