this post was submitted on 13 Jun 2025
25 points (100.0% liked)

Linux

55329 readers
1560 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 6 years ago
MODERATORS
 

My disk was dos labelled (MBR). So I 'fdisk'-ed my disk and entered 'o' to convert it to GPT and wrote it to the disk. Now all the partitions are gone. I want those back. I care about the data rather than the partitions

Edit 0:

Solution:

  • install testdisk
  • run testdisk
  • choose "Create" log
  • choose target disk. Eg: /dev/sda
  • Choose appropriate partition type. Mine was MBR and I chose "Intel" and select "analyze"
  • Now you'll see deleted partitions. Giveem appropriate flags like "*" for boot (efi partition) and "P" any other using space or arrow keys and press enter
  • choose "write" and press y on the prompt to write those found partitions to the disk.

Thanks guys for the help

you are viewing a single comment's thread
view the rest of the comments
[–] INeedMana@lemmy.world 2 points 3 days ago

yeah, you need some help

🤡

On serious note, have you by any chance somehow saved the previous start and end values? Like in history of the shell, terminal or even a piece of paper?
I've found out in the past, that if you recreate the partition table as it was, the data will be read fine

Otherwise, you might need to use RescueCd to try and get the partition borers back. But if you haven't rebooted since that fateful keypress, first focus on trying to get to what partition borders were printed in the terminal earlier. IMO it will be the fastest and easiest
Even if you will get those in cylinders and will have to calculate those back to MBs