Menu

Cannot boot Windows

serge bee
2021-03-14
2021-03-16
  • serge bee

    serge bee - 2021-03-14

    I recently installed ubuntu on my macbook with Win10 and iOS. After that I could still boot iOS and ubuntu, but Windows brought an error. I can still access the files of Windows, but can no longer boot the system. There seems a screen with a short message, but I cannot read it as it immediately disappears.

    Now I wanted to reinstall Windows 10, so I created an installation media. This also loads correctly on my second Acer notebook. On my macbook, reFind also recognizes that a Win10 installation media is plugged in, but nothing happens when I enter-click on the icon. The installer simply does not start. What can I do?

     
  • Roderick W. Smith

    Before doing anything else, it's imperative that you identify the Windows boot mode (EFI or BIOS/CSM/legacy). The rEFInd documentation has a page on this topic:

    https://www.rodsbooks.com/refind/bootmode.html

    Unfortunately, if Windows is not booting right now, you won't be able to identify the boot mode of the Windows installation using the techniques on that page; however, the rEFInd entry for Windows may provide a clue. An EFI-mode boot loader will probably appear with a description of "Boot Microsoft EFI boot from..." and the ESP's name or description. I don't have a BIOS-mode Windows installation to check, but based on the rEFInd source code, I believe its description should include the string "Windows (Legacy)."

    You should also make an effort to read the message that disappears too quickly to read. Try recording a video with a camera or cell phone. Played back frame-by-frame, you may be able to read the message, which may provide important clues about what's wrong.

    If Windows was installed in BIOS/CSM/legacy mode, that could at least partially explain the problem. To boot in BIOS mode, Macs require that at least one disk be an MBR disk or to be a GPT disk with a hybrid MBR. Hybrid MBRs are ugly and dangerous hacks, and they can easily become corrupted. If the disk was re-partitioned, the Windows partition might easily have shifted out of hybridized status, which would lead to a boot failure. Many other things could have gone wrong, too. You can check a disk's status (true GPT, MBR, or hybrid MBR) by running gdisk on it and examining the initial partition table scan:

    Partition table scan:
      MBR: protective
      BSD: not present
      APM: not present
      GPT: present
    

    This example shows a conventional GPT disk, as identified by the GPT: present and MBR: protective lines. A hybrid MBR will also have GPT: present, but the MBR line will read MBR: hybrid. If you believe Windows was installed in BIOS mode to a GPT disk with a hybrid MBR, and if you think a change to the hybrid MBR is to blame for the problem, then repairing that issue may resolve the problem. Doing so can be tricky, though; you really need to know what you're doing. If you don't, you can create even bigger problems. The page on hybrid MBRs referenced earlier provides some information on this topic.

    Note that gdisk is a standard part of most Linux distributions, but if you want to run it from macOS, you'll need to download and install it; see the project's dowloads page for details. SIP must also be disabled, at least temporarily, in order to run it on an internal disk.

    If you need to re-install Windows 10, I recommend doing so in EFI mode, not in BIOS mode. It's just much cleaner and more flexible that way. (That said, there are reasons to do a BIOS-mode install in some circumstances, such as if that way is known to work better with your specific Mac model or third-party hardware, such as plug-in video cards. I don't know specific models for which this might be the case. A Mac forum is probably a better place to ask about that.) Before re-installing in this way, be sure you do not have a hybrid MBR, at least not on the disk to which you'll be installing Windows.

    Controlling how an OS installer boots can be tricky. If you boot the installer through rEFInd, you may see two options to boot the installation medium, one of which is described as an EFI fallback loader and the other of which is described as a legacy-mode loader. Pick the one for the mode in which you want to install. Note that the Windows installer will complain if it doesn't like the partition table for its boot mode -- that is, if it sees a GPT for a BIOS-mode boot or an MBR (including a GPT with a hybrid MBR) for an EFI-mode boot. This is why you must replace a hybrid MBR with a standard GPT protective MBR if you intend to install in EFI mode.

     
  • serge bee

    serge bee - 2021-03-15

    I have to make a small correction to my post. When I try to start the partition with Windows, I get the following error:
    "Failed to set moklist: Invalid parameters." => and a lot more messages which I also tried to find answers to on the web, but did not find any solution.
    https://ibb.co/0qXXmKR

    simon-MacBookPro:~$ df /boot/efi
    Filesystem     1K-blocks   Used Available Use% Mounted on
    /dev/nvme0n1p1    201633 196963      4670  98% /boot/efi
    

    When I try to start the USB with the Windows Installer, I can choose between 3 different modes:
    1. Boot fallback bootloader from UEFI_NTFS
    2. Boot EFI/Rufus/exfat from UEFI_NTFS
    3. Boot EFI/Rufus/ntfs from UEFI_NTFS
    With all, a short error message appears, but so short I cannot read it. I try to read it with the explained method though, need some time for this. Isn't it possible to activate logs on this? I have not found a way to do this, though I found something in the docs.

    When running fdisk, I get:

    @simon-MacBookPro:~$ sudo fdisk -l
    Disk /dev/loop0: 99,21 MiB, 104026112 bytes, 203176 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/loop1: 55,48 MiB, 58159104 bytes, 113592 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/loop2: 162,89 MiB, 170778624 bytes, 333552 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/loop3: 164,65 MiB, 172634112 bytes, 337176 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/loop4: 152,98 MiB, 160391168 bytes, 313264 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/loop5: 218,102 MiB, 229629952 bytes, 448496 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/loop6: 51,4 MiB, 53522432 bytes, 104536 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/loop7: 64,79 MiB, 67915776 bytes, 132648 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/nvme0n1: 953,89 GiB, 1024209543168 bytes, 2000409264 sectors
    Disk model: INTEL SSDPEKNW010T8                     
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disklabel type: gpt
    Disk identifier: 3504EFAD-833C-4B5F-8767-75700C37D407
    
    Device              Start        End    Sectors   Size Type
    /dev/nvme0n1p1         40     409639     409600   200M EFI System
    /dev/nvme0n1p2     411648 1689866239 1689454592 805,6G Microsoft basic data
    /dev/nvme0n1p3 1822656512 2000408575  177752064  84,8G Linux filesystem
    
    
    Disk /dev/loop8: 32,28 MiB, 33845248 bytes, 66104 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/loop9: 31,9 MiB, 32595968 bytes, 63664 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    
    
    Disk /dev/sda: 14,93 GiB, 16008609792 bytes, 31266816 sectors
    Disk model: Cruzer Blade    
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disklabel type: gpt
    Disk identifier: 345BB29D-C99D-4A25-BD3C-B5A5202A3700
    
    Device        Start      End  Sectors  Size Type
    /dev/sda1      2048 31264663 31262616 14,9G Microsoft basic data
    /dev/sda2  31264664 31265687     1024  512K Microsoft basic data
    
     

    Last edit: serge bee 2021-03-15
  • serge bee

    serge bee - 2021-03-15

    UEFI: NTFS (x64)
    [INFO] UEFI v1.10 (Apple, 0x0001000A)
    Apple Inc. MBP121.88Z.0177.B00.1806051659
    Apple Inc. MacbookPro12,1
    Disconnecting potencially blocking drivers
    Searching for target partition on boot disk
    PciRoot(0)/Pci(0x14, 0x0)/USb (0x1, 0x0)
    Fount NTFS target partition:
    PciRoot(0)/Pci(0x14, 0x0)
    Starting NTFS partition service:
    FAIL Unable to start driver: Incompatible version

     
  • Roderick W. Smith

    None of the error messages you've posted are from rEFInd; they're from follow-on programs. The one that refers to MokListRT might be from Shim (a tool for handling Secure Boot on Linux) or something related; Shim employs a feature known as a Machine Owner Key (MOK), and will sometimes display messages about that. OTOH, I searched the Shim source code and didn't find matches to those messages (at least, not the ones I tried specifically), so maybe that's a red herring. It could also be from GRUB, which is Shim's follow-on program. Either way, if you're seeing this when you select the Windows boot option, then something isn't installed correctly. (There are procedures for installing Linux boot loaders and boot managers, including rEFInd, where the Windows boot loader normally goes. These procedures exist to work around buggy EFI implementations and should not be used unless necessary. AFAIK, they aren't necessary on any Apple computer. If you followed such a procedure, you may need to undo it.)

    The clue that strikes me as potentially most important is:

    Starting NTFS partition service:
    FAIL Unable to start driver: Incompatible version

    This implies that the boot loader or an NTFS driver doesn't like something about whatever NTFS volume it's found. It's possible that it's been damaged and needs to be repaired. Of course, repairing it could be tricky if you can't boot the Microsoft installer/recovery tools!

    I doubt if this is a rEFInd issue, but just in case, you can try bypassing rEFInd to boot your external medium directly by holding down the Option/Alt key as you power on the computer. This should bring up Apple's boot manager, which should enable you to boot the external medium. If that fails in a similar way, then either the external medium is bad (improperly prepared or physically defective in some way) or it's failing early in its boot process because of something it doesn't like about your disk layout.

    Also, I asked for the output of gdisk, not fdisk. The gdisk program will produce a summary, as I described earlier, of partition table data, which can help you identify whether a disk has a hybrid MBR. If there is a hybrid MBR on your internal disk (/dev/nvme0n1), or maybe even on the USB flash drive (/dev/sda), and if that hybrid MBR is damaged in some way, then that might explain the Windows boot loader misbehaving. That's wildly speculative at this point, but it remains a possibility, given the information in your follow-on post.

    You might want to prepare for the possible need to wipe the Windows partition clean. Since you mentioned in your first post that you can access your Windows files, I recommend you back up your important Windows data to an external medium. That way, you can wipe the partition clean if that seems desirable and then restore the data later.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.