0

So guys I got panicked since my data gone, I tried the solution to use backup Superblock from this askubuntu page but still no luck. but when I tried sudo fsck.ext4 -vy /dev/md0 I got this message /dev/md0/ clean, 11/244178944 files, blablablah.

this is the screenshot I get from sudo fsck.ext4

Do I still have a chance to recover that 244000++ files? the guy from the link said when suitable superblock has been found, I can recover the data, Did I use the wrong superblock?

edit So I did the sudo blkid and what I get is this one

dev/sda1, sdb, sdd1, and sdc is the Raid HDD that contains the whole file that I meant. So what can I do next?

  • /dev/md0 is not mounted. You will need to look at UUIDs. I would recommend that you edit your question and add the following output. sudo blkid. There you will probably see something like /dev/md0p1: UUID="xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" BLOCK... The UUID is what can be added to your /etc/fstab file to mount the device of /dev/md0 so that you should be able to hopefully browse your files again. – Terrance Jan 12 '24 at 05:43
  • /dev/md0 not mounted is intentional tbh to make sure nothing is written to the HDD. But should I mount first before doing sudo blkid or I can do it without mounting the dev/md0? – IT_Sobad Jan 12 '24 at 06:17
  • blkid reads only the UUID regardless of if the drive is mounted or not. But, without mounting the /dev/md0 you cannot browse into it to see all your files. – Terrance Jan 12 '24 at 14:15
  • okay so I already found the UUID, what can I do next? Do I have to edit the /dev/md0 UUID to the same UUID as the raid HDD? – IT_Sobad Jan 13 '24 at 02:42
  • You need to give it a mount point. Make a directory like sudo mkdir /media/storage or something like that. Then add a line to the bottom of your /etc/fstab file like UUID=6e5c07a5-d751-490a-92a6-2d1dee2237e9 /media/storage ext4 defaults 0 0. Then after it is added then you can mount it by typing in sudo mount -a which should mount it at /media/storage. It is just odd though that all of your other drives that are mounted have partitions on them, but this RAID does not. – Terrance Jan 13 '24 at 03:43
  • I still didn't find any file when I mount the HDD – IT_Sobad Jan 13 '24 at 04:12
  • Unfortunately, I am only guessing right now based on the info you have given. On the linked answer you put in your question the person did state to test the superblock numbers until they matched and then recovered that SuperBlock. I hope it didn't overwrite the backup SuperBlocks that were there. – Terrance Jan 13 '24 at 04:20

0 Answers0