How To Clone a Hard Drive in Ubuntu 16.04/18.04

this opportunity, we will see how to clone a hard disk in Ubuntu 16.04, but this process is similar to other, other available distros.

Clone Disk using DD Command

The DD command (Dataset Definition) is a command that comes integrated with the Operating System and allows us to perform multiple management tasks on hard drives securely and straightforwardly keeping the integrity of them.

With DD we can perform tasks such as cloning a partition or a complete unit, deleting all data from a disk, so we must use it with caution.

The basic syntax of the command is:

sudo dd if=source of=destination

IF= Input File –

OF= Output File –

In addition to the previous syntax, we will add the following lines:

bs=64K conv=noerror,sync

The 64K value indicates the size of the blocks, bs (Block Size), remember that the larger the size of the block the faster the transfer but, the smaller, the more reliable.

To see the units in Ubuntu 16.04, we will use the command:

sudo fdisk -l

The objective is to clone the path/dev/sda2 in the destination /dev/sdb, for this we will execute the following:

dd if=/dev/sda2 of=/dev/sdb bs=64K conv=noerror,sync

There it will be necessary to wait for the cloning process which depends on the capacity and content of the source disk. As we can see, the process is completed thanks to the DD command efficiently.

Using this method, we will have the possibility to clone our hard drives and in this way always guarantee the integrity and availability of the information hosted there.

Similar Posts

Leave a Reply

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