Configuring grub-pc

Forum Forums New users New Users and General Questions Configuring grub-pc

  • This topic has 12 replies, 6 voices, and was last updated Aug 12-7:39 pm by olsztyn.
Viewing 13 posts - 1 through 13 (of 13 total)
  • Author
    Posts
  • #40165
    Member
    steve_anunknown

      Hello people!
      Please excuse my lack of knowledge if my problem is trivial.
      I got a notification that some updates were available, so obviously I just updated my system. However, after the update, a window poped up with the following message:

      “The grub-pc package is being upgraded. This menu allows you to select which devices you’d like grub-install to be automatically run for, if any.
      Running grub-install automatically is recommended in most situations, to prevent the installed GRUB core image from getting out of sync with GRUB modules or grub.cfg.
      If you are unsure which drive is designated as boot drive by your BIOS, it is often a good idea to install GRUB to all of them.
      Note: —Some Note— (I’m not quoting it because the content changed after pressing “ok” and I can’t find a way to return)
      <<Ok option>>”

      After selecting the “OK” option, I’m presented with options of devices to install GRUB to:
      “/dev/sda (60011 MB; FUJITSU_MHW2060BH) , /dev/sda1 (57830 MB; /)” which I’m guessing is the hard drive of the device and the root partition (correct me if I’m wrong).

      As I understand it, I should probably select /dev/sda , however my device is librebooted and I don’t know if there are any complications lurking.

      Should I just do it , can I ignore it? I’m a little skeptical because , as I was searching through forums, I came across some unpleasant experiences.

      Thanks in advance!

      #40170
      Member
      Xecure
        Helpful
        Up
        0
        ::

        After selecting the “OK” option, I’m presented with options of devices to install GRUB to:
        “/dev/sda (60011 MB; FUJITSU_MHW2060BH) , /dev/sda1 (57830 MB; /)”

        I think you can only install it in a partition and not a main drive.
        Use arrows to select the partition sda1, use space to activate the selection, and see if you can also do so for the drive sda. hit enter when ready for installing/updating grub. It doesn’t matter if you install it in all of them.

        As I understand it, I should probably select /dev/sda , however my device is librebooted and I don’t know if there are any complications lurking.

        Should I just do it , can I ignore it? I’m a little skeptical because , as I was searching through forums, I came across some unpleasant experiences.

        I don’t think it will afect the BIOS, so no worries there. But my experience with upgrading grub has always brught me trouble. I recently upgraded grub, the same as you are doing, and had to repair it with a upgraded antiX live system and rechecked the correct boot and bios_grub flags.

        If you have any problems after upgrading grub I will help you as best I can. Know that you can restore your grub no matter how bad the stupid grub upgrade installer is.

        antiX Live system enthusiast.
        General Live Boot Parameters for antiX.

        #40171
        Member
        steve_anunknown
          Helpful
          Up
          0
          ::

          Hey Xecure,

          I appreciate your willingness to help me after the update.

          It seems that your advice clashes with the information I have gathered from my searching through forums.

          I think you can only install it in a partition and not a main drive.

          However, some other people agree that:
          “In your case, the correct selection is /dev/sda, the first one. It’s the first and only hard disk in your system, whereas /dev/sda1 is a partition on that hard disk. You can install grub on a partition, but it’s a “BAD idea”.” (ubuntu forum)

          In your defense, what I’m quoting is really(!) old (9 years), so maybe things were different back then. I’m saying all this in order to clarify why I’m a little insecure with the whole process. Maybe another person could speak up and resolve the dilemma.

          Out of curiosity, ignoring the update maybe is not wise, right?

          #40172
          Moderator
          Brian Masinick
            Helpful
            Up
            0
            ::

            Suppose your main drive is sda and the device name for the drive is /dev/sda.
            If you want the boot loader installed for the entire disk, /dev/sda is the correct choice.
            If you want the boot loader installed for only a specific distribution, you can install it where that distribution is installed.
            IF that is /dev/sda6, that’s fine; if you want BOTH, that is allowed with the GRUB boot loader.

            --
            Brian Masinick

            #40177
            Member
            olsztyn
              Helpful
              Up
              0
              ::

              You can install grub on a partition, but it’s a “BAD idea”.” (ubuntu forum)

              Check if this statement was possibly taken out of broader context. It all depends what you want to do and masinick outlined various options.
              When you have multiboot or dual boot system such as Windows/Linux residing in separate partitions it is good to give thought how you want to design boot architecture.
              On one or two of my laptops I have Grub installed on sda, on some others I have Grub entries on a partition and on three main laptops I do not Grub installed at all, with syslinux as boot loader for Linux and Windows boot loader for Win 10. In this particular case it is not Grub that serves as boot manager.
              On the heels of this I should add one often overlooked capability of antiX that it lets you boot Linux partitions or Windows partitions thanks to that it finds all existing:
              – Widows bootloaders
              – Linux Grub bootloaders
              – Grub menu entries

              After finding them it creates a menu of bootable systems for you to select and boots your selection. There are out there dedicated utilities to boot your partitions (boot managers) but none seems more capable than what antiX has all this built in.
              This great antiX feature is not much exposed though, unfortunately…

              Live antiX Boot Options (Previously posted by Xecure):
              https://antixlinuxfan.miraheze.org/wiki/Table_of_antiX_Boot_Parameters

              #40178
              Member
              steve_anunknown
                Helpful
                Up
                0
                ::

                I installed it on /dev/sda as I have no intention of multibooting or doing anything out of the ordinary really. Shutted down the laptop and turned it on again and everything turned out just fine.

                Thank you all for your valuable input!

                #40179
                Moderator
                Brian Masinick
                  Helpful
                  Up
                  0
                  ::

                  At any given time, only ONE boot loader record can effectively boot your system, but if you do it right, you can have extra copies of the boot loader on every /boot directory structure of every distribution you have loaded, so if you are a person that boots multiple systems from the same computer, GRUB (both the OLD Legacy version and current GRUB 2 implementations) can control the boot process.

                  The Master Boot Record (MBR) is usually installed on the primary device, so if that device is /dev/sda, that’s where you put your primary boot entry. In addition to this you can have boot loader configurations on each distribution partition and if you decide to make a different system control the boot loader, you simply install grub from that distribution.

                  4.1 Installing GRUB using grub-install – section 4.1 in the GNU GRUB Manual, explains the details.
                  http://www.gnu.org/software/grub/manual/grub/grub.html#Installing-GRUB-using-grub_002dinstall

                  Here’s what it says:
                  grub-install /dev/sda

                  But all the above examples assume that GRUB should put images under the /boot directory. If you want GRUB to put images under a directory other than /boot, you need to specify the option –boot-directory. The typical usage is that you create a GRUB boot floppy with a filesystem. Here is an example:

                  # mke2fs /dev/fd0
                  # mount -t ext2 /dev/fd0 /mnt
                  # mkdir /mnt/boot
                  # grub-install --boot-directory=/mnt/boot /dev/fd0
                  # umount /mnt

                  I recommend reading the GNU GRUB Manual. The beginning of the manual is at http://www.gnu.org/software/grub/manual/grub/grub.html

                  --
                  Brian Masinick

                  #40180
                  Member
                  olsztyn
                    Helpful
                    Up
                    0
                    ::

                    The Master Boot Record (MBR) is usually installed on the primary device, so if that device is /dev/sda, that’s where you put your primary boot entry. In addition to this you can have boot loader configurations on each distribution partition and if you decide to make a different system control the boot loader, you simply install grub from that distribution.

                    Just to add to this great post: If it not MBR but UEFI system then there should be an UEFI boot partition, where bootloader will reside.

                    I should admit though that I dislike Grub2 way to the utmost. Although flexible, IMHO it is a kludge. As often typical in Linux world obfuscation prevails where simple things should be kept simple. Just look at how many configuration files Grub2 needs. It is a mess…
                    This is one of reasons why Intel’s Clear Linux discarded Grub altogether and uses Syslinux. This way is also what Christophe published in another thread as using Extlinux/syslinux asway to boot. It is much simpler and superior to this obfuscated Grub mess. Unfortunately as it is in Linux world, vast majority has been lead into unnecessary complexity and inefficiency for some personal agendas of making things difficult…

                    Live antiX Boot Options (Previously posted by Xecure):
                    https://antixlinuxfan.miraheze.org/wiki/Table_of_antiX_Boot_Parameters

                    #40181
                    Moderator
                    Brian Masinick
                      Helpful
                      Up
                      0
                      ::

                      There are many different ways to boot a system.

                      The MBR is the old way. You’re right, a specific partition is created for UEFI.

                      There are also many boot loader programs, though GRUB is the usual one.

                      I agree, I was a GRUB Legacy EXPERT.
                      GRUB2? Not nearly as much!

                      Syslinux and other boot manager/loader can be used. Keep in mind that the tools included with the distribution are the only ones that we can properly document, explain and support. You are free to use what you prefer, but it may be difficult to help you with other software.

                      --
                      Brian Masinick

                      #40182
                      Forum Admin
                      anticapitalista
                        Helpful
                        Up
                        0
                        ::

                        antiX uses syslinux for its live system, but grub2 for installation to a device.

                        Philosophers have interpreted the world in many ways; the point is to change it.

                        antiX with runit - leaner and meaner.

                        #40183
                        Moderator
                        Brian Masinick
                          Helpful
                          Up
                          0
                          ::

                          antiX uses syslinux for its live system, but grub2 for installation to a device.

                          Thanks for clarifying how our boot loaders are used anti!

                          Thanks for the fantastic work that you do, and thanks to all contributors in our community!

                          --
                          Brian Masinick

                          #40191
                          Member
                          seaken64
                            Helpful
                            Up
                            0
                            ::

                            I have several computers where I multi-boot. I usually use antiX or MX to control the grub config files. In these cases I install grub to the partition when the distro is not controlling the boot. So, in your case I would have chosen /dev/sda1 as the partition. But in your case you needed to choose /dev/sda because you only have the one OS. I would have /dev/sda2, /dev/sda3, /dev/sda4, etc. for all the distros installed. I would choose /dev/sda ONLY on the distro controlling the boot. On all the others I choose the partition. Then I go into the distro in control of grub and run the update-grub or boot repair. Grub then finds all the other distros and rebuilds the grub menu.

                            Seaken64

                            #40232
                            Member
                            olsztyn
                              Helpful
                              Up
                              0
                              ::

                              antiX uses syslinux for its live system, but grub2 for installation to a device.

                              Thanks. Would this be appropriate for me to mention that antiX Live in addition to installing Grub for antiX installs to hard drive it is using Grub entries for Live itself upon entering ‘Switch to Grub bootloader’, which option is also automatically used for UEFI systems?
                              If ‘Switch to Grub bootloader’ is used then grub.cfg is used instead of syslinux.conf…
                              I am mentioning this as grub.cfg on antiX Live adds some extremely valuable functions such as finding all Grub and Windows bootloaders so antiX can boot any system in existence on hard drive…

                              • This reply was modified 2 years, 8 months ago by olsztyn.

                              Live antiX Boot Options (Previously posted by Xecure):
                              https://antixlinuxfan.miraheze.org/wiki/Table_of_antiX_Boot_Parameters

                            Viewing 13 posts - 1 through 13 (of 13 total)
                            • You must be logged in to reply to this topic.