helloSystem / ISO

helloSystem Live and installation ISO
https://github.com/helloSystem/
BSD 3-Clause "New" or "Revised" License
805 stars 58 forks source link

SD card reader crashes system when empty or unmountable card is inserted #368

Open TriVoxel opened 2 years ago

TriVoxel commented 2 years ago

I was drafting a multi-paragraph tutorial for you on how to better utilize the Raspberry Pi 4 when my whole system went down due to me plugging in an SD card… 🤬😂

Jokes and jaded emotions aside, if you insert an empty “micro SD to SD” card adapter into the SD card reader, the whole system crashes and it will boot loop until you remove it. I suspect this also applies to SD cards that aren’t empty but have an issue with mounting. This is what happened to me. I plugged it in to view some config files to reference in my tutorial and “WAM!” Whole thing crashed and it started boot looping.

This is a completely reproducible error as well. I am on a Hewlett Packard laptop with a built-in SD card module.

probonopd commented 2 years ago

I can reproduce this issue.

Attaching Transcend TS-RDF5K USB 3.1 SDHC/SDXC/microSDHC/SDXC Card Reader without an cards inserted will crash the system entirely, requring a full reboot.

Same if I unmount a card and then pull the card out of the reader instead of pulling the reader out of the USB port.

image

Next steps:

Possibly related to https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=129311?

TriVoxel commented 2 years ago

I think it's an issue with whatever you are using to automatically mount volumes. It seems that if it detects a storage device, it tries to mount it regardless of whether it is capable of being mounted.

probonopd commented 2 years ago

I think it's an issue with whatever you are using to automatically mount volumes.

That'd be https://github.com/vermaden/automount. But even if it tried to mount, I don't think the whole system should come to a crashing halt.

By the way, it only seems to happen sometimes...

probonopd commented 1 year ago

Looks like this has been resolved in 2023Q1 packages, as found on helloSystem 0.8.0. Can you confirm @TriVoxel?

probonopd commented 11 months ago

Added https://github.com/helloSystem/ISO/commit/b9a2d0d2ba62fb38d27df32291977c06900c0ea7.

Please retest in build 0I41 or later.

If it is still crashing, please let me know