Getting the deleted partition back using TestDisk or Timeshift?

I knew it needed it but for the life of me found no way in gparted. So I just did it in terminal.


A gpt disk setup for Gentoo, this will work for most any Linux.

According to another forum, they are not available until after booting:

How are you checking that the snapshot is restored? 
Timeshift does a restart and then does the restore stuff.

So now the questions are:

My editing fstab was not to the right file, so edit after restart?
We know it will probably not boot then without fstab & grub update, so restart and then back to live session and maybe then see the sys files?

Sheila

So I did it right, then? I don’t have a BIOS, never have, but I do have the 3 parts:
boot/efi
ext4
swap

Thanks,
Sheila

You will have to have a unformatted bios_grub for any Linux to boot on a GPT disk, Grub is to large to install on the first sectors of the gpt disc, the bios_grub is the overflow.

Both of my Pop OS & Fedora machines have no BIOS partition.

Have never seen it on any of my Linux machines. Hmm.

Sheila

Do you have an nvme disk in your computer?

Yes, in all of them. Does that make a difference?

Sheila

So I rebooted and in BIOS, the internal drive is still just listed as WD, not Ubuntu (as it was before). Looking at the difference in used space on the root partition:

Was 73.81 and is now 84.28…not that I understand what that means.

But I still do not have access to the restored files from a live session. I will reboot and let it give me errors. Maybe that will tell us something.

Sheila

Where are your Linux partitions? Why is the / partition almost full?

The root partition is 316 GB free? This is the computer I am using now.

The efi is quite large in my opinion at 1022 Mib, but swap is 4 gb and Pop always puts a recovery partition so that is 4 gb. The rest (except for unallocated) is the Linux drive at 922 gb with 606 used.

Sheila

It tells us what I already knew: This restore is not going to boot. Whether it is because of grub & fstab, I don’t know.

So the only thing I know is to restore back to that original Nov 2023 snapshot and see what happens. If it boots fine, then I need to just keep moving up a snapshot at a time. But we will see.

UNLESS: the only reason it booted from that original snapshot before was because I had installed a fresh LM prior to restoring the snapshot. That would mean we cannot restore to an empty disk even with partitions set up.

Sheila

1 Like

And pop has used 600 GB of disc space?

No, my home folders point to an external drive that I use for a lot of my games, but those in Crossover are on the main partition. AND, remember I created a Windows 10 vm in both Oracle and QEMU and gave them each like 100 gb.

Sheila

Are you sure Timeshift has not been writing to your /?

No. I just checked to be sure, but I have that ext HDD that holds not only my /home folders but the TS snapshots as well.
Screenshot from 2024-01-28 16-43-23

That first disk is the ext HDD with a separate partition just for Linux stuff. My internal SSD is at the bottom.

Yes all the system files should be there and viewable.
Use the File Manager, it will mount the partition for you

You only need that for legacy boot. For uefi boot, EFI system
partition is all you need.

It does seem a bit excessive.?

Why not. What are you doing wrong?
All you have to do is mount the partition and cd to there and look at it with ls

That is why. You have to get grub installed and fstab correct and hide grub.cfg

The fresh LM install would have put grub in the EFI partition and wkuld have left a working fstab file in /etc. So that is why it booted without issues.
So maybe you shoukd do it that way…do the fresh install…
you wont need to do the partitions bit, they are there… exceot maybe out a flag on the EFI partition, the do the TS restore of your choice… it should not have to be the original image.

So you have an easystore 5tbWD external drive storing all the TS snapshots/and a 1tb nvme that only has 339 GB free. I am not sure how the attached WD drive will respond to restoring any TS snapshots. I am certain of one thing!!! I have been using Linux for longer than I care, and to fill a 1tb drive to that capacity is beyond my thinking. I also believe that drive has been compromised to the point that the only fix is to delete and start over. I would never let Linux have full access to the / directory. Hope you get what you are wanting, so good luck.