LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 09-23-2022, 10:11 PM   #1
Eucalyp333
Member
 
Registered: Nov 2021
Distribution: KDE Neon
Posts: 72

Rep: Reputation: Disabled
Cloning primary drive to external drive - any issues?


Hi everyone,

Previously, I used the following command to successfully clone one external drive to another:

sudo dd if=/dev/sd* of=/dev/sd* bs=1024k status=progress

I'm wondering if there might be any issues if I attempt to clone my running system to an external drive using this method?

Thanks.
 
Old 09-23-2022, 10:23 PM   #2
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,675

Rep: Reputation: Disabled
You need to boot from an external media for this method. Technically it is possible to back up your live drive, but you have to combine dd and other copy methods, and you must exclude virtual filesystems like /proc, /dev and /sys. For EFI systems you do not need dd at all.
 
Old 09-23-2022, 10:26 PM   #3
Eucalyp333
Member
 
Registered: Nov 2021
Distribution: KDE Neon
Posts: 72

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Emerson View Post
You need to boot from an external media for this method. Technically it is possible to back up your live drive, but you have to combine dd and other copy methods, and you must exclude virtual filesystems like /proc, /dev and /sys. For EFI systems you do not need dd at all.
Thanks. Had a feeling that might be the case.

If I boot from a USB stick, will that be fine?

Last edited by Eucalyp333; 09-23-2022 at 10:27 PM.
 
Old 09-24-2022, 12:48 AM   #4
mrmazda
LQ Guru
 
Registered: Aug 2016
Location: SE USA
Distribution: openSUSE 24/7; Debian, Knoppix, Mageia, Fedora, OS/2, others
Posts: 6,533
Blog Entries: 1

Rep: Reputation: 2249Reputation: 2249Reputation: 2249Reputation: 2249Reputation: 2249Reputation: 2249Reputation: 2249Reputation: 2249Reputation: 2249Reputation: 2249Reputation: 2249
Quote:
Originally Posted by Eucalyp333 View Post
If I boot from a USB stick, will that be fine?
That's one type of external media, so yes.
 
1 members found this post helpful.
Old 09-24-2022, 02:44 AM   #5
killerhippy
LQ Newbie
 
Registered: Jan 2021
Location: Germany
Distribution: debian
Posts: 27

Rep: Reputation: Disabled
Quote:
Originally Posted by Emerson View Post
You need to boot from an external media for this method. Technically it is possible to back up your live drive, but you have to combine dd and other copy methods, and you must exclude virtual filesystems like /proc, /dev and /sys. For EFI systems you do not need dd at all.
What do mean by saying "For EFI systems you do not need dd at all"?
 
1 members found this post helpful.
Old 09-24-2022, 06:43 AM   #6
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,675

Rep: Reputation: Disabled
You can back up your EFI partition with plain 'cp -a'. Other filesystems as well. With dd you will have a huge image, it will copy the free space, too. With cp method you can create directories (boot, root, home) in your backup media and copy your files over. Will use much less space and won't take ages. Then you can use rsync to update your backup any time you wish, it will take a minute or two. Granted, restoring from such backup involves editing fstab and bootloader conf to replace UUID's. But how often you restore from full backup? Besides, you can set up your system using labels instead of UUID's. Then when you prepare new disk to replace failing drive you create filesystems with same labels and everything works right out of the box. With cp method you can even back up a live system if you know what you are doing. I personally do even less, I back up only user files and configuration files. Restoring from such backup is more work. But again, how often one needs to do full restore? Hasn't happened to me in last ten years. Imagine, if I was backing up 6-7 computers using dd over ten years. How much work that would have been? Nono, in my opinion dd backups are clumsy, time consuming and not practical.
 
1 members found this post helpful.
Old 09-24-2022, 10:24 PM   #7
rclark
Member
 
Registered: Jul 2008
Location: Montana USA
Distribution: KUbuntu, Fedora (KDE), PI OS
Posts: 657

Rep: Reputation: 254Reputation: 254Reputation: 254
I'd suggest just use clonezilla as that is what it is used for. Write that to your USB drive and follow the instructions after booting from it. Worked fine for me.
 
1 members found this post helpful.
  


Reply

Tags
clone, drive, external, internal


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Will cloning one hdd (not ssd) to another encrypted hdd work on a cloning device? hddfsck Linux - Newbie 16 09-05-2019 07:02 AM
Partitioning; safe to add a primary when already having primary and extended/logical? Wim Sturkenboom Linux - General 2 08-16-2009 12:10 PM
Running Fedora 4 on primary master and cant acsess my xp files on primary slave roxberry1 Linux - Newbie 5 01-29-2006 11:37 AM
Dual boot primary Linspire & XP primary slave? watmonki Linspire/Freespire 5 11-01-2005 08:16 PM
boot loader, MBR, redhat9 on primary slave, winxp on primary master samik Linux - Hardware 4 10-15-2003 08:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 06:27 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration