Recently, my Pi 3 broke, and I had some important files on its Raspbian Stretch SD card. I would like to get these files off the SD card without buying a whole new Pi.
Does anyone know a way of doing this?
Thanks!
Raspberry Pi Stack Exchange is a question and answer site for users and developers of hardware and software for Raspberry Pi. It only takes a minute to sign up.
Sign up to join this communityTo view files from your EXT4
partition you'll need to download FUSE for macOS. This solution only lets you read, not write, but this should be enough to recover your files.
brew cask install osxfuse
brew install ext4fuse
Create a directory where you want to mount the EXT4
partition. I'll just call it mnt
. Navigate to the directory containing mnt
and type (including the quotation marks)
sudo ext4fuse "/dev/disk2s2" "mnt/" -o allow_other
In my case, the micro SD card is under /dev/disk2
and the EXT4
partition corresponds to disk2s2
. To make sure which is your partition, type diskutil list
.
Then you can cd
into mnt/
and recover your files, for example by issuing the dd
command and saving a copy on your Mac. Let me know if this works, and if you're facing any issues related to FUSE
.
To unmount the partition
sudo umount mnt
References
osxfuse has been succeeded by macfuse as of version 4.0.0
and ext4fuse has been disabled because it requires closed-source macFUSE
macOS
can't (actually won't) show Linux ext4
partitions. There used to be 3rd party software to mount these, but Apple are making it more difficult with each new release, and AFAIK it is not possible with SIP.
You can see the contents on any Linux OS - this can be a virtual machine, a bootable image or another Pi.
I find a Pi with a fresh Raspbian installation and SD Card reader the easiest.
One way is to boot a live Linux CD on your Mac.
I do not have a Mac so can't vouch for the following instructions.
https://www.howtogeek.com/213396/how-to-boot-a-linux-live-usb-drive-on-your-mac/
Once Linux is booted it will be able to see the file systems on the SD card (FAT for the boot partition, and ext4 for the rest).
ls /dev
can you see new device here? I am not sure about names on Mac but on linux SD card ismmcblkxxx