Booting linux from cloned drive switches to original drive instead












0















I have a multiboot linux system and am trying to clone my existing linux partition to an unused partition on a separate drive and have both available to boot from the Grub menu.



It appears to work, showing the original drive as the default first option and the clone lower down in the list. The problem is that selecting the clone from the menu ends up booting from the original partition instead, every time. I can tell the difference by looking at fstab and drive sizes. And yes I've changed the clone's UUID (see below).



It appears that grub starts booting from the clone (the startup screen is graphical when booting from the original, text when booting from the clone, though no idea why it would differ), but by the time I get to the login screen, the original drive is the one mounted.



Here's what I've done:




  • Cloned partition using CloneZilla

  • Changed UUID of clone w/ tune2fs and edited UUID in its etc/fstab

  • Booted to original drive

  • Ran update-grub

  • Chrooted to clone and ran update-initramfs


What am I forgetting? I've done this in the past and got it work! However, in the past I didn't start with CloneZilla, I may have used dd but can't be sure.



I'm running Linux Mint 18, kernel 4.4.0-141-generic.



Here's blkid (edited and commented):



/dev/sda1: UUID="4e9c..." TYPE="ext4" (original) 
/dev/sda5: UUID="bb86..." TYPE="swap"
/dev/sdb1: UUID="69cc..." TYPE="ext4" (/home)
/dev/sdc1: UUID="3CF6..." TYPE="ntfs" (windows)
/dev/sdc5: UUID="d8e2..." TYPE="ext4" (clone)
/dev/sdc6: UUID="fc7d..." TYPE="swap"


Here's fstab on clone (edited):



# <file system> <mount point>   <type>  <options>       <dump>  <pass>
UUID=d8e2.... / ext4 errors=remount-ro 0 1
UUID=fc7d.... none swap sw 0 0


Grub menu looks something like this (from memory):



Linux Mint 18 Sarah
something about custom options
Memtest
Windows 7
Linux Mint 18 Sarah (on /dev/sdc5)
again w/ custom options









share|improve this question


















  • 1





    When in Grub, see Linux entries (pretend you want to edit them) and confirm they use different root=UUID= values. Do they?

    – Kamil Maciorowski
    Jan 6 at 2:19











  • You're onto something - the clone config has the original UUID in the "linux ... root=UUID=" line, though other places in the config (search commands) have the clone UUID. Any idea why that would happen?

    – Kruthers
    Jan 6 at 3:12











  • @Kamil - That clue helped me figure it out, thanks. Will post the solution.

    – Kruthers
    Jan 6 at 3:39
















0















I have a multiboot linux system and am trying to clone my existing linux partition to an unused partition on a separate drive and have both available to boot from the Grub menu.



It appears to work, showing the original drive as the default first option and the clone lower down in the list. The problem is that selecting the clone from the menu ends up booting from the original partition instead, every time. I can tell the difference by looking at fstab and drive sizes. And yes I've changed the clone's UUID (see below).



It appears that grub starts booting from the clone (the startup screen is graphical when booting from the original, text when booting from the clone, though no idea why it would differ), but by the time I get to the login screen, the original drive is the one mounted.



Here's what I've done:




  • Cloned partition using CloneZilla

  • Changed UUID of clone w/ tune2fs and edited UUID in its etc/fstab

  • Booted to original drive

  • Ran update-grub

  • Chrooted to clone and ran update-initramfs


What am I forgetting? I've done this in the past and got it work! However, in the past I didn't start with CloneZilla, I may have used dd but can't be sure.



I'm running Linux Mint 18, kernel 4.4.0-141-generic.



Here's blkid (edited and commented):



/dev/sda1: UUID="4e9c..." TYPE="ext4" (original) 
/dev/sda5: UUID="bb86..." TYPE="swap"
/dev/sdb1: UUID="69cc..." TYPE="ext4" (/home)
/dev/sdc1: UUID="3CF6..." TYPE="ntfs" (windows)
/dev/sdc5: UUID="d8e2..." TYPE="ext4" (clone)
/dev/sdc6: UUID="fc7d..." TYPE="swap"


Here's fstab on clone (edited):



# <file system> <mount point>   <type>  <options>       <dump>  <pass>
UUID=d8e2.... / ext4 errors=remount-ro 0 1
UUID=fc7d.... none swap sw 0 0


Grub menu looks something like this (from memory):



Linux Mint 18 Sarah
something about custom options
Memtest
Windows 7
Linux Mint 18 Sarah (on /dev/sdc5)
again w/ custom options









share|improve this question


















  • 1





    When in Grub, see Linux entries (pretend you want to edit them) and confirm they use different root=UUID= values. Do they?

    – Kamil Maciorowski
    Jan 6 at 2:19











  • You're onto something - the clone config has the original UUID in the "linux ... root=UUID=" line, though other places in the config (search commands) have the clone UUID. Any idea why that would happen?

    – Kruthers
    Jan 6 at 3:12











  • @Kamil - That clue helped me figure it out, thanks. Will post the solution.

    – Kruthers
    Jan 6 at 3:39














0












0








0








I have a multiboot linux system and am trying to clone my existing linux partition to an unused partition on a separate drive and have both available to boot from the Grub menu.



It appears to work, showing the original drive as the default first option and the clone lower down in the list. The problem is that selecting the clone from the menu ends up booting from the original partition instead, every time. I can tell the difference by looking at fstab and drive sizes. And yes I've changed the clone's UUID (see below).



It appears that grub starts booting from the clone (the startup screen is graphical when booting from the original, text when booting from the clone, though no idea why it would differ), but by the time I get to the login screen, the original drive is the one mounted.



Here's what I've done:




  • Cloned partition using CloneZilla

  • Changed UUID of clone w/ tune2fs and edited UUID in its etc/fstab

  • Booted to original drive

  • Ran update-grub

  • Chrooted to clone and ran update-initramfs


What am I forgetting? I've done this in the past and got it work! However, in the past I didn't start with CloneZilla, I may have used dd but can't be sure.



I'm running Linux Mint 18, kernel 4.4.0-141-generic.



Here's blkid (edited and commented):



/dev/sda1: UUID="4e9c..." TYPE="ext4" (original) 
/dev/sda5: UUID="bb86..." TYPE="swap"
/dev/sdb1: UUID="69cc..." TYPE="ext4" (/home)
/dev/sdc1: UUID="3CF6..." TYPE="ntfs" (windows)
/dev/sdc5: UUID="d8e2..." TYPE="ext4" (clone)
/dev/sdc6: UUID="fc7d..." TYPE="swap"


Here's fstab on clone (edited):



# <file system> <mount point>   <type>  <options>       <dump>  <pass>
UUID=d8e2.... / ext4 errors=remount-ro 0 1
UUID=fc7d.... none swap sw 0 0


Grub menu looks something like this (from memory):



Linux Mint 18 Sarah
something about custom options
Memtest
Windows 7
Linux Mint 18 Sarah (on /dev/sdc5)
again w/ custom options









share|improve this question














I have a multiboot linux system and am trying to clone my existing linux partition to an unused partition on a separate drive and have both available to boot from the Grub menu.



It appears to work, showing the original drive as the default first option and the clone lower down in the list. The problem is that selecting the clone from the menu ends up booting from the original partition instead, every time. I can tell the difference by looking at fstab and drive sizes. And yes I've changed the clone's UUID (see below).



It appears that grub starts booting from the clone (the startup screen is graphical when booting from the original, text when booting from the clone, though no idea why it would differ), but by the time I get to the login screen, the original drive is the one mounted.



Here's what I've done:




  • Cloned partition using CloneZilla

  • Changed UUID of clone w/ tune2fs and edited UUID in its etc/fstab

  • Booted to original drive

  • Ran update-grub

  • Chrooted to clone and ran update-initramfs


What am I forgetting? I've done this in the past and got it work! However, in the past I didn't start with CloneZilla, I may have used dd but can't be sure.



I'm running Linux Mint 18, kernel 4.4.0-141-generic.



Here's blkid (edited and commented):



/dev/sda1: UUID="4e9c..." TYPE="ext4" (original) 
/dev/sda5: UUID="bb86..." TYPE="swap"
/dev/sdb1: UUID="69cc..." TYPE="ext4" (/home)
/dev/sdc1: UUID="3CF6..." TYPE="ntfs" (windows)
/dev/sdc5: UUID="d8e2..." TYPE="ext4" (clone)
/dev/sdc6: UUID="fc7d..." TYPE="swap"


Here's fstab on clone (edited):



# <file system> <mount point>   <type>  <options>       <dump>  <pass>
UUID=d8e2.... / ext4 errors=remount-ro 0 1
UUID=fc7d.... none swap sw 0 0


Grub menu looks something like this (from memory):



Linux Mint 18 Sarah
something about custom options
Memtest
Windows 7
Linux Mint 18 Sarah (on /dev/sdc5)
again w/ custom options






linux boot grub






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Jan 6 at 2:07









KruthersKruthers

1




1








  • 1





    When in Grub, see Linux entries (pretend you want to edit them) and confirm they use different root=UUID= values. Do they?

    – Kamil Maciorowski
    Jan 6 at 2:19











  • You're onto something - the clone config has the original UUID in the "linux ... root=UUID=" line, though other places in the config (search commands) have the clone UUID. Any idea why that would happen?

    – Kruthers
    Jan 6 at 3:12











  • @Kamil - That clue helped me figure it out, thanks. Will post the solution.

    – Kruthers
    Jan 6 at 3:39














  • 1





    When in Grub, see Linux entries (pretend you want to edit them) and confirm they use different root=UUID= values. Do they?

    – Kamil Maciorowski
    Jan 6 at 2:19











  • You're onto something - the clone config has the original UUID in the "linux ... root=UUID=" line, though other places in the config (search commands) have the clone UUID. Any idea why that would happen?

    – Kruthers
    Jan 6 at 3:12











  • @Kamil - That clue helped me figure it out, thanks. Will post the solution.

    – Kruthers
    Jan 6 at 3:39








1




1





When in Grub, see Linux entries (pretend you want to edit them) and confirm they use different root=UUID= values. Do they?

– Kamil Maciorowski
Jan 6 at 2:19





When in Grub, see Linux entries (pretend you want to edit them) and confirm they use different root=UUID= values. Do they?

– Kamil Maciorowski
Jan 6 at 2:19













You're onto something - the clone config has the original UUID in the "linux ... root=UUID=" line, though other places in the config (search commands) have the clone UUID. Any idea why that would happen?

– Kruthers
Jan 6 at 3:12





You're onto something - the clone config has the original UUID in the "linux ... root=UUID=" line, though other places in the config (search commands) have the clone UUID. Any idea why that would happen?

– Kruthers
Jan 6 at 3:12













@Kamil - That clue helped me figure it out, thanks. Will post the solution.

– Kruthers
Jan 6 at 3:39





@Kamil - That clue helped me figure it out, thanks. Will post the solution.

– Kruthers
Jan 6 at 3:39










1 Answer
1






active

oldest

votes


















0














It turns out I needed to run update-initramfs on the original partion before running update-grub.



It's possible that update-initramfs was completely unnecessary on the clone partition, or that it needed to be run on both, I'm not sure. But in any case everything is working now.






share|improve this answer























    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "3"
    };
    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',
    autoActivateHeartbeat: false,
    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%2fsuperuser.com%2fquestions%2f1391050%2fbooting-linux-from-cloned-drive-switches-to-original-drive-instead%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    It turns out I needed to run update-initramfs on the original partion before running update-grub.



    It's possible that update-initramfs was completely unnecessary on the clone partition, or that it needed to be run on both, I'm not sure. But in any case everything is working now.






    share|improve this answer




























      0














      It turns out I needed to run update-initramfs on the original partion before running update-grub.



      It's possible that update-initramfs was completely unnecessary on the clone partition, or that it needed to be run on both, I'm not sure. But in any case everything is working now.






      share|improve this answer


























        0












        0








        0







        It turns out I needed to run update-initramfs on the original partion before running update-grub.



        It's possible that update-initramfs was completely unnecessary on the clone partition, or that it needed to be run on both, I'm not sure. But in any case everything is working now.






        share|improve this answer













        It turns out I needed to run update-initramfs on the original partion before running update-grub.



        It's possible that update-initramfs was completely unnecessary on the clone partition, or that it needed to be run on both, I'm not sure. But in any case everything is working now.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Jan 6 at 3:39









        KruthersKruthers

        1




        1






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to Super User!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1391050%2fbooting-linux-from-cloned-drive-switches-to-original-drive-instead%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

            flock() on closed filehandle LOCK_FILE at /usr/bin/apt-mirror

            Mangá

             ⁒  ․,‪⁊‑⁙ ⁖, ⁇‒※‌, †,⁖‗‌⁝    ‾‸⁘,‖⁔⁣,⁂‾
”‑,‥–,‬ ,⁀‹⁋‴⁑ ‒ ,‴⁋”‼ ⁨,‷⁔„ ‰′,‐‚ ‥‡‎“‷⁃⁨⁅⁣,⁔
⁇‘⁔⁡⁏⁌⁡‿‶‏⁨ ⁣⁕⁖⁨⁩⁥‽⁀  ‴‬⁜‟ ⁃‣‧⁕‮ …‍⁨‴ ⁩,⁚⁖‫ ,‵ ⁀,‮⁝‣‣ ⁑  ⁂– ․, ‾‽ ‏⁁“⁗‸ ‾… ‹‡⁌⁎‸‘ ‡⁏⁌‪ ‵⁛ ‎⁨ ―⁦⁤⁄⁕