Recovering Deleted Partitions of a Windows 11 disk Topic is solved

How to use TestDisk to recover lost partition
Forum rules
When asking for technical support:
- Search for posts on the same topic before posting a new question.
- Give clear, specific information in the title of your post.
- Include as many details as you can, MOST POSTS WILL GET ONLY ONE OR TWO ANSWERS.
- Post a follow up with a "Thank you" or "This worked!"
- When you learn something, use that knowledge to HELP ANOTHER USER LATER.
Before posting, please read https://www.cgsecurity.org/testdisk.pdf
Locked
Message
Author
rgireyev
Posts: 5
Joined: 26 Jun 2022, 20:38

Recovering Deleted Partitions of a Windows 11 disk

#1 Post by rgireyev »

Hello!

First of all I'd like to say a huge Thank you for this amazing tool, and another Thank you for this forum. WOW!

Now on to my question.
I have a Samsung SSD 830 drive that is advertised as 256G and has an SATA interface.
I have had Windows 10 Pro installed on it, which I later upgraded to Windows 11 Pro.
I had recently purchased a 1TB drive that I tried to do a clean install of Windows 11 on, and in the process deleted the partitions on my Samsung 830. :oops:
The Samsung 830 was my only drive in this PC. My motherboard is gigabyte hd3p z370 in case that is relevant.

My confusion lies in the following. When I run TestDisk and I choose the Intel partition type things appear to go somewhat smoothly. I was able to find the 4 partitions and they started at 0 and ended wherever they ended. The 4 partitions were in Deleted status and I marked the first one as boot and the rest as Primary.

However, when I go to the EFI-GPT world things look rather wild. My first partition does not start with 0 and it finds 6 partitions all in all. :o I went with the Intel suggestion even though my gut feeling makes me think that Windows 11 is probably EFI-GPT. So I would love some guidance on this. Namely should I proceed and try to recover (assuming it is even possible) the disk as EFI-GPT? Or should I leave it as Intel and try to make it work that way?

Currently when I try to boot from the disk Windows complains that the disk is corrupted, and will not boot. :( So I would also love some guidance on how to fix that.
Here are the screenshots.
Drive List

Code: Select all

Select a media (use Arrow keys, then press Enter):
 Disk /dev/sda - 256 GB / 238 GiB - SAMSUNG SSD 830 Series
Partitions as Intel

Code: Select all

Disk /dev/sda - 256 GB / 238 GiB - CHS 31130 255 63
Current partition structure:
     Partition                  Start        End    Size in sectors

 1 * HPFS - NTFS              0  32 33    12 223 19     204800 [System Reserved]
 2 P HPFS - NTFS             12 223 20 31052  23 11  498644992
 3 P FAT32 LBA            31052  23 12 31064 213 61     204800 [NO NAME]
 4 P HPFS - NTFS          31064 213 62 31130 158  4    1056768
Partitions as EFI-GPT

Code: Select all


Disk /dev/sda - 256 GB / 238 GiB - CHS 31130 255 63
     Partition               Start        End    Size in sectors
>P MS Data                     2048     206847     204800 [System Reserved]
 D MS Data                   206848  498850248  498643401
 D MS Data                   206848  500115455  499908608
 D MS Data                497999873  499056640    1056768
 D EFI System             498851840  499056639     204800 [EFI System Partition]
 D MS Data                499056640  500113407    1056768
Doing the Deep Scan on EFI-GPT produces many error messages and gives a really long list of partitions.
First this screen

Code: Select all

Disk /dev/sda - 256 GB / 238 GiB - CHS 31130 255 63

The harddisk (256 GB / 238 GiB) seems too small! (< 567 GB / 528 GiB)
Check the harddisk size: HD jumper settings, BIOS detection...

The following partitions can't be recovered:
     Partition               Start        End    Size in sectors
>  Mac HFS                219689586 1108882291  889192706
   Mac HFS                223893609  974674026  750780418
   Mac HFS                223893616  974674289  750780674
   Mac HFS                335899423  537228064  201328642
   MS Data                498850248  997493648  498643401
   MS Data                500113407  501170174    1056768
   MS Data                500115455 1000024062  499908608

HFS blocksize=33554432, 455 GB / 424 GiB
And then this one:

Code: Select all


Disk /dev/sda - 256 GB / 238 GiB - CHS 31130 255 63
     Partition               Start        End    Size in sectors
>D MS Data                     2048     206847     204800 [System Reserved]
 D MS Data                     2344     207143     204800
 D MS Data                   206847     411646     204800
 D MS Data                   206848  498850248  498643401
 D MS Data                   206848  500115455  499908608
 D Mac HFS                134570785  335899426  201328642
 D EFI System             134754336  134757215       2880 [EFI System Partition]
 D EFI System             177927616  177930495       2880 [EFI System Partition]
 D MS Data                186507459  186513632       6174
 D MS Data                186513632  186519805       6174 [Boot]
 D MS Data                193346035  193352208       6174
 D MS Data                193352208  193358381       6174 [Boot]
 D MS Data                193476739  193482912       6174
 D MS Data                193482912  193489085       6174 [Boot]
 D EFI System             193489104  193491983       2880 [EFI System Partition]
 D EFI System             196396560  196399439       2880 [EFI System Partition]
 D MS Data                199492491  199498664       6174
 D MS Data                199498664  199504837       6174 [Boot]
 D MS Data                200702923  200709096       6174
 D MS Data                200709096  200715269       6174 [Boot]
 D EFI System             228331008  228333887       2880 [EFI System Partition]
 D EFI System             229173472  229176351       2880 [EFI System Partition]
 D EFI System             241537072  241539951       2880 [EFI System Partition]
 D EFI System             286816344  286819223       2880 [EFI System Partition]
 D MS Data                497999873  499056640    1056768
 D EFI System             498851840  499056639     204800 [EFI System Partition]
 D MS Data                498851846  499056645     204800 [NO NAME]
 D MS Data                499056640  500113407    1056768














Structure: Ok.  Use Up/Down Arrow keys to select partition.
Use Left/Right Arrow keys to CHANGE partition characteristics:
                P=Primary  D=Deleted
Keys A: add partition, L: load backup, T: change type, P: list files,
     Enter: to continue
NTFS, blocksize=4096, 104 MB / 100 MiB
Lastly when I go to view the files in the Partitions listed I do see everything there.
TIA
Rudy
recuperation
Posts: 3036
Joined: 04 Jan 2019, 09:48
Location: Hannover, Deutschland (Germany, Allemagne)

Re: Recovering Deleted Partitions of a Windows 11 disk

#2 Post by recuperation »

rgireyev wrote: 26 Jun 2022, 22:21 Hello!

First of all I'd like to say a huge Thank you for this amazing tool, and another Thank you for this forum. WOW!

Now on to my question.
I have a Samsung SSD 830 drive that is advertised as 256G and has an SATA interface.
I have had Windows 10 Pro installed on it, which I later upgraded to Windows 11 Pro.
I had recently purchased a 1TB drive that I tried to do a clean install of Windows 11 on, and in the process deleted the partitions on my Samsung 830. :oops:
The Samsung 830 was my only drive in this PC. My motherboard is gigabyte hd3p z370 in case that is relevant.

My confusion lies in the following. When I run TestDisk and I choose the Intel partition type things appear to go somewhat smoothly. I was able to find the 4 partitions and they started at 0
What is zero?!
and ended wherever they ended. The 4 partitions were in Deleted status and I marked the first one as boot and the rest as Primary.

However, when I go to the EFI-GPT world things look rather wild. My first partition does not start with 0 and it finds 6 partitions all in all. :o I went with the Intel suggestion even though my gut feeling makes me think that Windows 11 is probably EFI-GPT. So I would love some guidance on this. Namely should I proceed and try to recover (assuming it is even possible) the disk as EFI-GPT? Or should I leave it as Intel and try to make it work that way?
Check your BIOS settings. When in doubt, perform that clean install on your 1TB disk (after removing the Samsung 830 disk) and replay your old installation process.
Currently when I try to boot from the disk Windows complains that the disk is corrupted, and will not boot. :( So I would also love some guidance on how to fix that.
Once your lost partitions are visible again you can try a repair installation booting from your installation media.
rgireyev
Posts: 5
Joined: 26 Jun 2022, 20:38

Re: Recovering Deleted Partitions of a Windows 11 disk

#3 Post by rgireyev »

Thank you for your reply and your time.
What is zero?!
From my first Post the second listing where I list Partitions that were recovered as Intel type.
The very first Partition that is numbered 1 and has an asterisk indicating that it is a boot Partition.
The column that says Start, starts with 0 (and then 32 33)

Code: Select all

1 * HPFS - NTFS              0  32 33    12 223 19     204800 [System Reserved]
Check your BIOS settings.
I believe this answer was on whether recovering the partitions as Intel or EFI-GPT is the correct course of action.
What should I look for in the BIOS? I see the drive in my BIOS under the SATA devices which is where it belongs.
Once your lost partitions are visible again you can try a repair installation booting from your installation media.
OK. Will try that next and report back my progress.

A few more bits of info:
1. In this Ubuntu Linux, I see my drive as 3 drives just in case that is an indicator of something. :)
2. When I run Disks and I do Check Partition, it tells me that the second partition needs repair. This is my largest partition. Number 2 in the Listing 2 above. And if I try to repair it, the process fails.

Tangent
Sadly the 1Tb drive turned out to be defective. And my unrelenting attempts to try and make it work is what caused me to delete the partitions on my Samsung 830 in the first place. <grrrrr> It was a Samsung 970 Evo Plus. I initially had my Samsung 830 unplugged. But as Windows 11 refused to be installed on the 970 or to even format it, I plugged the 830 back in to see if I can do it with the disk manager program, and now I'm killing unspoken number of hours trying to recover from that. LOL The 970 I had to send back for Warranty repairs. :(
recuperation
Posts: 3036
Joined: 04 Jan 2019, 09:48
Location: Hannover, Deutschland (Germany, Allemagne)

Re: Recovering Deleted Partitions of a Windows 11 disk

#4 Post by recuperation »

rgireyev wrote: 27 Jun 2022, 15:25 Thank you for your reply and your time.
What is zero?!
From my first Post the second listing where I list Partitions that were recovered as Intel type.
The very first Partition that is numbered 1 and has an asterisk indicating that it is a boot Partition.
The column that says Start, starts with 0 (and then 32 33)

Code: Select all

1 * HPFS - NTFS              0  32 33    12 223 19     204800 [System Reserved]
The partition above has a start location of cyclinder=0, head=32, sector=33 which can be converted into a LBA number (a sector number running from zero to number of sectors of your drive minus 1. If you say "starts 0" this means that you are referring to a LBA number, obviously because a CHS-address contains a value for H and S as well. Typically there is a MBR at LBA=0 (even with GPT drives) and no start of a partition.
Check your BIOS settings.
I believe this answer was on whether recovering the partitions as Intel or EFI-GPT is the correct course of action.
What should I look for in the BIOS? I see the drive in my BIOS under the SATA devices which is where it belongs.
Sorry, that was too short. Your BIOS contains information about its boot mode. If it is set to UEFI instead of CSM (compatibility support module) a windows installation only allows for GPT.
Once your lost partitions are visible again you can try a repair installation booting from your installation media.
OK. Will try that next and report back my progress.

A few more bits of info:
1. In this Ubuntu Linux, I see my drive as 3 drives just in case that is an indicator of something. :)
2. When I run Disks and I do Check Partition, it tells me that the second partition needs repair. This is my largest partition. Number 2 in the Listing 2 above. And if I try to repair it, the process fails.
Partition repairs or running chkdsk under windows cannot be reversed. You shoud duplicate your drive before doing so.
rgireyev
Posts: 5
Joined: 26 Jun 2022, 20:38

Re: Recovering Deleted Partitions of a Windows 11 disk

#5 Post by rgireyev »

OK. Here's my report in trying the Repair Mode during windows install.

1. Using diskpart I see all 4 volumes, however there is no drive letter assigned to any of them, and the status says offline.
2. Attempts to run chkdsk with either /r or /f fail with the message CHKDSK is not available for RAW drives.

If there is a way to fix this in Linux that of course would be much preferred.
But at this point I'll take any recommendation. :)

One again a million Thanks.
Rudy
recuperation
Posts: 3036
Joined: 04 Jan 2019, 09:48
Location: Hannover, Deutschland (Germany, Allemagne)

Re: Recovering Deleted Partitions of a Windows 11 disk

#6 Post by recuperation »

Obviously you did more than justing deleting partitions as stated in your initial posting. In this case you would have needed to check the status of each partition using the "p"-key ("list files") to look inside and search for accessible content. If this does not work you are left with Photorec or other recovery software.
rgireyev
Posts: 5
Joined: 26 Jun 2022, 20:38

Re: Recovering Deleted Partitions of a Windows 11 disk

#7 Post by rgireyev »

I did do the P listing in every partition and it does list my files.
I believe the issue at the moment is that the Partiotions are stuck in Read Only Mode and cannot be brought back online.
They say offline and refuse to accept command "online".

Will Photorec (or any other software) restore it to a bootable drive so that it will be like before?
Or should I give up and save whatever I can from it and start over by reinstalling windows 11 on it?

Thank You for all of your help once again.
Rudy
recuperation
Posts: 3036
Joined: 04 Jan 2019, 09:48
Location: Hannover, Deutschland (Germany, Allemagne)

Re: Recovering Deleted Partitions of a Windows 11 disk

#8 Post by recuperation »

rgireyev wrote: 28 Jun 2022, 16:58 I did do the P listing in every partition and it does list my files.
I believe the issue at the moment is that the Partiotions are stuck in Read Only Mode and cannot be brought back online.
They say offline and refuse to accept command "online".

Will Photorec (or any other software) restore it to a bootable drive so that it will be like before?
Using Photorec is an armageddon tool and should be used if Testdisk fails. Using Photorec you loose metadata information such as folder structures and original file names because of the way it operates. If you can see your files using the "p"-key you should keep using Testdisk to save your personal data to another disk from within that Testdisk menu.
Photorec will not be able to produce a bootable device for you.


Or should I give up and save whatever I can from it and start over by reinstalling windows 11 on it?
Save your personal data first and reinstall windows 11 afterwards.

Recovery software is made for recovery. I am not aware of another software that is intended to repair your broken installation other than the repair mode of your installation media.
rgireyev
Posts: 5
Joined: 26 Jun 2022, 20:38

Re: Recovering Deleted Partitions of a Windows 11 disk

#9 Post by rgireyev »

Thank you recuperation.
I can actually see my files in the File Manager in Linux.
Even though my disk appears as 3 different disks in Linux. :roll:
I guess I'll just bite the bullet and backup my data and do a clean install of Windows 11 on the drive.

All the best
Rudy
Locked