I accidently deleted two partitions from an external usb drive. One was a blank ntsb partition with about 1gb. The other was a LUKS partition of the rest of the 250gb drive. I did not format or do anything else. When I realized what happened I tried to follow advice on the site and ran testdisk which prompted me to make a backup image which I did. I messed around but didn't manage to get a restoration to work.
Being someone who has used Ubuntu for just several months, I am fairly comfortable using terminal commands if I know what the different switches and variables mean (the first PCs I ever learned to use ran MS-DOS and PC-DOS (which means I wanted to use dir and del instead of ls and rm or use / instead of - to set variables, at least until I practiced!).However some of the advice I found for similar situations assumes a level of knowledge I just don't have or are based on previous
Could someone give me tutorial or step-by-step on how to restore the partition? Do I need to use the backup and if so how do I proceed? I am using 20.04.
sudo apt install testdisk
, but you already seem to have it) should be able to reccover partitions, and has an example guide on how to do it. – mivk Feb 07 '22 at 19:18