I want to switch to SSD from HDD. I have dual boot on my hp laptop. My C drive in Windows and Ubuntu / directories have less size than new SSD.

But the whole HDD is of 1 TB and SSD of 240 GB. I am putting my SSD inside laptop using hard disk candy into the CD/DVD slot. And I'm not planning to use the DVD port for DVD again.

How can I clone both systems (only C drive + Ubuntu /) without reinstalling everything if that's possible? I want to use SSD for the operating systems and the old HDD for storage. Noob here. Thanks in advance.

1 Answer 1

  • Connect both HDD and SSD to the PC.

  • (optional) Boot Windows installation, install drivers for SSD, shutdown.

  • Boot PC from live cd/usb (Ubuntu will be ok).

  • Open gparted. Resize all partitions to smallest possible size, but leave around 100 mb of free space on each one. And move partitions closer to "left border". Apply this operation.

  • Open terminal. Detect which drive is your HDD and which one is SSD (see cat /proc/partitions)

  • sudo dd if=HDD_DEVICE bs=1M of=SSD_DEVICE - it will take some time

    (for example: sudo dd if=/dev/sda bs=1M of=/dev/nvme0n1)

  • sudo partprobe SSD_DEVICE (for example: /dev/nvme0n1)

  • Probably, you'll need to expand partition table and file systems again, so you can use gparted again.

  • Shutdown. Remove HDD.

  • Try to boot again.


  • If everything looks ok, you can connect HDD, format it, and use as you wish.
  • OR Change UUIDs of HDD file systems: tune2fs /dev/sda1 -U random /dev/sda1 (probably the same for sdb if you have, etc). But don't do this with your SSD!

This operation is potentially dangerous. Be attentive with device names you're using!

  • I don't want to remove and format my HDD. Is there any other way?
    – Yogi Katba
    Oct 25, 2020 at 1:02
  • Can you check the updated question?
    – Yogi Katba
    Oct 26, 2020 at 16:01
  • @YogiKatba. Okey, I've updated answer Oct 27, 2020 at 17:05
  • Can you help me on this askubuntu.com/q/1287412/1041505
    – Yogi Katba
    Oct 27, 2020 at 17:31
  • @YogiKatba, Sorry, I'm not aware of that script and don't know what is the problem there.. Oct 27, 2020 at 20:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.