0

I am using a 16GB Micro SD Card on which Raspbian is running. Basically everything is working, however the sd card is acting strange. Whenever I change something or add a new file and reboot the raspberry after, the change is undone. I experienced the same behaviour while using the sd card on my windows. I can create a new file (or change an existing one). After saving the changes and reopening the file, they are still there. But when I unplug the sd card and plug it back in, all the changes are undone again.

Can anyone explain this behaviour to me?

  • Are you using a microSD to SD adapter? Some have a write protect switch on it, have you accidentally turned it on? – Kong Chun Ho Jun 11 '16 at 2:31
  • already checked that and its not the problem – MegaAdragon Jun 11 '16 at 9:05
  • The MS Windows issue is not totally surprising as it does not natively support the filesystem used on the primary Raspbian partition. Are you removing the card after you properly shutdown the system and unplug the power? – goldilocks Jun 13 '16 at 12:29
1

this appears to be SD-card failure by old age.

i have several cards here that behave exactly that way after being bombarded with enormous amounts of writes for several weeks.

my suggestion: backup. copy your card onto a new one (with dd) and use that instead.

edit: As for a detailed explanation of the "why":

everything has a limited life-cycle. with flash memory, this is most commonly limited by the write-count. in short, at one day the cells simply are not able to permanently store new information - but as long as it is connected to power, the written bytes are stored somewhere and it appears as if the write operation was successful. as soon as power goes, there goes the temporary memory.

this write-failure can not be prevented, but pushed back, by using large cards, high quality cards, appropriate file systems and most of all: minimising write operations to the card.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.