Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hello!
Im using slackware current. When update the system around 20 march my sd cards became read only mode. The same card is read write mode on another machine also with slackware but without this update.
Can someone tell me which package may occurs the problem just to downgrade to previous version.
Till now i try these without success:
dosfsck -a /dev/mmcblk0p1
hdparm -r0 /dev/mmcblk0p1
always return: readonly = 1 (on)
its not about permissions because root also cant write on sd cards
in /var/log/messages find this:
from 20 march kernel: mmcblk0: mmc0:59b4 5cMJR 59.7 GiB
and on march 21: kernel: mmcblk0: mmc0:59b4 5cMJR 59.7 GiB (ro)
I don't think it's a package. There's often a setting in /etc/fstab in the option "errors=remount,ro" for sd cards. If the card is going belly-up, this preserves the readable data.
The larger sd cards (≅30mm×20mm) can have little switches to physically set r/w or read only. sd cards don't live long and should not be rewritten frequently.
Sorry guys none of this cause the problem. As i said its not only one card and several cards which suddenly became read only after update. And the same card is working perfectly in read/write mode on another slackware machine which has not updated.
Its totally strange but when i switch to windows 10 pro and then the sd card was read only too, but when i do safety remove it and insert it again suddenly it became writable as it should be. Its very strange because now in slackware is also writable... And all other card became writable.
If someone have the similar problem may try to fix it by this way. I don't know what is happening at the end.
It's not the case. Why in another PC also with slackware the same sd card working in writable mode?
That's an interesting question, but only you have the answer in your hands. Check the obvious stuff like /etc/fstab, & less obvious stuff , (e.g. kernel settings or version, dodgy sdcard socket or usb plug). You're not telling us. Have you inserted the card into both, run 'sudo dmesg |tail -n 20' and compared outputs?
You can read the sdcard, so I'm not too worried if you have to use another PC to do it while you compare settings. Does it work on a liveslak usb?
Last edited by business_kid; 03-27-2024 at 10:39 AM.
That's an interesting question, but only you have the answer in your hands. Check the obvious stuff like /etc/fstab, & less obvious stuff , (e.g. kernel settings or version, dodgy sdcard socket or usb plug). You're not telling us. Have you inserted the card into both, run 'sudo dmesg |tail -n 20' and compared outputs?
You can read the sdcard, so I'm not too worried if you have to use another PC to do it while you compare settings. Does it work on a liveslak usb?
fstab is not the problem
dodgy sdcard socket or usb plug - not the problem now it works on both pc, if the socked/plug is broken will never work until repair.
sudo dmesg |tail -n 20' and compared outputs? - now i cant do that because cards start work as normal on both pc and if the problem with read only mode happen again i will see if there is any difference in logs. As i see only difference before was this "(ro)" from my first post.
kernel settings or version - kernel is the same version
Something happen during insert the card in windows and cant figure it out, but now works in writable mode on both pcs.
Something happen during insert the card in windows and cant figure it out, but now works in writable mode on both pcs.
Great! So now you apply Rule #1 of maintenance
Code:
If it works, don't fix it!
My guess is windows may have done something to the format, especially if it's FAT formatted. Try umounting the disk and running these next time if the problem recurs
fsck.vfat -a /dev/mmcblk0
# Fix the dirty bit and write. Remount.If there's still an issue
sudo mount -o remount,rw /dev/mmcblk0
At least you might get an intelligent error, which is always useful.
Yes i will try. But the most curious thing is that the same cards which now is working perfectly:
1. Work in slackware pc1 in read only mode, and i cant remount in read-write mode because it always says sd card is read-only mode. Cant remove dirty bit because it again says sd card is read-only mode.
2. The same sd cards work in slackware on PC2 in read-write mode without any problems. So if the problem is in the way sd cards are unplugged, dirty bit, file system or something similar... Should they work perfectly on another PC also with slackware? Something missing...
And if the problem start again will try to find out what is the missing peace...
BTW do you have an idea how can i recreate the problem just with one sd card for testing?
probably you have a problem with a reader, not the sd card itself. Or just it wasn't inserted properly. Or something else happened.
Not possible. If the reader was the problem it cant be fixed by itself. Now the same reader and the same CARDS is working as it should - in read-write mode.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.