Testdisk reporting different sector sizes - unable to restore boot partition
Posted: 26 Jun 2018, 04:42
I hope that you can give me some help.
I have an HP Pavilion Desktop that originally ran Windows 7 / 64 bit with WD 1.5 TB drive.
I upgraded to Windows 10 when is was free and due to frustration with how it ran decided to try Ubuntu 18.04 LTS.
I did not make note of the partition structure before hand and in trying to create a dual boot system, I created a single linux volume.
Testdisk is a life saver as I have been able to copy all my data to an external HD.
I am now trying to get my old partitions restored but I am unsure about what I am seeing/doing and getting confusing results. I can get my PC booting up with the Ubuntu CD and running testdisk from my external drive.
I have tried to create a bootable partition but have had no success. I am seeing both 512 and 4096 sector sizes - my external has 4096 sector sizes is this confusing the issue?
Before I do a deeper analysis I see the following from the log.
*****
Mon Jun 25 20:56:19 2018
Command line: TestDisk
TestDisk 7.0, Data Recovery Utility, April 2015
Christophe GRENIER <grenier@cgsecurity.org>
http://www.cgsecurity.org
OS: Linux, kernel 4.15.0-20-generic (#21-Ubuntu SMP Tue Apr 24 06:16:15 UTC 2018) x86_64
Compiler: GCC 7.2
ext2fs lib: 1.44.1, ntfs lib: libntfs-3g, reiserfs lib: none, ewf lib: none, curses lib: ncurses 6.0
/dev/sda: LBA, LBA48, DCO support
/dev/sda: size 2930277168 sectors
/dev/sda: user_max 2930277168 sectors
/dev/sda: dco 2930277168 sectors
Warning: can't get size for Disk /dev/mapper/control - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/mapper/ubuntu--vg-root - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/mapper/ubuntu--vg-swap_1 - 0 B - 0 sectors, sector size=512
/dev/sr0 is not an ATA disk
Warning: can't get size for Disk /dev/dm-0 - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/dm-1 - 0 B - 0 sectors, sector size=512
Hard disk list
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63, sector size=512 - WDC WD15EARS-60MVWB0, S/N:WD-WCAZA6928672, FW:51.0AB51
Disk /dev/sdf - 3000 GB / 2794 GiB - CHS 45600 255 63, sector size=4096 - Seagate FA GoFlex Desk, FW:0D12
Disk /dev/sr0 - 1921 MB / 1832 MiB - 938400 sectors (RO), sector size=2048 - hp CDDVDW TS-H653T, S/N:R7106GRB362601, FW:H6D1
Partition table type (auto): Intel
Disk /dev/sda - 1500 GB / 1397 GiB - WDC WD15EARS-60MVWB0
Partition table type: Intel
Analyse Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
Geometry from i386 MBR: head=224 sector=19
NTFS at 0/32/33
Current partition structure:
1 * HPFS - NTFS 0 32 33 12 223 19 204800
search_part()
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
LVM2 magic value at 0/32/33
part_size 2930274304
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Results
P Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Hint for advanced users. dmsetup may be used if you prefer to avoid to rewrite the partition table for the moment:
echo "0 2930274304 linear /dev/sda 2048" | dmsetup create test0
interface_write()
1 P Linux LVM 0 32 33 182401 68 3 2930274304
simulate write!
write_mbr_i386: starting...
write_all_log_i386: starting...
No extended partition
TestDisk exited normally.
*****
When I do a deeper analysis I see the following
*****
Mon Jun 25 20:59:29 2018
Command line: TestDisk
TestDisk 7.0, Data Recovery Utility, April 2015
Christophe GRENIER <grenier@cgsecurity.org>
http://www.cgsecurity.org
OS: Linux, kernel 4.15.0-20-generic (#21-Ubuntu SMP Tue Apr 24 06:16:15 UTC 2018) x86_64
Compiler: GCC 7.2
ext2fs lib: 1.44.1, ntfs lib: libntfs-3g, reiserfs lib: none, ewf lib: none, curses lib: ncurses 6.0
/dev/sda: LBA, LBA48, DCO support
/dev/sda: size 2930277168 sectors
/dev/sda: user_max 2930277168 sectors
/dev/sda: dco 2930277168 sectors
Warning: can't get size for Disk /dev/mapper/control - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/mapper/ubuntu--vg-root - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/mapper/ubuntu--vg-swap_1 - 0 B - 0 sectors, sector size=512
/dev/sr0 is not an ATA disk
Warning: can't get size for Disk /dev/dm-0 - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/dm-1 - 0 B - 0 sectors, sector size=512
Hard disk list
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63, sector size=512 - WDC WD15EARS-60MVWB0, S/N:WD-WCAZA6928672, FW:51.0AB51
Disk /dev/sdf - 3000 GB / 2794 GiB - CHS 45600 255 63, sector size=4096 - Seagate FA GoFlex Desk, FW:0D12
Disk /dev/sr0 - 1921 MB / 1832 MiB - 938400 sectors (RO), sector size=2048 - hp CDDVDW TS-H653T, S/N:R7106GRB362601, FW:H6D1
Partition table type (auto): Intel
Disk /dev/sda - 1500 GB / 1397 GiB - WDC WD15EARS-60MVWB0
Partition table type: Intel
Analyse Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
Geometry from i386 MBR: head=224 sector=19
NTFS at 0/32/33
Current partition structure:
1 * HPFS - NTFS 0 32 33 12 223 19 204800
search_part()
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
LVM2 magic value at 0/32/33
part_size 2930274304
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Results
P Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Hint for advanced users. dmsetup may be used if you prefer to avoid to rewrite the partition table for the moment:
echo "0 2930274304 linear /dev/sda 2048" | dmsetup create test0
interface_write()
1 P Linux LVM 0 32 33 182401 68 3 2930274304
search_part()
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
LVM2 magic value at 0/32/33
part_size 2930274304
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
NTFS at 0/32/33
filesystem size 204800
sectors_per_cluster 8
mft_lcn 8533
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 0 32 33 12 223 19 204800
NTFS, blocksize=4096, 104 MB / 100 MiB
BAD_RS LBA=206848 16434495
NTFS at 12/223/19
filesystem size 204800
sectors_per_cluster 8
mft_lcn 8533
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 0 32 33 12 223 19 204800
NTFS found using backup sector, blocksize=4096, 104 MB / 100 MiB
NTFS at 12/223/20
filesystem size 2903789568
sectors_per_cluster 8
mft_lcn 786432
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 12 223 20 180765 106 13 2903789568
NTFS, blocksize=4096, 1486 GB / 1384 GiB
NTFS at 180765/106/14
filesystem size 921600
sectors_per_cluster 8
mft_lcn 38400
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 180765 106 14 180822 199 49 921600
NTFS, blocksize=4096, 471 MB / 450 MiB
NTFS at 180822/199/50
filesystem size 25356288
sectors_per_cluster 8
mft_lcn 786432
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 180822 199 50 182401 35 34 25356288
NTFS, blocksize=4096, 12 GB / 12 GiB
Search for partition aborted
Results
HPFS - NTFS 0 32 33 12 223 19 204800
NTFS, blocksize=4096, 104 MB / 100 MiB
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
HPFS - NTFS 12 223 20 180765 106 13 2903789568
NTFS, blocksize=4096, 1486 GB / 1384 GiB
HPFS - NTFS 180765 106 14 180822 199 49 921600
NTFS, blocksize=4096, 471 MB / 450 MiB
HPFS - NTFS 180822 199 50 182401 35 34 25356288
NTFS, blocksize=4096, 12 GB / 12 GiB
Hint for advanced users. dmsetup may be used if you prefer to avoid to rewrite the partition table for the moment:
echo "0 204800 linear /dev/sda 2048" | dmsetup create test0
echo "0 2930274304 linear /dev/sda 2048" | dmsetup create test1
echo "0 2903789568 linear /dev/sda 206848" | dmsetup create test2
echo "0 921600 linear /dev/sda 2903996416" | dmsetup create test3
echo "0 25356288 linear /dev/sda 2904918016" | dmsetup create test4
ntfs_device_testdisk_io_ioctl() unimplemented
dir_partition inode=5
HPFS - NTFS 0 32 33 12 223 19 204800
NTFS, blocksize=4096, 104 MB / 100 MiB
Directory /
5 dr-xr-xr-x 0 0 0 13-May-2018 17:38 .
5 dr-xr-xr-x 0 0 0 13-May-2018 17:38 ..
35 dr-xr-xr-x 0 0 0 13-May-2018 17:38 Boot
135 dr-xr-xr-x 0 0 0 10-Dec-2015 22:35 Recovery
97 dr-xr-xr-x 0 0 0 5-Feb-2015 21:07 System Volume Information
134 -r--r--r-- 0 0 1 29-Sep-2017 09:41 BOOTNXT
101 -r--r--r-- 0 0 8192 11-Dec-2017 00:19 BOOTSECT.BAK
86 -r--r--r-- 0 0 398136 3-May-2018 02:59 bootmgr
interface_write()
No partition found or selected for recovery
simulate write!
write_mbr_i386: starting...
write_all_log_i386: starting...
No extended partition
Analyse Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
Geometry from i386 MBR: head=224 sector=19
NTFS at 0/32/33
Current partition structure:
1 * HPFS - NTFS 0 32 33 12 223 19 204800
search_part()
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
LVM2 magic value at 0/32/33
part_size 2930274304
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Results
P Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Hint for advanced users. dmsetup may be used if you prefer to avoid to rewrite the partition table for the moment:
echo "0 2930274304 linear /dev/sda 2048" | dmsetup create test0
interface_write()
1 P Linux LVM 0 32 33 182401 68 3 2930274304
simulate write!
write_mbr_i386: starting...
write_all_log_i386: starting...
No extended partition
TestDisk exited normally.
*****
Any help you can provide would be greatly appreciated. I realize that I may have to start from scratch,,,such is life. I would still need a dual boot system for those applications that I need.
Thanks MS.
I have an HP Pavilion Desktop that originally ran Windows 7 / 64 bit with WD 1.5 TB drive.
I upgraded to Windows 10 when is was free and due to frustration with how it ran decided to try Ubuntu 18.04 LTS.
I did not make note of the partition structure before hand and in trying to create a dual boot system, I created a single linux volume.
Testdisk is a life saver as I have been able to copy all my data to an external HD.
I am now trying to get my old partitions restored but I am unsure about what I am seeing/doing and getting confusing results. I can get my PC booting up with the Ubuntu CD and running testdisk from my external drive.
I have tried to create a bootable partition but have had no success. I am seeing both 512 and 4096 sector sizes - my external has 4096 sector sizes is this confusing the issue?
Before I do a deeper analysis I see the following from the log.
*****
Mon Jun 25 20:56:19 2018
Command line: TestDisk
TestDisk 7.0, Data Recovery Utility, April 2015
Christophe GRENIER <grenier@cgsecurity.org>
http://www.cgsecurity.org
OS: Linux, kernel 4.15.0-20-generic (#21-Ubuntu SMP Tue Apr 24 06:16:15 UTC 2018) x86_64
Compiler: GCC 7.2
ext2fs lib: 1.44.1, ntfs lib: libntfs-3g, reiserfs lib: none, ewf lib: none, curses lib: ncurses 6.0
/dev/sda: LBA, LBA48, DCO support
/dev/sda: size 2930277168 sectors
/dev/sda: user_max 2930277168 sectors
/dev/sda: dco 2930277168 sectors
Warning: can't get size for Disk /dev/mapper/control - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/mapper/ubuntu--vg-root - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/mapper/ubuntu--vg-swap_1 - 0 B - 0 sectors, sector size=512
/dev/sr0 is not an ATA disk
Warning: can't get size for Disk /dev/dm-0 - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/dm-1 - 0 B - 0 sectors, sector size=512
Hard disk list
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63, sector size=512 - WDC WD15EARS-60MVWB0, S/N:WD-WCAZA6928672, FW:51.0AB51
Disk /dev/sdf - 3000 GB / 2794 GiB - CHS 45600 255 63, sector size=4096 - Seagate FA GoFlex Desk, FW:0D12
Disk /dev/sr0 - 1921 MB / 1832 MiB - 938400 sectors (RO), sector size=2048 - hp CDDVDW TS-H653T, S/N:R7106GRB362601, FW:H6D1
Partition table type (auto): Intel
Disk /dev/sda - 1500 GB / 1397 GiB - WDC WD15EARS-60MVWB0
Partition table type: Intel
Analyse Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
Geometry from i386 MBR: head=224 sector=19
NTFS at 0/32/33
Current partition structure:
1 * HPFS - NTFS 0 32 33 12 223 19 204800
search_part()
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
LVM2 magic value at 0/32/33
part_size 2930274304
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Results
P Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Hint for advanced users. dmsetup may be used if you prefer to avoid to rewrite the partition table for the moment:
echo "0 2930274304 linear /dev/sda 2048" | dmsetup create test0
interface_write()
1 P Linux LVM 0 32 33 182401 68 3 2930274304
simulate write!
write_mbr_i386: starting...
write_all_log_i386: starting...
No extended partition
TestDisk exited normally.
*****
When I do a deeper analysis I see the following
*****
Mon Jun 25 20:59:29 2018
Command line: TestDisk
TestDisk 7.0, Data Recovery Utility, April 2015
Christophe GRENIER <grenier@cgsecurity.org>
http://www.cgsecurity.org
OS: Linux, kernel 4.15.0-20-generic (#21-Ubuntu SMP Tue Apr 24 06:16:15 UTC 2018) x86_64
Compiler: GCC 7.2
ext2fs lib: 1.44.1, ntfs lib: libntfs-3g, reiserfs lib: none, ewf lib: none, curses lib: ncurses 6.0
/dev/sda: LBA, LBA48, DCO support
/dev/sda: size 2930277168 sectors
/dev/sda: user_max 2930277168 sectors
/dev/sda: dco 2930277168 sectors
Warning: can't get size for Disk /dev/mapper/control - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/mapper/ubuntu--vg-root - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/mapper/ubuntu--vg-swap_1 - 0 B - 0 sectors, sector size=512
/dev/sr0 is not an ATA disk
Warning: can't get size for Disk /dev/dm-0 - 0 B - 0 sectors, sector size=512
Warning: can't get size for Disk /dev/dm-1 - 0 B - 0 sectors, sector size=512
Hard disk list
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63, sector size=512 - WDC WD15EARS-60MVWB0, S/N:WD-WCAZA6928672, FW:51.0AB51
Disk /dev/sdf - 3000 GB / 2794 GiB - CHS 45600 255 63, sector size=4096 - Seagate FA GoFlex Desk, FW:0D12
Disk /dev/sr0 - 1921 MB / 1832 MiB - 938400 sectors (RO), sector size=2048 - hp CDDVDW TS-H653T, S/N:R7106GRB362601, FW:H6D1
Partition table type (auto): Intel
Disk /dev/sda - 1500 GB / 1397 GiB - WDC WD15EARS-60MVWB0
Partition table type: Intel
Analyse Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
Geometry from i386 MBR: head=224 sector=19
NTFS at 0/32/33
Current partition structure:
1 * HPFS - NTFS 0 32 33 12 223 19 204800
search_part()
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
LVM2 magic value at 0/32/33
part_size 2930274304
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Results
P Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Hint for advanced users. dmsetup may be used if you prefer to avoid to rewrite the partition table for the moment:
echo "0 2930274304 linear /dev/sda 2048" | dmsetup create test0
interface_write()
1 P Linux LVM 0 32 33 182401 68 3 2930274304
search_part()
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
LVM2 magic value at 0/32/33
part_size 2930274304
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
NTFS at 0/32/33
filesystem size 204800
sectors_per_cluster 8
mft_lcn 8533
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 0 32 33 12 223 19 204800
NTFS, blocksize=4096, 104 MB / 100 MiB
BAD_RS LBA=206848 16434495
NTFS at 12/223/19
filesystem size 204800
sectors_per_cluster 8
mft_lcn 8533
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 0 32 33 12 223 19 204800
NTFS found using backup sector, blocksize=4096, 104 MB / 100 MiB
NTFS at 12/223/20
filesystem size 2903789568
sectors_per_cluster 8
mft_lcn 786432
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 12 223 20 180765 106 13 2903789568
NTFS, blocksize=4096, 1486 GB / 1384 GiB
NTFS at 180765/106/14
filesystem size 921600
sectors_per_cluster 8
mft_lcn 38400
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 180765 106 14 180822 199 49 921600
NTFS, blocksize=4096, 471 MB / 450 MiB
NTFS at 180822/199/50
filesystem size 25356288
sectors_per_cluster 8
mft_lcn 786432
mftmirr_lcn 2
clusters_per_mft_record -10
clusters_per_index_record 1
HPFS - NTFS 180822 199 50 182401 35 34 25356288
NTFS, blocksize=4096, 12 GB / 12 GiB
Search for partition aborted
Results
HPFS - NTFS 0 32 33 12 223 19 204800
NTFS, blocksize=4096, 104 MB / 100 MiB
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
HPFS - NTFS 12 223 20 180765 106 13 2903789568
NTFS, blocksize=4096, 1486 GB / 1384 GiB
HPFS - NTFS 180765 106 14 180822 199 49 921600
NTFS, blocksize=4096, 471 MB / 450 MiB
HPFS - NTFS 180822 199 50 182401 35 34 25356288
NTFS, blocksize=4096, 12 GB / 12 GiB
Hint for advanced users. dmsetup may be used if you prefer to avoid to rewrite the partition table for the moment:
echo "0 204800 linear /dev/sda 2048" | dmsetup create test0
echo "0 2930274304 linear /dev/sda 2048" | dmsetup create test1
echo "0 2903789568 linear /dev/sda 206848" | dmsetup create test2
echo "0 921600 linear /dev/sda 2903996416" | dmsetup create test3
echo "0 25356288 linear /dev/sda 2904918016" | dmsetup create test4
ntfs_device_testdisk_io_ioctl() unimplemented
dir_partition inode=5
HPFS - NTFS 0 32 33 12 223 19 204800
NTFS, blocksize=4096, 104 MB / 100 MiB
Directory /
5 dr-xr-xr-x 0 0 0 13-May-2018 17:38 .
5 dr-xr-xr-x 0 0 0 13-May-2018 17:38 ..
35 dr-xr-xr-x 0 0 0 13-May-2018 17:38 Boot
135 dr-xr-xr-x 0 0 0 10-Dec-2015 22:35 Recovery
97 dr-xr-xr-x 0 0 0 5-Feb-2015 21:07 System Volume Information
134 -r--r--r-- 0 0 1 29-Sep-2017 09:41 BOOTNXT
101 -r--r--r-- 0 0 8192 11-Dec-2017 00:19 BOOTSECT.BAK
86 -r--r--r-- 0 0 398136 3-May-2018 02:59 bootmgr
interface_write()
No partition found or selected for recovery
simulate write!
write_mbr_i386: starting...
write_all_log_i386: starting...
No extended partition
Analyse Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
Geometry from i386 MBR: head=224 sector=19
NTFS at 0/32/33
Current partition structure:
1 * HPFS - NTFS 0 32 33 12 223 19 204800
search_part()
Disk /dev/sda - 1500 GB / 1397 GiB - CHS 182401 255 63
LVM2 magic value at 0/32/33
part_size 2930274304
Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Results
P Linux LVM 0 32 33 182401 68 3 2930274304
LVM2, 1500 GB / 1397 GiB
Hint for advanced users. dmsetup may be used if you prefer to avoid to rewrite the partition table for the moment:
echo "0 2930274304 linear /dev/sda 2048" | dmsetup create test0
interface_write()
1 P Linux LVM 0 32 33 182401 68 3 2930274304
simulate write!
write_mbr_i386: starting...
write_all_log_i386: starting...
No extended partition
TestDisk exited normally.
*****
Any help you can provide would be greatly appreciated. I realize that I may have to start from scratch,,,such is life. I would still need a dual boot system for those applications that I need.
Thanks MS.