The fdisk output is listed in my previous message. I was not aware of the possibility to copy two partitions at the same time with dd. I have never tried this. Sounds like a tricky part.
According to suse_rasputin you probably need to coppy the first and second partitions. You could use parted to dicover the extent of the first two partitions, then the count= parameter of dd and if=/dev/sda to avoid copying the rest of the drive.
Why not copy over the WHOLE disk, subsequently delete the linux partitions. Or keep the /home partition and simply install Leap to the old / ? You can tell the leap installer to use the old /home as home for the new install…
Careful with the blocksize, 64M seems too large. Try this:
sudo blockdev --getbsz /dev/sda2
I wrote a bit on using dd to clone things and you may find it useful (https://forums.opensuse.org/showthread.php/536408-Distro-invariant-SSD-HDD-cloning-procedure-to-an-equal-size-or-large-size-using-dd).
To answer your questions:
- At which point the mSATA is setup in legacy mode. In the past I used to install suse on the space made available by shrinking the windows partition. This time it will be the other way round. I will be installing Linux first.
If you ever boot Windows 7/10 with the mSATA in for the first time, you can initiate the drive to be MBR/UEFI in “Create and format hardisk partitions” (built-in to MS Windows). There are some good google results for changing this with diskpart in Windows command line and Linux console.
Regarding installing Linux first, I recommend you to do Windows first because it will always at least try to over-write Linux partitions.
- I have no CD drive, is it possible to use the live usb to copy the MBR with dd?
There are ways to copy the MBR, but you will have to do some google search, I did but I don’t remember exactly what I did. I recommend you to create try using “Windows rescue drive” on a USB drive and reset MBR this way. Even if you copy the old MBR, it may have some old LEAP 42.3 entries.
Also, rasputin suggested, if you can clone the whole thing, I would do that.
Dear raspu and SJLPHI.
Thank you for your replies. I can copy the entire old drive with dd. It is about 300 GB, which will take some time, but is doable. I have some follow up questions though.
- The new drive will have capacity of 500 GB. What will happen with the extra 200GB, if I am to use the /home, cloned from the old drive, with the new install?
- If I would use the cloned old /home, is Suse leap 15.1 going to take over setting from the old install?
- If I would decide to delete all partitions, except the windows ntfs partitions. Will the new installed GRUB see the windows install.
The block size 64M that was indicated with dd, was a recommendation from that I got on the forum. The explanation back than was that this block size will somehow reduce tension on the disk.
Hello john_snow, to answer your questions:
The extra 200GB will become unpartitioned space and you can easily initialize it using gparted, opensuse partition manager or windows partition manager and use it for anything else you’d like.
If you are talking about installation settings/partition table, no. If you are talking about configurations you’ve made such as thunderbird, application launcher, task manager, custom shortcuts and etc. Yes. However, be aware that this can be disadvantageous because it will also keep thing such as software/applications launchers for the packages you have not yet installed. Such as google-chrome launcher will be available but no google-chrome is installed. You will also have some issues with themes because some themes are not available with LEAP 15.1/15.2, and you will end up with some very weird looking applications.
As long as either:
- Windows is installed in EFI mode, and has an EFI partition, and you install LEAP in EFI mode.
or - Windows is installed in Legacy mode, and it has a valid entry in MBR, and you install LEAP in Legacy mode, and during installation writes a valid entry in MBR.
Yes.
I see, but be aware that if you don’t have the exactly the same block size from source to target (typically 4K), it’s not exactly a bit-by-bit clone, and there is a chance of things getting corrupt. In my experience when I went from 4K source to 0.5K target for example, the corruption was definitely visible. From 4K to 64M, there may be a risk, but I am not 100% sure. I usually try to stay bit-by-bit.
How to tell which is which. I know that I used yast to make grub boot from the ext partition. But how to tell if it is EFI or legacy?
I war reading that one has to look for /sys/firmware/efi. If not present, it is legacy.
That sounds about right (or in /boot/efi), but I would double check with this: How to Check if Windows is Booted in UEFI or Legacy BIOS Mode?
Unfortunately, I can’t boot windows.
Can you boot from Linux? If so, can you try what Ouki suggest:https://unix.stackexchange.com/questions/120221/gpt-or-mbr-how-do-i-know ?