14.04 Upgrade triggers grub-pc failure











up vote
3
down vote

favorite
1












My problem begins with an upgrade from Ubuntu 12.04 LTS to 14.02 LTS. As part of this I received several error messages about not being able to remove old kernels.



When first booting into 14.02, I checked everything was ok by running sudo apt-get autoremove, the same errors appeared.



Following a guide online, I ran the following:



sudo apt-get purge grub-common
sudo apt-get install grub-pc


The first operation succeeded, removing grub from my pc. The second operation failed with the following:



Creating config file /etc/default/grub with new version
Installing for i386-pc platform.
Installation finished. No error reported.
Generating grub configuration file ...
Warning: Setting GRUB_TIMEOUT to a non-zero value when GRUB_HIDDEN_TIMEOUT is set is no longer supported.
Found linux image: /boot/vmlinuz-3.13.0-54-generic
Found initrd image: /boot/initrd.img-3.13.0-54-generic
Found linux image: /boot/vmlinuz-3.13.0-44-generic
Found initrd image: /boot/initrd.img-3.13.0-44-generic
Found linux image: /boot/vmlinuz-3.13.0-40-generic
Found initrd image: /boot/initrd.img-3.13.0-40-generic
Adding boot menu entry for EFI firmware configuration
cat: /video.lst: No such file or directory
/usr/sbin/grub-probe: error: failed to get canonical path of `'.
No path or device is specified.
Usage: grub-probe [OPTION...] [OPTION]... [PATH|DEVICE]
Try 'grub-probe --help' or 'grub-probe --usage' for more information.
dpkg: error processing package grub-pc (--configure):
subprocess installed post-installation script returned error exit status 64
Errors were encountered while processing:
grub-pc
E: Sub-process /usr/bin/dpkg returned an error code (1)


I have tried numerous fixes for this, most of which are documented here. I created a LiveCD before removing grub-common, so I have access to my old partition and can mount and chroot into it.



But when running update-grub the same error appears, I also cannot run dpkg --configure -a without this occurring.



I used boot-repair to get a boot summary for my machine, which is a 2 HDD rig with dual boot on the first drive (/dev/sda). With Windows on /dev/sda1 and my Ubuntu partition (also boot) on /dev/sda2.



Please help me fix this and I promise I won't touch my Ubuntu install ever again. :-)










share|improve this question




























    up vote
    3
    down vote

    favorite
    1












    My problem begins with an upgrade from Ubuntu 12.04 LTS to 14.02 LTS. As part of this I received several error messages about not being able to remove old kernels.



    When first booting into 14.02, I checked everything was ok by running sudo apt-get autoremove, the same errors appeared.



    Following a guide online, I ran the following:



    sudo apt-get purge grub-common
    sudo apt-get install grub-pc


    The first operation succeeded, removing grub from my pc. The second operation failed with the following:



    Creating config file /etc/default/grub with new version
    Installing for i386-pc platform.
    Installation finished. No error reported.
    Generating grub configuration file ...
    Warning: Setting GRUB_TIMEOUT to a non-zero value when GRUB_HIDDEN_TIMEOUT is set is no longer supported.
    Found linux image: /boot/vmlinuz-3.13.0-54-generic
    Found initrd image: /boot/initrd.img-3.13.0-54-generic
    Found linux image: /boot/vmlinuz-3.13.0-44-generic
    Found initrd image: /boot/initrd.img-3.13.0-44-generic
    Found linux image: /boot/vmlinuz-3.13.0-40-generic
    Found initrd image: /boot/initrd.img-3.13.0-40-generic
    Adding boot menu entry for EFI firmware configuration
    cat: /video.lst: No such file or directory
    /usr/sbin/grub-probe: error: failed to get canonical path of `'.
    No path or device is specified.
    Usage: grub-probe [OPTION...] [OPTION]... [PATH|DEVICE]
    Try 'grub-probe --help' or 'grub-probe --usage' for more information.
    dpkg: error processing package grub-pc (--configure):
    subprocess installed post-installation script returned error exit status 64
    Errors were encountered while processing:
    grub-pc
    E: Sub-process /usr/bin/dpkg returned an error code (1)


    I have tried numerous fixes for this, most of which are documented here. I created a LiveCD before removing grub-common, so I have access to my old partition and can mount and chroot into it.



    But when running update-grub the same error appears, I also cannot run dpkg --configure -a without this occurring.



    I used boot-repair to get a boot summary for my machine, which is a 2 HDD rig with dual boot on the first drive (/dev/sda). With Windows on /dev/sda1 and my Ubuntu partition (also boot) on /dev/sda2.



    Please help me fix this and I promise I won't touch my Ubuntu install ever again. :-)










    share|improve this question


























      up vote
      3
      down vote

      favorite
      1









      up vote
      3
      down vote

      favorite
      1






      1





      My problem begins with an upgrade from Ubuntu 12.04 LTS to 14.02 LTS. As part of this I received several error messages about not being able to remove old kernels.



      When first booting into 14.02, I checked everything was ok by running sudo apt-get autoremove, the same errors appeared.



      Following a guide online, I ran the following:



      sudo apt-get purge grub-common
      sudo apt-get install grub-pc


      The first operation succeeded, removing grub from my pc. The second operation failed with the following:



      Creating config file /etc/default/grub with new version
      Installing for i386-pc platform.
      Installation finished. No error reported.
      Generating grub configuration file ...
      Warning: Setting GRUB_TIMEOUT to a non-zero value when GRUB_HIDDEN_TIMEOUT is set is no longer supported.
      Found linux image: /boot/vmlinuz-3.13.0-54-generic
      Found initrd image: /boot/initrd.img-3.13.0-54-generic
      Found linux image: /boot/vmlinuz-3.13.0-44-generic
      Found initrd image: /boot/initrd.img-3.13.0-44-generic
      Found linux image: /boot/vmlinuz-3.13.0-40-generic
      Found initrd image: /boot/initrd.img-3.13.0-40-generic
      Adding boot menu entry for EFI firmware configuration
      cat: /video.lst: No such file or directory
      /usr/sbin/grub-probe: error: failed to get canonical path of `'.
      No path or device is specified.
      Usage: grub-probe [OPTION...] [OPTION]... [PATH|DEVICE]
      Try 'grub-probe --help' or 'grub-probe --usage' for more information.
      dpkg: error processing package grub-pc (--configure):
      subprocess installed post-installation script returned error exit status 64
      Errors were encountered while processing:
      grub-pc
      E: Sub-process /usr/bin/dpkg returned an error code (1)


      I have tried numerous fixes for this, most of which are documented here. I created a LiveCD before removing grub-common, so I have access to my old partition and can mount and chroot into it.



      But when running update-grub the same error appears, I also cannot run dpkg --configure -a without this occurring.



      I used boot-repair to get a boot summary for my machine, which is a 2 HDD rig with dual boot on the first drive (/dev/sda). With Windows on /dev/sda1 and my Ubuntu partition (also boot) on /dev/sda2.



      Please help me fix this and I promise I won't touch my Ubuntu install ever again. :-)










      share|improve this question















      My problem begins with an upgrade from Ubuntu 12.04 LTS to 14.02 LTS. As part of this I received several error messages about not being able to remove old kernels.



      When first booting into 14.02, I checked everything was ok by running sudo apt-get autoremove, the same errors appeared.



      Following a guide online, I ran the following:



      sudo apt-get purge grub-common
      sudo apt-get install grub-pc


      The first operation succeeded, removing grub from my pc. The second operation failed with the following:



      Creating config file /etc/default/grub with new version
      Installing for i386-pc platform.
      Installation finished. No error reported.
      Generating grub configuration file ...
      Warning: Setting GRUB_TIMEOUT to a non-zero value when GRUB_HIDDEN_TIMEOUT is set is no longer supported.
      Found linux image: /boot/vmlinuz-3.13.0-54-generic
      Found initrd image: /boot/initrd.img-3.13.0-54-generic
      Found linux image: /boot/vmlinuz-3.13.0-44-generic
      Found initrd image: /boot/initrd.img-3.13.0-44-generic
      Found linux image: /boot/vmlinuz-3.13.0-40-generic
      Found initrd image: /boot/initrd.img-3.13.0-40-generic
      Adding boot menu entry for EFI firmware configuration
      cat: /video.lst: No such file or directory
      /usr/sbin/grub-probe: error: failed to get canonical path of `'.
      No path or device is specified.
      Usage: grub-probe [OPTION...] [OPTION]... [PATH|DEVICE]
      Try 'grub-probe --help' or 'grub-probe --usage' for more information.
      dpkg: error processing package grub-pc (--configure):
      subprocess installed post-installation script returned error exit status 64
      Errors were encountered while processing:
      grub-pc
      E: Sub-process /usr/bin/dpkg returned an error code (1)


      I have tried numerous fixes for this, most of which are documented here. I created a LiveCD before removing grub-common, so I have access to my old partition and can mount and chroot into it.



      But when running update-grub the same error appears, I also cannot run dpkg --configure -a without this occurring.



      I used boot-repair to get a boot summary for my machine, which is a 2 HDD rig with dual boot on the first drive (/dev/sda). With Windows on /dev/sda1 and my Ubuntu partition (also boot) on /dev/sda2.



      Please help me fix this and I promise I won't touch my Ubuntu install ever again. :-)







      boot dual-boot grub2 upgrade






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Nov 21 at 22:08









      Jackspace

      94




      94










      asked Jun 14 '15 at 19:07









      Rossiar

      17418




      17418






















          2 Answers
          2






          active

          oldest

          votes

















          up vote
          5
          down vote



          accepted










          I "elegantly solved" my problem by using the following:



          sudo apt-get purge grub-pc grub-common
          sudo rm -r /etc/grub.d/
          sudo apt-get install grub-pc grub-common
          sudo grub-install /dev/sda
          sudo update-grub


          Deleting the /etc/grub.d/ directory seemed to have gotten rid of whatever 12.04 files I had lurking, allowing 14.04 to get on with installing grub!



          Although I would of course recommend making a backup of anything that you are about to delete.






          share|improve this answer

















          • 1




            This does solve the problem, thank you very much!
            – Tsung-Ting Kuo
            Jun 7 '16 at 17:38










          • DANGER you might not want to run such rm -r commands ... at the very least, back up what you remove. And also this solution is missing update-initramfs -u which is often important for fixng boot issues.
            – Peter
            Apr 4 at 11:16


















          up vote
          0
          down vote













          The easiest way to use Boot-Repair is to create a disk containing the tool (eg Boot-Repair-Disk, a disk starting Boot-Repair automatically), and boot on it.



          I personally prefer using the Boot-Repair disk ISO






          share|improve this answer








          New contributor




          Jackspace is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
          Check out our Code of Conduct.


















            Your Answer








            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "89"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














             

            draft saved


            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f636456%2f14-04-upgrade-triggers-grub-pc-failure%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            5
            down vote



            accepted










            I "elegantly solved" my problem by using the following:



            sudo apt-get purge grub-pc grub-common
            sudo rm -r /etc/grub.d/
            sudo apt-get install grub-pc grub-common
            sudo grub-install /dev/sda
            sudo update-grub


            Deleting the /etc/grub.d/ directory seemed to have gotten rid of whatever 12.04 files I had lurking, allowing 14.04 to get on with installing grub!



            Although I would of course recommend making a backup of anything that you are about to delete.






            share|improve this answer

















            • 1




              This does solve the problem, thank you very much!
              – Tsung-Ting Kuo
              Jun 7 '16 at 17:38










            • DANGER you might not want to run such rm -r commands ... at the very least, back up what you remove. And also this solution is missing update-initramfs -u which is often important for fixng boot issues.
              – Peter
              Apr 4 at 11:16















            up vote
            5
            down vote



            accepted










            I "elegantly solved" my problem by using the following:



            sudo apt-get purge grub-pc grub-common
            sudo rm -r /etc/grub.d/
            sudo apt-get install grub-pc grub-common
            sudo grub-install /dev/sda
            sudo update-grub


            Deleting the /etc/grub.d/ directory seemed to have gotten rid of whatever 12.04 files I had lurking, allowing 14.04 to get on with installing grub!



            Although I would of course recommend making a backup of anything that you are about to delete.






            share|improve this answer

















            • 1




              This does solve the problem, thank you very much!
              – Tsung-Ting Kuo
              Jun 7 '16 at 17:38










            • DANGER you might not want to run such rm -r commands ... at the very least, back up what you remove. And also this solution is missing update-initramfs -u which is often important for fixng boot issues.
              – Peter
              Apr 4 at 11:16













            up vote
            5
            down vote



            accepted







            up vote
            5
            down vote



            accepted






            I "elegantly solved" my problem by using the following:



            sudo apt-get purge grub-pc grub-common
            sudo rm -r /etc/grub.d/
            sudo apt-get install grub-pc grub-common
            sudo grub-install /dev/sda
            sudo update-grub


            Deleting the /etc/grub.d/ directory seemed to have gotten rid of whatever 12.04 files I had lurking, allowing 14.04 to get on with installing grub!



            Although I would of course recommend making a backup of anything that you are about to delete.






            share|improve this answer












            I "elegantly solved" my problem by using the following:



            sudo apt-get purge grub-pc grub-common
            sudo rm -r /etc/grub.d/
            sudo apt-get install grub-pc grub-common
            sudo grub-install /dev/sda
            sudo update-grub


            Deleting the /etc/grub.d/ directory seemed to have gotten rid of whatever 12.04 files I had lurking, allowing 14.04 to get on with installing grub!



            Although I would of course recommend making a backup of anything that you are about to delete.







            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered Jun 14 '15 at 23:02









            Rossiar

            17418




            17418








            • 1




              This does solve the problem, thank you very much!
              – Tsung-Ting Kuo
              Jun 7 '16 at 17:38










            • DANGER you might not want to run such rm -r commands ... at the very least, back up what you remove. And also this solution is missing update-initramfs -u which is often important for fixng boot issues.
              – Peter
              Apr 4 at 11:16














            • 1




              This does solve the problem, thank you very much!
              – Tsung-Ting Kuo
              Jun 7 '16 at 17:38










            • DANGER you might not want to run such rm -r commands ... at the very least, back up what you remove. And also this solution is missing update-initramfs -u which is often important for fixng boot issues.
              – Peter
              Apr 4 at 11:16








            1




            1




            This does solve the problem, thank you very much!
            – Tsung-Ting Kuo
            Jun 7 '16 at 17:38




            This does solve the problem, thank you very much!
            – Tsung-Ting Kuo
            Jun 7 '16 at 17:38












            DANGER you might not want to run such rm -r commands ... at the very least, back up what you remove. And also this solution is missing update-initramfs -u which is often important for fixng boot issues.
            – Peter
            Apr 4 at 11:16




            DANGER you might not want to run such rm -r commands ... at the very least, back up what you remove. And also this solution is missing update-initramfs -u which is often important for fixng boot issues.
            – Peter
            Apr 4 at 11:16












            up vote
            0
            down vote













            The easiest way to use Boot-Repair is to create a disk containing the tool (eg Boot-Repair-Disk, a disk starting Boot-Repair automatically), and boot on it.



            I personally prefer using the Boot-Repair disk ISO






            share|improve this answer








            New contributor




            Jackspace is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
            Check out our Code of Conduct.






















              up vote
              0
              down vote













              The easiest way to use Boot-Repair is to create a disk containing the tool (eg Boot-Repair-Disk, a disk starting Boot-Repair automatically), and boot on it.



              I personally prefer using the Boot-Repair disk ISO






              share|improve this answer








              New contributor




              Jackspace is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
              Check out our Code of Conduct.




















                up vote
                0
                down vote










                up vote
                0
                down vote









                The easiest way to use Boot-Repair is to create a disk containing the tool (eg Boot-Repair-Disk, a disk starting Boot-Repair automatically), and boot on it.



                I personally prefer using the Boot-Repair disk ISO






                share|improve this answer








                New contributor




                Jackspace is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.









                The easiest way to use Boot-Repair is to create a disk containing the tool (eg Boot-Repair-Disk, a disk starting Boot-Repair automatically), and boot on it.



                I personally prefer using the Boot-Repair disk ISO







                share|improve this answer








                New contributor




                Jackspace is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.









                share|improve this answer



                share|improve this answer






                New contributor




                Jackspace is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.









                answered Nov 21 at 20:55









                Jackspace

                94




                94




                New contributor




                Jackspace is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.





                New contributor





                Jackspace is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.






                Jackspace is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                Check out our Code of Conduct.






























                     

                    draft saved


                    draft discarded



















































                     


                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f636456%2f14-04-upgrade-triggers-grub-pc-failure%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Mouse cursor on multiple screens with different PPI

                    Agildo Ribeiro

                    Sometime when accessing a menu: “Ubuntu 16.04 has experienced an internal error”