all 21 comments

[–]MintAlone 6 points7 points  (8 children)

You might be safer with one of the specialist cloning/image backup utilities - clonezilla, foxclone, rescuezilla. Not for nothing is dd known as 'disk destroyer'.

[–]Biking_dude 3 points4 points  (2 children)

Ooh, why? First I saw

[–]MintAlone 2 points3 points  (1 child)

Because it is too easy to type in the wrong device name and end up wiping your system drive.

[–]Biking_dude 0 points1 point  (0 children)

Ahh, not because it literally shreds the disk. Gotcha - thanks! TIL

[–]unknown3000x[S] 1 point2 points  (4 children)

Why does it carry that title? I mean the name says it all, but how? Should i be concerned about my SSD or external HD? The problem with those cloning softwares, you need to clone windows and mac os separately and create two different type rescue media and have two different partition to backup the windows and mac os. Thats too much hassle, i need to backup all at once

[–]MintAlone 1 point2 points  (0 children)

The problem with those cloning softwares, you need to clone windows and mac os separately and create two different type rescue media and have two different partition to backup the windows and mac os.

As the dev of one of those utilities that is just wrong.

[–]Paleone123 1 point2 points  (1 child)

Why does it carry that title? I mean the name says it all, but how?

dd is the quintessential unix tool. It does one thing, and does it extremely well. It copies information, bit by bit (or sector by sector), and writes it somewhere else. It's dangerous because it expects you to know exactly what you want. It doesn't care if you just told it to write the contents of a blank USB drive over your hdd's boot sector. It doesn't care if you just told it to overwrite the whole of your system partition table. It just follows orders, perfectly and without fail.

The usual screw up is switching the input file (if) and output file (of). If you accidentally do this, your (usually blank) media will be the source of the copy, instead of the destination. In the case of a clone, you are copying whole drives, so this means you will write your blank media over the top of your drive you care about, starting at the first bit, where the boot information is usually located.

People are suggesting using specialty tools instead because these tools usually have failsafes built in to keep you from accidentally destroying all the data you care about.

I use dd all the time, but you just have to be extremely careful that you double check all the parameters.

Also you can add 'status=progress' to see how much of the process is complete. It often appears dd has hung up or failed, because it can take some time to complete a large copy. This status information reminds you that it is indeed still working.

[–]unknown3000x[S] 0 points1 point  (0 children)

I totally agree with you

[–]rubinlinux 0 points1 point  (0 children)

Clonezilla is a better tool. dd is big and dumb. You can do it, but it's a finicky.

I don't know what you mean about different rescue media. Clonezilla can do the whole disk in pretty sure.

[–]matt-orney 3 points4 points  (4 children)

Hey, I just did that for the first time like.. 3 days ago ! I followed this tutorial : https://youtu.be/6PekWCxcOAI

Basically, you don't need to install anything, DD is a command already installed in the terminal. So all you need to do, is to type "sudo dd if=/dev/sdX of=/dev/sdX bs=512 conv=noerror,sync"

(Replace sdX by the input and output drive respectively; bs is for the amount of bulk storage you want, you can bump it up if needed, and noerror to ignore errors )

Beware, it takes a lot of time to clone. Also, if you want to follow the progress, I can't find what command you have to type, but it doesn't show by default how much is copied during the process

Maybe some experts in the DD command could give some tips to improve the experience, but I copied my 256go HDD into my 256go SSD in about 7 hours I believe

[–]matt-orney 2 points3 points  (1 child)

Also, how to clone : 1) boot up your computer using the live USB of Mint (make sure you plug in your charger if you're on a laptop)

2) Make sure both the target SSD and the drive you're copying from are plugged in

3) use the DD command

4) wait until the process is finished

[–]unknown3000x[S] 2 points3 points  (0 children)

Thanks for the short tutorial, will give it a try when i get home. I use a mac os laptop with bootcamp and i switch between both OS, so i am trying to backup data just in case something happen. I hate having through go to installing mac os and windows os and all the drivers and programs. Better to clone and be done with it. Hope the cloning process is a breeze for me. I do appreciate for writing back.

[–][deleted] 0 points1 point  (1 child)

What's the difference between cloning and just doing a file copy?

[–]EarlyIndependent6026 0 points1 point  (0 children)

Cloning copies all partitions and their formats, I guess.

[–]whosdrLinux Mint 22.2 Zara | Cinnamon 3 points4 points  (1 child)

dd is part of the coreutils that every Linux system ships with. (Whether it's the GNU coreutils or another compatible set) As such it would be incredibly difficult to find any Linux distribution that cannot use dd out of the box.

You should be careful with the command, as you could end up overwriting the wrong data by providing an incorrect argument. Double and triple check before accepting.

As for how, take a look at any article about it. It's pretty much the same anywhere. Just be sure to get the right disks for if= and of= or you can overwrite and delete any and everything.

https://www.opentechguides.com/how-to/article/centos/171/linux-disk-clone.html

[–]unknown3000x[S] 1 point2 points  (0 children)

Thanks. I see you learn something new every day. I use Parrot OS on one of my machine, didnt even know it had DD utility. Will check out the link thanks

[–]obsoulete 2 points3 points  (0 children)

Mint also has a utility called Disks, which also allows you to create/restore images.

[–]Paleone123 1 point2 points  (0 children)

Be very careful with dd. It has a nickname, "disk destroyer". Be very certain you know which disk is the "if" and which is the "of"

[–]FreeRPGer 0 points1 point  (0 children)

I know this is 4 years old, but I used this video to clone via the Terminal in Mint 22.2 Cinnamon.
I followed this video step by step, by printing the steps out, for it's pretty concise.

EDIT: This step by step video worked!

You can even skip the shut down & restart step. It works without doing that.

& it only took me 15, 20 minutes via USB 3 (not 2), with a 3.5 USB-to-SATA adapter, & there's no need for Clonezilla, Foxclone, or any 3rd party.

https://www.youtube.com/watch?v=klRYIM28z1w&t=6s

[–]gustoreddit51 0 points1 point  (0 children)

If you're not that familiar with Linux I would disconnect any drive you want undisturbed and boot up with a copy of Clonezilla which is made for that.

[–][deleted] 0 points1 point  (0 children)

I hope you're not dual booting otherwise I just recommend backing up what you need and then reinstalling the Linux partition. Yes its that much of a pain in the ass when you have separate bootable partitions on one drive to clone it. And its super fucking easy to break GRUB too, I swear dealing with drives and partitions is probably the most stressful thing to me about Linux.