Score:0

Trying to extract my files from corrupted sd card [img file] or fix it

ci flag
5 5

I have corrupted image file based on Ubuntu 18.04. Inside Outside It was corrupted because of update interrupt and now i cant boot it. I have very important files on this sd but i cant extract them, because: I can't get access to some folders Error:Structure need cleaning.

To solve this problem i tried:

  1. fsck.ext4 command But i cant execute it and in my point of view, i should be able to, because there is only 1 user with root in the system (me).My corrupted image file is read only, i can mount it only in this way

     sudo mount -o ro,noload /dev/loop11 /media/sf_Jetson
    

Maybe i could make this file r/w ?

  1. Also i tried to use sudo photorec [guide : https://www.handyrecovery.com/linux-sd-card-recovery/#recovery-guide] It recovered my files but without any system: Almost useless Chaos I just cant find my python programms in this garbadge.Too many py files without names

  2. Besides this i received advice on nividia forums: "You may chroot into the rootfs folder on your SD card with help of QEMU". With links: https://unix.stackexchange.com/questions/41889/how-can-i-chroot-into-a-filesystem-with-a-different-architechture https://gist.github.com/gokart23/8ade2d431ead2de47340160301837cab Execute command sudo apt dist-upgrade using chroot into the rootfs folder - main idea of the suggested solution, but i couldn't get how to do that.

  3. I am going to owerwrite boot folder by boot folder from sd card without corruption and try to boot it.Is it going to work?Or maybe i should overwrie multiple folders?[Picture one "inside" in the begining shows this file structure] And thats all.

  4. Could you explain me please how to solve "Error:Structure need cleaning" and access my files, or how to execute command sudo apt dist-upgrade using chroot into the rootfs folder?Or maybe it is possible to solvethis problem other way?

guiverc avatar
cn flag
You've provided no OS/release details, mentioning only Linux which is supported at SE *Unix & Linux*, so why ask here? I see nothing yet on-topic with provided details.
5 5 avatar
ci flag
5 5
Just Linux edited to linux ARM64 is question correct now?
5 5 avatar
ci flag
5 5
Sorry i did a mistake.Edited.
guiverc avatar
cn flag
[Ubuntu 18.04 LTS has reached the end of it's *standard* support life](https://fridge.ubuntu.com/2023/05/13/extended-security-maintenance-for-ubuntu-18-04-bionic-beaver-begins-31-may-2023/) thus is now off-topic here unless your question is specific to helping you move to a supported release of Ubuntu. Ubuntu 18.04 ESM support is available, but not on-topic here, see https://askubuntu.com/help/on-topic See also https://ubuntu.com//blog/18-04-end-of-standard-support
guiverc avatar
cn flag
SE *Unix & Linux* does provide support for *development*, ESM, EOL, EOSS releases like Ubuntu 18.04 LTS as they fall under the *Linux* of SE *Unix & Linux*.
Artur Meinild avatar
vn flag
Just FYI: If you instead do your data forensics on Ubuntu 20.04 or later, your question would be on-topic.
Score:0
ci flag
5 5

I did a mistake.I tried to use clone of my image , located in folder in my pc,instead of sd card with my image.Now i use sd card with image and can extract all my files without any problems.Should i delete this post or shouldnt do anything?

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.