LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Is it possible to clone a dual-boot system with either the dd command or Clonezilla? (https://www.linuxquestions.org/questions/linux-software-2/is-it-possible-to-clone-a-dual-boot-system-with-either-the-dd-command-or-clonezilla-4175602808/)

ArtKautz 03-29-2017 05:55 PM

Is it possible to clone a dual-boot system with either the dd command or Clonezilla?
 
This laptop is set up as a dual boot, Windows 10 and Linux Mint 18.1 with the
Cinnamon desktop. I am trying to clone this to a backup SSD, and nothing seems to get the job done. (Before going dual boot, this ran on Linux Mint and I cloned it all the time - no problem at all. That's how I do backups, clone it. If the internal SSD fails, just order a new on and install the backup in the meantime.)

I have tried to clone the internal SSD to an external SSD, and Grub apparently never gets copied. Or if it does, it doesn't work.

The first attempt was done with Clonezilla using the beginner settings. When
that failed, I tried the advanced settings, though there was just one that
looked like a possibility, something about copying sectors (labeled as
inefficient). I checked that one, and didn't work either.

The next attempt was opening a terminal and trying the DD command. I entered:

sudo dd if=/dev/sda of=/dev/sdb bs=4096 (I checked with Gparted to see who was what)
pressed Enter and entered the password.

Over an hour later, it finished. I tried booting from the Inatek case the backup drive is in (also a 500Gb SSD)and it goes straight to Windows - no Grub menu at all.

The details:
Lenovo Laptop, model G50-80 Touch
Memory: 8GB
Processor: Intel Core i5-5200U @ 2.2Ghz
Drive: SSD 500GB (internal one)
Backup drive: 500GB SSD in an Inatek case, connected with a USB3 cable to
a USB3 port on the laptop.

Windows 10
Linux Mint 18.1 Cinnamon Desktop

Anyone got any idea what went wrong, or how to do this. Nope, I am not
interested in buying any $100 software, no matter how good it is. Yea, I get paid by the word. :)

Rickkkk 03-29-2017 06:04 PM

I seem to remember doing just this with Clonezilla in the past, using the "clone the entire disk to image" option. Have you tried that ?

ArtKautz 03-29-2017 06:11 PM

Need to clone disk to disk, not image.
 
No, I haven't tried that. I was interested in just cloning the internal disk to the external one so it was a ready replacement and a complete backup.

Rickkkk 03-29-2017 06:15 PM

Quote:

Originally Posted by ArtKautz (Post 5690084)
No, I haven't tried that. I was interested in just cloning the internal disk to the external one so it was a ready replacement and a complete backup.

I hear you - it honestly should work the same ... The salient point was to use "Disk-to-something" instead of something more granular like "partition-to-something" ...

Maybe other members here have some more insight ...

ArtKautz 03-29-2017 06:26 PM

I hope so, the only other option I am contemplating is put Windows on the original HDD and just plug it into one of the USB3 ports when I need that and boot from it. I would re-do the internal SSD to Linux and then clone it to the other SSD for backup/replacement. I don't use Windows all that often anyway.

syg00 03-29-2017 07:04 PM

This will be UEFI - the boot entries are held in NVRAM; it's not just the BIOS automatically reading the MBR. You'll need to update grub to get new entries in NVRAM.
Try interrupting the boot sequence - <Esc>, <F12>, whatever your kit requires. Then you should be able to select the external, and see if that works. Else pull the internal out and try connecting the backup - chroot into Linux and update grub from there, then swap the SSDs again.

That way you know it works.

Personally I just restore from backup; cloning has too many potentials for failure.

BW-userx 03-29-2017 07:49 PM

this is what I used to clone windows 10 to a 32gb sdd -- it worked flawlessly - I even had different size partitions from a 750GB hdd to a 32GB sdd -- it worked out the sizes on its own. it is free and worth a try to clone your entire 2 system hdd to another one.

http://www.todo-backup.com/backup-re...-10-to-ssd.htm

but the choice is up to you.

jefro 03-29-2017 08:24 PM

Did the easeus software also backup a linux partition or two and grub on an uefi? I know Acronis can, heard a lot about easeus as being OK.

Dumb uefi.

ArtKautz 03-29-2017 10:02 PM

The one thing I haven't tried is swapping the external drive with the internal one and seeing if it works that way. Maybe this weekend. One thing I am not going to do is shell out a buncha bucks for some cloning software that may or may not work. It's just not worth it, especially since I think Windows kinda sucks in the first place. Mostly I need it for (gag) iTunes for my iPhone. After that it's pretty much a malware magnet!

Swapping the drives this weekend (it's supposed to rain anyway) sounds like it's the last possible solution.

syg00 03-29-2017 10:06 PM

Yeah, I know all about that - we've had 200 mm (8 inches) in the last 12 hours. And the really heavy stuff ain't due to get here until tonight ... :eek:

jamiebbbb 03-29-2017 11:40 PM

FOLLOW THESE INSTRUCTION AND YOU WILL BE WELL ON YOUR WAY TO SUCCES.

https://www.securitybeacon.com/cloni...for-linux-g4l/

plasmonics 03-30-2017 05:59 AM

I have done it twice with Clonezilla with no problems. The source drive contained Windows as well as several linux flavors. I attached the target drive to a USB port using a Bytec interface. Then I used clonezilla in expert mode to make a disk to disk copy.

In one case, the target drive was able to boot Windows and all of the linux distros except Debian. After reinstalling grub, Debian booted up. In the other case, I did not have to change anything. Both of my systems are UEFI motherboards with GPT labelled drives. The process should work just as well for BIOS/MBR.

------------------------Edited--------------------------
The dd method should work, but it has to be done from a liveCD, not from any of the host operating systems. The source drive partitions should not be mounted.

jsbjsb001 03-30-2017 06:06 AM

+1 for clonezilla. I don't see why it wouldn't clone a dual-boot system (as others have said), as clonezilla supports NTFS as well as Linux based file systems.

rknichols 03-30-2017 09:14 AM

If you try to boot with both drives connected, you can run into problems. The order in which the OS detects the drives is uncertain. Your two drives are exact copies, including disk identifier, labels, and UUIDs. Windows will get upset when it sees two drives with the same disk identifier. GRUB and Linux have no way** to reliably access one drive vs. the other. LVM gets upset when it finds volumes with duplicate UUIDs. ...

Sometimes it "works", but it's still hard to be sure which drive you're really using.

** OK, you can use /dev/disk/by-id/... which includes the drive serial number, but systems are rarely configured that way.

BW-userx 03-30-2017 10:03 AM

Quote:

Originally Posted by jefro (Post 5690120)
Did the easeus software also backup a linux partition or two and grub on an uefi? I know Acronis can, heard a lot about easeus as being OK.

Dumb uefi.

that is the whole thing. I've never worried about backing up an entire Linux system, I olny back up what I need within Linux, because it is free, and easily reinstalled. I just add back what I need to it to get it back to how I had it set up. ie config files and such.

Seeings how it needs to be updated anyways, to me it seems a waste of time to back up an entire Linux system. The ones I use only take a few minutes to install, an hour tops to get my system back to where it was before I reinstalled it.

SO I've never bothered to even worry about backing up an entire Linux system.


But Windows 10 as I got that free update and it Windows takes forever and a day to install. 3 to 4 hours and it still has not done its updates that lock one out of the system until it is done with its updates and all. I get tired of seeing that 'don't turn off your computer. we're setting up your system then it changes colors and gives me that same message. hours later it is finally done.

The thing is it won't hurt anything to give it a try. Providing he has a means to plug it in and test it when it is done. With my Windows 10 on that sdd I have to use eSATA to get it to boot. Lucky I have that usb-port combo on this laptop.

He will still have his original systems on his hardware so it is not like he is losing anything other then time.

The same maybe goes for everything (software) he can use. Got to give it a try to see if it will work regardless of what it says.

I looked into that Clonezilla before going elsewhere only to find that easyus cloning and was even surprised at it ease of use as I have used other cloning software where one has to have that partiton and dirve the amount it is cloning from.

But I gave it a try and it worked cloning from a larger to smaller hdd without having to set it up to do so even. it just took care of it by itself in under 30 minutes. Keep in mind it was only the operating system without any other software installed in it. I wanted to keep it a clean install before cloning that Win10.

But yeah what does the OP have to lose? he could try Clonezilla and it maybe not work. either way I think he is in a - got a give it a try to see - situation on this one.

So it is still worth a try. as I have MBR on my windows and it cloned everything to the other even the boot part of it. As far as the UEFI boot he'd have to read up on it with that easyus but cloning software is made to clone everything including the bootstrap part of it so it can boot when it is done like the other system. If it didn't then it'd not be actual cloning software.

adding after thought, Linux partition format type.. good question.

this is the only answer I have for that
Quote:

Search Results
EaseUS Disk Copy
www.easeus.com/disk-copy/
EaseUS Disk Copy is a hard drive copy/clone software for PC and Server. Hard drive disk copy, ... Linux boot media; Linux boot media. Free lifetime upgrade.


All times are GMT -5. The time now is 05:44 PM.