0
I need suggestions. I wanted to backup sda2 on which Win7 is installed. I deleted the Recovery Resion. (Probably Testdisk can restore this partition because I haven't done any manipulation on that area since then.) Clonezilla said :
This disk contains mismatched GPT and MBR partition: /dev/sda
It will confuse Clonezilla and might make the saved image useless or
fail to clone the disk.
You can use gdisk or sgdisk to fix this issue. E.g. if you are sure
only MBR partition table is the one you want, you can run this command
to destroy the GPT partition table while keep the MBR partition table:
sudo sgdisk -z /dev/sdx
//NOTE// (1) Replace /dev/sdx with the above hard drive name. (2) ALL
EXISTING DATA ON THE DISK WILL BE LOST IF GIVING WRONG COMMAND. USE THIS
COMMAND CAREFULLY!
Please fix this issue then restart Clonezilla again.
So I'm thinking about doing this command, though before doing this I guess I should backup sda by dd in case of accident. And I don't remember whether my laptop had initially a MBR or GTP partition table.
And Win7 don't boot. I tried to restore the MBR and the PBR of Win7 by Windows PE also.
bootsect /nt60 c: /mbr
bootsect /nt60 c:
Both command worked fine. But even after that, Win7 didn't boot. /Boot/BCD and bootmgr.exe.mui already existed.
I intend to backup sda so that the generated image incldes the area enough beyond the end of sda2,
dd if=/dev/sda of=./sda_60G.img bs=32M count=1920 conv=noerror
(First I tried
dd if=/dev/sda bs=32M | lzma > /media/SSD_1/sda.img
,but this takes too long time. It takes about 17 minutes per 1GiB.)
When I enter the command
sgdisk -z /dev/sdx
as it is, is there any possibility that all the data on sda will be lost ? And if I destory all the data on sda by sgdisk, can I restore the present state of my HDD using this sda_60G.img ?
And I read the following Q&A.
Clonezilla fails at cloning with mismatched GPT and MBR partition
enter gdisk, type x to enter the experts' menu, type p, type o, and then type q to quit.
I tried to execute this command. But,there came the following message.
# gdisk /dev/sda
GPT fdisk (gdisk) version 0.8.5
Caution: invalid main GPT header, but valid backup; regenerating main
header
from backup!
Caution! After loading partitions, the CRC doesn't check out!
Warning! Main partition table CRC mismatch! Loaded backup partition table
instead of main partition table!
Warning! One or more CRCs don't match. You should repair the disk!
Partition table scan:
MBR: MBR only
BSD: not present
APM: not present
GPT: damaged
Found valid MBR and corrupt GPT. Which do you want to use? (Using the
GPT MAY permit recovery of GPT data.)
1 - MBR
2 - GPT
3 - Create blank GPT
Your answer:
Which should I choose ?
If I choose 2-GPT,
are there any possibility that all data on sda will be lost ?
Additional info.
# fdisk -l /dev/sda
WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util
fdisk doesn't support GPT. Use GNU Parted.
Disk /dev/sda: 640.1 GB, 640135028736 bytes
255 heads, 63 sectors/track, 77825 cylinders, total 1250263728 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: xxxxxxxxxx
Device Boot Start End Blocks Id System
/dev/sda1 1250058240 1250263039 102400 83 Linux
/dev/sda2 30926848 109707263 39390208 7 HPFS/NTFS/exFAT
Partition table entries are not in disk order
I've made this sad1 to install Grub a few days ago.
And in the end, after dding sda2 I tried "sgdisk -z /dev/sda" copied and pasted. It succeeded ? sda2 and sda1 are both safe.
# sgdisk -z /dev/sda
Caution: invalid main GPT header, but valid
backup; regenerating main header from backup!
Caution! After loading partitions, the CRC doesn't check out!
Warning! Main partition table CRC mismatch!
Loaded backup partition table
instead of main partition table!
Warning! One or more CRCs don't match. You should repair the disk!
Invalid partition data!
GPT data structures destroyed!
You may now partition the disk using fdisk or other utilities.
And this time Clonezilla succeeded. I could get the backup image of sda2. But Win7 still don't boot. I've posted this problem.