davehiggins2170
Posts: 6
Joined: Fri May 13, 2016 5:22 pm

index.html edits disappear after a reboot

Fri May 13, 2016 5:49 pm

I've recently installed Raspbian (Jessie) on a Pi B+ and installed Apache and PHP and copied some HTML and PHP code from a Dalek project from the forum. I changed /var/www/ to be owned by pi and successfully edited index.html to change various bits including a link to a gif file which I copied into /var/www/html and it all worked. I then changed some of the .php files that the html used and got them working.

After a reboot all my changes to index.html and the .php files had disappeared and the gif had gone as well and the permission had reverted to root. It looks like the whole folder had been copied back from somewhere.

I've done this sort of thing before without problem - has something changed recently or is there a setting somewhere that I've missed?

Thanks for any help Dave

User avatar
B.Goode
Posts: 10356
Joined: Mon Sep 01, 2014 4:03 pm
Location: UK

Re: index.html edits disappear after a reboot

Fri May 13, 2016 6:03 pm

Sounds very similar to this thread, in which I commented:

viewtopic.php?f=28&t=145965&hilit=impossible

davehiggins2170
Posts: 6
Joined: Fri May 13, 2016 5:22 pm

Re: index.html edits disappear after a reboot

Sat May 14, 2016 6:15 pm

Hi thanks for that - looks like that is the problem. I can't now write to the SD card even using SDformatter or the HD Raw Copy tool that I use for making backups. It's only got about 3.6Gb on an 8Gb card. I don't know where it came from as it and the Pi were presents but looks like I'm going to have to find some new cards, I've got loads of cards suitable for my original B but only this one micro card.

Cheers Dave :D

davehiggins2170
Posts: 6
Joined: Fri May 13, 2016 5:22 pm

Re: index.html edits disappear after a reboot

Fri May 27, 2016 6:42 pm

I've now copied the failing card to a new one and it is working fine. The old card is going in the in once I'm sure I've got everything off it.

stderr
Posts: 2178
Joined: Sat Dec 01, 2012 11:29 pm

Re: index.html edits disappear after a reboot

Fri May 27, 2016 6:55 pm

davehiggins2170 wrote:Hi thanks for that - looks like that is the problem. I can't now write to the SD card even using SDformatter or the HD Raw Copy tool that I use for making backups.
I wonder if some of the sdcards lock you out of writing to the materials that were there but still present them read only and allow writes to some other part of the flash drive that then aren't made available on reboot. People have said that some drive fail to read only to protect the data, but it seems more than just not letting you write because it seems like you actually could write and it was all there until you rebooted. It would be interesting if someone did a more detailed examination of one of these failing cards to see. I have a 4gig card that would not work correctly, everything was fine when I plugged in a crappy 8gig Amazon special, but it didn't fail in the way you described, I could read and write from it, it just locked up the machine. So there are different failure modes and different ways different cards handle failure.

Return to “Troubleshooting”