1

I'm trying to recover some files from an NVMe SSD I installed just recently.

The current situation is as follows:

Installed Ubuntu 20.04 onto the blank drive. Partition table was formatted to GPT.

Attempted to use a backup recovery drive for Windows on another SSD that had Windows installed on it. Backup recovery targets the wrong drive and overwrites the NVMe SSD partition table and partitions. This fails, presumably because there was no Windows system installed to recover.

However now the drive only shows up with Windows partitions. The partition table was also switched to MBR.

Booting up back into an Ubuntu Live USB let me delete the Windows partitions and reformat the partition table, but running testdisk did not identify the previous partitions Ubuntu had set up. It did identify the deleted Windows partitions, however.

How can I recover the ext4 partition that Windows recovery overwrote, or at least files that may exist in that space?

Following that main concern, I attempted to reinstall Ubuntu onto the same drive in exactly the same way after clearing out the Windows partitions (because I assumed it would repartition the drive the exact same way to make finding lost files easier).

However, the installer fails this time, citing: the attempt to mount a filesystem with type vfat at /boot/efi failed.

If I can't recover the data, how can I at least reinstall Ubuntu onto this same drive?

Michael
  • 11
  • A few things: A partition table cannot be switched from GPT to MBR- it would have to have been formatted. Any files that were overwritten are effectively unrecoverable. To install Ubuntu, format the drive again and perform a normal installation (presumably you already know how to do this since you've done it before). See also: https://askubuntu.com/questions/982552/accidentally-did-dd-dev-sda – Nmath Oct 21 '20 at 18:27
  • Old Windows BIOS installs to gpt drive, convert drive to MBR, but left backup gpt partition table. What does this show for that drive? sudo gdisk -l /dev/nvme0n1 if that is correct NVMe drive or change to correct drive. – oldfred Oct 21 '20 at 18:39
  • Are you trying to recover data or just partition? If partition will probably need to remake them from scratch. – crip659 Oct 21 '20 at 19:00

0 Answers0