Boot Camp Windows fails to start after installation

I'm using MacBook Pro 2017 Touch Bar with macOS Sierra 10.12.6..

I've installed Windows 10 via Boot Camp. After the installation, and restarting several times, I got an error "The computer restarted unexpectedly or encounter an unexpected error Windows installation cannot proceed to install Windows, click OK to restart the computer and then restart the installation"

In my Startup Disk PrefPane it already shows both boot volumes (Windows and my Mac). In storage it already shows the Boot Camp partition (40 GB). Tried to use Disk Utility and first aid but nothing happens.

Can someone help me with these problem?

these is the output diskutil list

/dev/disk0 (internal):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                         500.3 GB   disk0
   1:                        EFI EFI                     314.6 MB   disk0s1
   2:          Apple_CoreStorage Untitled                458.4 GB   disk0s2
   3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3
   4:       Microsoft Basic Data BOOTCAMP                41.0 GB    disk0s4

/dev/disk1 (internal, virtual):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:                  Apple_HFS Untitled               +458.0 GB   disk1
                                 Logical Volume on disk0s2
                                 4B06A783-EA29-48E9-BD9C-51B15BF5C840
                                 Unlocked Encrypted

GPT fdisk (gdisk) version 1.0.3

Warning: Devices opened with shared lock will not have their partition table automatically reloaded! NOTE: Write test failed with error number 1. It will be impossible to save changes to this disk's partition table! You may need to deactivate System Integrity Protection to use this program. See https://www.quora.com/How-do-I-turn-off-the-rootless-in-OS-X-El-Capitan-10-11 for more information.

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

Found valid GPT with hybrid MBR; using GPT.

Command (? for help):


If use the diskutil command to delete the BOOTCAMP partition, the partitioning will change from hybrid to protective. When installing Windows, you can create a new partition for the installation of Windows. So, you do not need gdisk. Also, you do not have to disable System Integrity Protection. Enter the commands given below to delete the BOOTCAMP partition.

sudo  diskutil  unmount  disk0s4
sudo  diskutil  eraseVolume  free  n  disk0s4  

I sure hope you properly copied the Boot Camp Support Software to your USB Windows installer flash drive.

I would encourage you to also create a partition for the Windows Recovery Environment (WRE). Although, a WRE partition in not required when installing Windows.

Recommended Proceedure

This steps given below are estimated to take about a hour, but this really depends on how fast you drink coffee.

  1. Find a coffee shop with high speed internet.
  2. Buy a coffee.
  3. Erase everything on your Mac.
  4. Reinstall macOS.
  5. Enjoy the coffee.
  6. Install Windows 10.
  7. Continue to enjoy the coffee.

If you need clarification regarding any part of my answer, let me know.