0

I accidentally deleted (not formatted) my Ununtu LVM partition on Windows today using it's Disk Management software. After a long night, I've managed to boot into Ubuntu again with my data intact.

However, now my Nvidia GPU won't work. After some googling it says that I need to boot with a GPT (i don't know why), but it seems like the case as I've the same setup (dual boot Win 10 + Ubuntu 20.04) on my other rig with GPT.

I ran gdisk and it showed that I have MBR: present and GPT: damaged and it also said that I'm supposed to "repair" my disk.

gdisk said that my GPT backup is ok, so I rebuild the partition table by loading from the backup and write it to the disk.

After I rebooted the system, my computer just hanged saying waiting for cryptsetup from [disk UUID].

I've chose to encrypt my disk on Ubuntu during installation, so I've my file system on a LVM (LUKS).

I boot into a Ubuntu Live CD and run gdisk again on my drive, now it says MBR: protective and GPT: present, but when I opened gparted, it showed that the LVM partition is unallocated.

Is there a chance that I can get my data back by converting GTP back to MBR or some other way?

I've lost -> recovered -> and lost my data again ...

I am no expert in disks and hard drives, so my question might not be clear. Please let me know any extra information is required.

Algo7
  • 201
  • Try TestDisk, in your live session, install with sudo apt install testdisk and then run it. – mook765 Jul 09 '21 at 23:21
  • Can you mount it & decrypt it? Mount LVM - duckhook https://ubuntuforums.org/showthread.php?t=2383017&p=13733372#post13733372 https://unix.stackexchange.com/questions/339011/how-do-i-mount-an-lvm-partition/339621#339621 For mounting encrypted see first few lines: https://askubuntu.com/questions/262211/how-do-i-resize-an-encrypted-lvm-to-install-another-copy-of-ubuntu – oldfred Jul 09 '21 at 23:41
  • 1
    There maybe some confusion. MBR and GPT are partition schemes. A drive either has one or the other. It can't be both. You cannot make a conversion from one to another without formatting the drive which effectively wipes the drive. For modern operating systems, you should use GPT. – Nmath Jul 10 '21 at 00:46
  • @oldfred, I am no longer able to mount the LVM, the whole partition now is just unallocated. I've tried all the links you posted. But none seems to work. – Algo7 Jul 10 '21 at 07:34
  • @Nmath, but I used gdisk on the drive when I was still able to perform tasks on the system. After I select "w", which write the changes to the disk, i still could use the system. Everything went down only after i rebooted – Algo7 Jul 10 '21 at 07:35

0 Answers0