How can I clone a Windows 10 disk onto a larger disk?
I have bought a larger SSD for my Windows 10 machine and an external USB enclosure and now I would like to transfer the content of the Windows 10 system disk onto the new SSD and eventually replace the system disk with this new SSD.
Problem: The Samsung Migration tool only prints an unspecific error when cloning the disk. As expected, this Software is unusable, and I also do not feel comfortable cloning the disk of a running Windows 10 system.
How can I do this?
94 Answers
I will only use Linux as I am used to it, if someone has a better way using other tools feel free to add an answer.
You can only clone your boot drive if it is not mounted. For this you will need to create a bootable USB drive with Rufus. You will need either a second M.2/SATA connector in your PC or an external case to connect your new drive while you are copying the data. Note that this process will only work as-is if there is no encryption in place.
0. Backup your data. This is the most important step.
0.5 Check if the backup was successful, and if it's possible to retrieve the data
- Download Rufus from Github
- Download SystemRescue from their Website
- Connect an empty USB Stick with a minimum of 4gb of storage to your PC, note that any files on it will be erased
- Start Rufus as Administrator and select your USB, the Systemrescue-x.xx-amd64.iso you've downloaded and click Start. Wait for the process to complete.
Shutdown your computer, boot into the boot menu and select the USB you've just created. You might need to enable legacy boot and the bootmenu in your BIOS settings.
Select the first entry and press enter on Systemrescues boot menu.
Type "startx", press enter and wait for the GUI to load.
[
- Click on the little black icon on the lower left to open a terminal window
- In the window which opens type "lsblk" to show all connected drives, your drive descriptors may vary. I will use sda as the current smaller drive and sdb as the new bigger drive.
9.1. We will use dd to write the data from one drive to the other, bit by bit. You need to make absolutely sure that you don't mix up the input and the output drive, as otherwise your data will be overwritten with 0s from your new, empty drive! Make sure you identified your drives in the previous step without any doubt before continuing! If you are using an external enclosure you can disconnect it and run lsblk again, the drive which disappeared is obviously the one you've disconnected.
- Clone your harddrive with dd:
dd if=/dev/sda of=/dev/sdb status=progress bs=4M && syncwhereifis the input device andofis the output device. You will need to use the identifiers for your drives instead of sda and sdb obviously. Wait patiently until the process has finished.
- When finished, you will notice that your new drive now has the exact same partition structure as your old one. Now we will resize and expand the partition to be able to use all of the storage space. Remember your "main" partitions number for the following steps. In my case it is sdb2.
You'll want to run
ntfsfix /dev/sdb2to make sure your filesystem is clean before the next step.Start
partedin terminal and typeselect /dev/sdbto select your new SSD. Typeprintto get an overview over your partitions. You'll want to work with the last, probably biggest partition, in my case "2".
- Type
resizepartthen2then `100%. Let parted finish its job. The partition now should take the maximum amount of availible space on the device.
Now type
quitRun
ntfsfix /dev/sdbagain, just to be sure.
You're done at this point.
As a last command type
poweroffSwap your drives and boot windows.
Disclaimer: I don't take any responsibility for user error, data loss or nuclear war after following this guide.
8There is a tool made exactly for your task
You can install it on an USB flash drive, boot it and go next-next-next.
Be sure not to have both copies of a single bootable Windows partition connected to your computer when booting into Windows.
2If you roughly know how to use Linux, do:
- As always, when messing with disks, backup all your important data. Otherwise you may be sent into the valley of tears.
- Install Kali Linux Live (or any other live Linux system) onto a USB stick.
- Boot Kali on the Windows 10 machine.
- Connect the new SSD (in the external USB enclosure).
- Type
lsblkto get the names of the disk devices (old and new disk). Look at the sizes. - Transfer the content of the old system disk to the new SSD using:
sudo dd if=/dev/sdX of=/dev/sdY bs=1M status=progress- (Replace X and Y by the old and the new drive, respectively. Getting this the wrong way round will erase your system disk!)
sync- Disconnect the disk and reconnect it.
- Start
gpartedto grow the Windows 10 system partition. - Move the last partition to the very end of the disk. You may need to leave about 1 MB of space after the last partition due to bugs in gparted.
- Increase the size of the Windows 10 system partition (the biggest one) to occupy all the space. It may not be possible to occupy the last 1 MB of the free space, leaving a 1 MB gap, due to bugs in gparted.
- Apply the changes.
- Wait until this completes and a couple of seconds longer.
- Shut down the computer and install the new disk. Do not connect the old disk because it has the same disk id.
- Power-on the computer. It should now boot Windows 10 from the new SSD and show the increased disk space.
- If you want to continue to use the old disk, e.g. to use the data on the system partition on the old disk:
If you're not comfortable with using Linux to clone your disk then you can do this entirely with Windows tools, although you may need two additional storage devices.
If you don't already have a bootable DVD or USB stick, you can create one. Run "control" to open the old Control Panel. For a 16GB USB stick, select Recovery, then Create a recovery drive. For a DVD, select Back up and Restore (Windows 7), then Create system repair disc.
From the Control Panel, Back up and Restore (Windows 7), select Create a system image, and back it up to an external hard drive. Then, replace the old internal drive, boot from the DVD or USB stick, and select Repair your computer. This will allow you to restore the system image from the external hard drive.
Note that your partitions are restored to the same size as they were on your old internal drive. If your original system partition is not the last partition on your disk (typically because of a recovery partition), you won't be directly able to enlarge it from Disk Management. If you don't want the recovery partition, you could just delete it, or you could use a third-party tool to relocate it, and then enlarge your system partition.
2More in general
"Zoraya ter Beek, age 29, just died by assisted suicide in the Netherlands. She was physically healthy, but psychologically depressed. It's an abomination that an entire society would actively facilitate, even encourage, someone ending their own life because they had no hope. Th…"