Select Page

Windows can’t be installed on drive…

When installing Windows onto a new system and the target drive was previously used for another purpose or operating environment, the Windows Installer sometimes fails with the message “Windows can’t be installed on drive …”

Symptom

When the Windows Installer attempts to install on a computer, and at the step where the installer attempts to partition the OS drive, the installer displays the above error message error and cannot continue.

KB5 - 1 Error Message

Some operating systems such as versions of Linux and SunOS create a partition where Windows cannot read and remove the existing partition. Even when using the Windows Installer and deleting the partition, the disk drive is left in a state unusable by the Windows Installer. The installer will produce the following message:

“We couldn’t create a new partition or locate an existing one. For more information, see the Setup log files.”

KB5 - 2 Error Message 2

Solution

To resolve this condition and put the OS drive into a clean state, the system will have to be booted into a Windows PE Environment. There is a Windows PE environment included with the Window Installation system.

Boot into Windows PE from Windows Installer

  1. Boot the computer system from the Windows Installer media, and select “Repair your Computer”.
  2. Next, select the Troubleshoot option
  3. Then, select the Command Prompt

You are now booted into a tiny version of Windows. From this environment, we can then clean and process the drive.

Clean and partition the drive

From the command prompt, type the following sequence of commands.

Command Notes
DISKPART
  • This will start the disk management command line utility.
  • This is the command line equivalent to Windows Disk Management.
LIST DISK
  • This will show a list of disks available. If you have a USB drive plugged in, it will likely include this in the list.
  • Select the disk to install Windows.
SELECT DISK x
  • If you type LIST DISK again, an asterisk will show the selected drive. The next disk commands will be performed on this selected disk
  • Be careful to select the correct disk
CLEAN This will erase the disk completely including partitions and the boot sector including MBR records
CREATE PARTITION PRIMARY Technically we do not have to do the next commands, but we should test the functionality of the OS disk and the Windows drivers
SELECT PARTITION 1
ACTIVE
FORMAT QUICK FS=NTFS
ASSIGN
EXIT
EXIT

If this procedure competes correctly, the Windows Installer should complete correctly.

KB5 - 3 Installs correctly

Step by Step with Screen Shots

Exit the Windows installer environment by clicking on the exit X button (top right)

KB5 - 4 Blow 1

Return to the beginning of the Windows Installation process. Click on the “Repair your computer” link.

KB5 - 5 Blow 2

Select the Troubleshoot option.

KB5 - 6 Blow 3

Select the “Command Prompt” option

KB5 - 8 Blow 5

Select the correct disk to clean.

In this example, the 29GB disk is the Windows Installation USB drive.
The LIST DISK command now shows Disk 16 being managed.

Type the following DISKPART commands:

CLEAN

CREATE PARTITION PRIMARY

SELECT PARTITION 1

ACTIVE

FORMAT QUICK FS=NTFS

ASSIGN

EXIT

KB5 - 9 Blow 7

Select Turn off your PC and then restart the installation process.

KB5 - 10 Blow 8

Was this article helpful?

Submit a Comment

Your email address will not be published. Required fields are marked *