Windows 10: [guide] Modifying disk UniqueId +BootLoader to point at it

Discus and support [guide] Modifying disk UniqueId +BootLoader to point at it in Windows 10 Backup and Restore to solve the problem; Hello, im now happily re-writing my post since while intending to ask how to do it after breaking my head on it, while writing this thread it forced me... Discussion in 'Windows 10 Backup and Restore' started by clocal, Jan 27, 2021.

  1. clocal Win User

    [guide] Modifying disk UniqueId +BootLoader to point at it


    Hello, im now happily re-writing my post since while intending to ask how to do it after breaking my head on it, while writing this thread it forced me to check all things and it made me realize what and how to do it, so this is now a guide.


    First is the guide how to repair
    Repair BCD If you've accidently changed the Disk's UniqueId and get error 0xc000000e

    [guide] Modifying disk UniqueId +BootLoader to point at it [​IMG]


    create a windows repair disc:
    to do that download the windows media creation tool from here
    https://support.microsoft.com/en-us/...f-40c3b507420d

    and make a bootable usb drive, you could also download the .ISO and later use 'Rufus' application to make a bootable usb.

    Insert a windows repair disc and turn on your machine, load it (you'll see the msg 'press any key to load from...'), select language, click 'Repair windows' -> click 'troubleshoot' and enter the command prompt, there you will use a tool called 'diskpart' to select your disk and then the volume with the BCD info (for me it was the one with 'Info' being set to hidden with the Fat32, I have suspicion it should've been the 'System' as Info column, but retesting it on the same drive did not work so....)
    we will assign a temporary drive letter like 'T' using, and use the 'bcdboot' tool to fix the BCD
    take care to note that your Disk is Gpt (when u do command list disk it will have an asterix '*' near "Gpt" tab.
    if your disk is MBR (old bios) than in the last command instead of typing "/f UEFI" type "/f BIOS"
    alternatively you could use '/f ALL'
    commands

    I'm testing this on a virtual machine but it should not matter at all.
    on my machine there is only 1 disk labeled 'C', in the 'set disk' command you will have to select the correct number if you have more than one disk.

    Code:
    [guide] Modifying disk UniqueId +BootLoader to point at it [​IMG]


    and that's it, windows should boot, on a side note you can go ahead and delete the old boot config so windows will not ask you from where you want to boot windows.
    open 'System configuration' (run -> msconfig)
    go to 'Boot' tab and delete the boot that is NOT the 'Current OS; Default OS'

    [guide] Modifying disk UniqueId +BootLoader to point at it [​IMG]







    HOW TO CHANGE
    bootable Disk's UniqueId and Set the BCD to load from it

    Generate a new UID:
    open powershell.exe as an admin and type
    [guid]::NewGuid().ToString()

    this will print out a newly created uid for you, select and copy it
    for example I got this
    bef16cfc-76a1-440a-9c4b-673d5eb59634

    Now type the command 'diskpart'

    diskpart
    sel disk 0
    UniqueId disk id=bef16cfc-76a1-440a-9c4b-673d5eb59634
    replace the Id with your own UniqueId

    The problem as you know is that changing the UniqueId in diskpart will not notify and update the BCD/bootloader itself of the change thus rebooting the system will result in a 0xc000000e error and renders everything useless as windows would not be able to boot or even enter repair mode (without the repair disc)


    Update BCD

    We are going to correctly identify where your current Windows Boot Manager resides
    for that we will first label all volumes on the disk (this is temporary dont worry)
    in diskpart we will list all the volumes in the current disk
    Diskpart
    list disk
    select disk 0 (or your other disk?)
    list vol

    instead of 'NUMBER' type the number of the volume that does not have a Ltr (letter)
    most likely you will have 2 volumes that do not have letters, give each volume a different unused label lets say T: and W:
    select vol NUMBER
    assign letter=T:
    ^ repeat this for all volumes with no Ltr (change T: to a different letter each time likw W, X, Y...)

    now open CMD with admin privileges (or use powershell, although I've had some issues with that with bcdedit /store...)
    type
    bcdedit /enum /v
    It will show you a list with the first entry being "Windows Boot Manager"
    and the rest will be a few "Windows Boot Loader" entries
    look at the Device and Path of the boot manager, for me it's partition=T:\EFI\Microsoft\Boot\bootmgfw.efi
    so now we know it's in volume
    T:

    now we will edit the "Windows Boot Loader"
    most likely your second entry (the first "windows boot loader")
    is the boot loader that you want to update
    you will see that the "device" and "osdevice" are 'unkown'

    [guide] Modifying disk UniqueId +BootLoader to point at it [​IMG]

    (*edit in this image u dont see my boot manager device letter because I took the screenshot before assigning one, but it was drive letter 'T')
    copy the "Identitfier" guid of the Boot Loader
    we will change the 'device' and 'osdevice' to point to our C partition

    bcdedit /store T:\EFI\Microsoft\Boot\BCD /set {LOADER_IDENTIFIER_WE_COPIED} device partition=C:
    bcdedit /store T:\EFI\Microsoft\Boot\BCD /set {LOADER_IDENTIFIER_WE_COPIED} osdevice partition=C:

    replace T:\EFI\..... with the drive letter that we got from the 'boot manager' earlier
    and that's it, we're good [guide] Modifying disk UniqueId +BootLoader to point at it :)
    you can later delete the previous bootloader using System info (msconfig) I showed how earlier in this tut




    Incase you can't detect the bcd drive letter and it says 'Uknown' on the "Window boot manager" device, it means it did not detect a BCD at all, look up google on how to try to locate your bcd and if it still doesnt find it you'll have to create a fresh new BCD
    reference this microsoft doc page and look for guides on creating new bcd
    https://docs.microsoft.com/en-us/win...d-line-options

    :)
     
    clocal, Jan 27, 2021
    #1
  2. miahallen Win User
    miahallen, Jan 27, 2021
    #2
  3. DJ Hyrax Win User
    Disk offline because it has signature collision with another disk online

    Based on your suggestion such as "You may clean old disk to remove all information from it and reinitialize it. Run diskpart utility and use clean command. Be careful to not clean new disk.

    Change identifier using uniqueid command of diskpart. "

    what will be the next step?
     
    DJ Hyrax, Jan 27, 2021
    #3
  4. [guide] Modifying disk UniqueId +BootLoader to point at it

    How to make Windows 10 bootloader As default bootloader

    If you're using UEFI, you might have to use that to edit.
    Modified from here:
    How to set Windows bootloader as default bootloader?
    To repair your Windows bootloader, if you have a Windows CD

    1. Boot from CD
    2. From title screen, open terminal (the button is usually in bottom left corner)
    3. Execute bootrec /fixmbr

      If this doesn't give desired results, try bootrec /fixboot
     
    Allan Smithee, Jan 27, 2021
    #4
Thema:

[guide] Modifying disk UniqueId +BootLoader to point at it

Loading...
  1. [guide] Modifying disk UniqueId +BootLoader to point at it - Similar Threads - guide Modifying disk

  2. How to increase Disk size in VirtualBox [Guide]

    in Windows 10 News
    How to increase Disk size in VirtualBox [Guide]: [IMG]How often have we encountered a situation where the predefined disk size lacks space to accommodate more data? If you require more space on your virtual machine’s hard disk at a later stage, you will have to expand the virtual hard disk and partition. In this post, we...
  3. bootloader repair

    in Windows 10 Installation and Upgrade
    bootloader repair: i have problem with windows bootloader since i installed it on external linux drive. I want to run the startup repair tool, but I need to sign in to my Microsoft account to proceed. when he enters his password, he tells me that it is incorrect, and it is correct because I can...
  4. Bootloader

    in Windows 10 Support
    Bootloader: Hello I tried to create a USB external SSD portable Ubuntu. I followed the online instructions so as not to affect my bootloader. Guess what, it affected my bootloader . Without doing a clean install is there a way to restore the bootloader which is relatively...
  5. Clover Bootloader

    in Windows 10 Drivers and Hardware
    Clover Bootloader: Hiya, I am going to install clover bootloader whilst clean installing windows 10 for BIOS UEFI (but the BIOS UEFI are 32-Bit). So after I have set up the partitions (shift + F10 before installing windows) from command prompt - please note the automatic set up of partitions...
  6. How to change disk guid

    in Windows 10 Support
    How to change disk guid: I want to change the guid of the disk that is running my windows 10 OS. The reason for this is i want to change the 'machine id' of my system. This unique machine id i think is determined from the guid of the disk. I followed this guide (How to Change the Disk Signature of...
  7. Metro Bootloader

    in Windows 10 Installation and Upgrade
    Metro Bootloader: I just did a dual boot with windows 10 and windows 7 and all I get is the black and white bootloader. Before I partitioned my drive and installed windows 7 I had the Metro bootloader with my windows 10 and Macrium Reflect but after installing windows 7 on the new partition...
  8. how modify Kyhi's PE disk

    in Windows 10 Support
    how modify Kyhi's PE disk: @Kyhi Thank you for the Emergency DVD. I'd like to add a few tools to my version. Can you please explain how to do this? Also, I'd like to place an icon for every tool on the desktop. How do I do that? I would think that I would have to use the ISO to write on a...
  9. Windows 10 Pro Bootloader and Bootmanager on different Disks

    in Windows 10 Support
    Windows 10 Pro Bootloader and Bootmanager on different Disks: I have problem with booting my computer a lot of time and I see true EasyBCD that my bootloader and bootmanager was on 2 different drives. So all the files in Windows 10 is on the C: drive but the boot files are on a N: drive. Is it something I can do about that. I have...
  10. fat32 efi partition on OS disk and bootloader showing in bios

    in Windows 10 Performance & Maintenance
    fat32 efi partition on OS disk and bootloader showing in bios: after i put a friends laptop hd in my computer and fixed his. i have a strange little 99MB fat32 efi volume\partition on the OS disk. and i never saw it before. and i have 2 boot loaders in bios. wont boot without one of them being selected. is it supposed to be there? can...