SD's, fsck, dmesg, freezing, and the Corrupt FAT-fs

Login or Register to Reply

Thread Tools Search this Thread
# 1  
Error SD's, fsck, dmesg, freezing, and the Corrupt FAT-fs

Up until today I haven't had a problem using an SD card with Fedora ( 25 ) but when I went to insert the SD adapter with the micro-sd card this time, the computer froze. It has frozen every time since. It is still reading the card, and after a minute or two of losing control of the GUI and terminal it mounts and I can access the files within the card. It used to mount the card with grace and ease and even performed the kindness of letting me know that the card was mounted successfully at the top of the screen. So what caused this? I don't know. It began today and today I:

sudo dnf upgrade

And from there I just modified a couple .brs files and ran them so I could go bug-hunting, and, on a side-note, enabled RPM-fusion on my system.

I don't know why any of those would cause the SD card to be read or mounted any differently, so I decided to call dmesg after inserting the card to see what I could find out.

"FAT-fs (mmcblk0p1) Volume was not properly unmounted. Some data may be corrupt. Please run fsck.". Oh so that's the problem. Well problem one led to problem two and three as when I tried to run fsck or e2fsck I got a rather cryptic warning.

/dev/mapper/fedora-root, /dev/sda1, /dev/mapper/fedora-home is mounted
WARNING!!! The filesystem is mounted. If you continue you ***WILL*** cause ***SEVERE*** filesystem damage.

Well I don't want that, abort... abort!!! When trying to unmount these filesystems so that I could run fsck and see if I could fix the corrupt filesystem I would either get:

umount: /home: ( or /root: ) umount failed: Operation not permitted ( or the target is busy )

and /dev/sda1 flat out doesn't show up.

I'm at a loss. Can anyone explain to me how I would go about fixing the sd card and preventing the temporary full system lock-up? It would be preferred if I didn't have to perform cmd gymnastics or unmount everything on the system to do so, but if it's necessary then I'll do what I must.

Last edited by Beta_OmegaAdinf; 02-20-2017 at 03:18 PM.. Reason: Title missing comma.
# 2  

As a first step, what do you see in the output of df and mount, when run as 'root' or via 'sudo' ? Do you see the SD card device (which I'm guessing from the messages given earlier is going to be something like /dev/mmcblk0p1) ?

As a next step, if you don't see any traces of the SD card device being mounted, and you're sure that it isn't to the best of your knowldge, what happens when you try an fsck /dev/mmcblk0p1 as 'root' ?
# 3  


/dev/mmcblk0p1 on /run/media/USER/UNTITLED type vfat (rw,nosuid,nodev,relatime,uid=1000,gid=1000,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,showexec,utf8,flush,errors=remount-ro,uhelper=udisks2)

/dev/mmcblk0p1           15629312      352  15628960   1% /run/media/USER/UNTITLED/

So the problem is that it is freezing everything while it trys to mount which seems to take a while. Like I said, it successfully mounts but only after consuming 1-2 minutes of time, during which the GUI and Terminal are completely inaccessible. That's annoying and it has not done that before, so it's not so much "How do I fix the SD" though that is useful/helpful but more "What happened to cause the change in performance?"
# 4  

It could still be filesystem corruption that's the issue, and so that might be an avenue that's still worth exploring. As root or via sudo can you umount /run/media/USER/UNTITLED (first ensuring you're not in that directory in any shell session, and don't have any file manager windows open showing the card contents), and then try the fsck /dev/mmcblk0p1 command as root or via sudo ? Note that as always fsck could potentially cause data loss as well as fixing issues, so ideally you'd want to have a backup of the card contents (if possible) before beginning.
This User Gave Thanks to drysdalk For This Post:
# 5  

Sorry I forgot to mention that I already followed the steps above. When I ran fsck /dev/mmcblk0p1 It worked and supposedly fixed my SD card, removing 11 dirty bits, but when I unmounted and put it back in, again, the entire screen froze. Mouse functionality? Gone. Keyboard functionality? No sir, I'm afraid that went out the window too. The only thing that seems to work while it's trying to mount is the power button.
Running dmesg the corrupt file system error/warning no longer shows up. Could it be a result of the update or enabling rpm-fusion?

EDIT: Thank you for suggesting a back up. I cp'd * from the card onto the computer before running fsck, after running fsck -p, removing dirty bits, and waiting for the card to load, I saw that file3.brs was missing. Thank god it was saved to the computer.

---------- Post updated at 06:44 PM ---------- Previous update was at 06:00 PM ----------


mmc0: card never left busy state
mmc0: error -110 whilst initializing MMC card
mmc0:: error -110 whilst initializing SD card

Someone on StackOverflow is having a similar problem on Ubuntu which of course they very nicely reported and closed ( Seems to happen to all StackOverflow questions ) Turns out it was a bug in the kernel that was causing the SD card to freeze the computer/Not read/mount right the first time. I'm going to see if anyone has reported such a bug for fedora yet.

Last edited by Beta_OmegaAdinf; 02-20-2017 at 06:11 PM.. Reason: Courtesy reasons.
Login or Register to Reply

Thread Tools Search this Thread
Search this Thread:
Advanced Search

More UNIX and Linux Forum Topics You Might Find Helpful
unable to repair the / filesystem. Run fsck manually (fsck -F ufs /dev/rdsk/c1t0d0s0)
What can I fix this issue? I have ran below commands but everything is same.:confused: WARNING: Last shutdown is later than time on time-of-day chip: check date. The / file system (/dev/rdsk/c1t0d0s0) is being checked WARNING - unable to repair the / filesystem. Run fsck manually (fsck -F...... Solaris
Thousands of "unattached inode" entries freezing fsck
We have some CentOS systems with ext3 filesystems that (on occasion) experiences long power failures that are longer than the UPS can handle. We run an fsck on the file systems at every boot, and sometimes they will come back on after a power failure, and when fsck runs there are tens of thousands...... UNIX for Advanced & Expert Users
UNIX for Advanced & Expert Users
/usr corrupt, can get to fsck (solaris)
I have a solaris 5.8 system, it wont boot because /usr is corrupt, which means i cannot bring up fsck to run a disk check. Any ideas?... UNIX for Advanced & Expert Users
UNIX for Advanced & Expert Users
CDE freezing
I am running Solaris 8 intel and recently my Common Desktop environment will not load. I enter the root username and password at the prompt, it switches to the CDE screen and the freezes. The OpenWindows environment works fine. I tried with a regular username (not root) and I get the same resutls....... UNIX for Dummies Questions & Answers
UNIX for Dummies Questions & Answers