stolsvik
Posts: 4
Joined: Sun Oct 13, 2013 12:20 pm

SD Corruption problems with overclocking

Sun Oct 13, 2013 9:46 pm

Hi!

I have Googled way too much now, and I just need someone in the actual know to answer these questions:
  • Have the proper cause of the SD card corruption been found?
  • Is it fixable? Why isn't it fixed?
  • Is there a known good "high overclock", possibly with a certain special SD card, that doesn't corrupt the SD card?
  • How about using a USB stick instead? (Possibly just boot off of the SD card, then do everything off of the USB stick). How's the speed, and how's the stamina of a good USB stick compared to a good SD card - on the Raspberry?
Thanks!

BudgetRacing
Posts: 9
Joined: Sun Sep 29, 2013 1:47 am
Location: Ontario, Canada

Re: SD Corruption problems with overclocking

Mon Oct 14, 2013 2:41 am

I am currently running this on my sd card with the newer raspbian with zero problems with a 7 overvolt. It's an OCZ gold series 16GB card class 6.

1100 - Arm
500 - Core
550 - Ram
350 - GPU

User avatar
hojnikb
Posts: 128
Joined: Mon Jun 04, 2012 3:59 pm
Location: @Home

Re: SD Corruption problems with overclocking

Mon Oct 14, 2013 9:38 am

just don't touch core clock and corruption will be less likely to occour.
Or run from usb stick, as it works just fine and almost no chance of corruption
+°´°+,¸¸,+°´°~ Everyone should have a taste of UK Raspberry Pie =D ~°´°+,¸¸,+°´°+
Rasberry Pi, SoC @ 1225Mhz :o, 256MB Ram @ 550Mhz, 16GB SD-Card, Raspbian

stolsvik
Posts: 4
Joined: Sun Oct 13, 2013 12:20 pm

Re: SD Corruption problems with overclocking

Sun Oct 20, 2013 9:11 pm

Thanks, folks!

But still, is there no confirmed reason for why this occurs? I find this quite hard to believe - over all this time, someone must have found out what, exactly, is causing this. There are too many theories - but no one is certain. Power supply, core clock, what not.

But - given that you have ample, rock solid power - what are the remaining real reasons?
  • Why does it happen?
  • Is it fixable?

hal8000
Posts: 187
Joined: Fri Oct 04, 2013 5:22 pm

Re: SD Corruption problems with overclocking

Tue Oct 22, 2013 8:34 pm

stolsvik wrote:Thanks, folks!

But still, is there no confirmed reason for why this occurs? I find this quite hard to believe - over all this time, someone must have found out what, exactly, is causing this. There are too many theories - but no one is certain. Power supply, core clock, what not.

But - given that you have ample, rock solid power - what are the remaining real reasons?
  • Why does it happen?
  • Is it fixable?


The short answer is overclocking exceeds the manufacturers specification, so the Pi will become unstable.

All components have a manufacturers specification which they are guaranteed to work at.
If you exceed the spec by overclocking or by providing extra voltage then it is working outside of the original
manufacturers limits.
If you take for example a Class 10 SD card, they have a rated speed of 10MB/sec. Many cards will run faster
and you can measure throughput with hdparm command like below:

pi@raspbmc:~$ sudo hdparm -tT /dev/mmcblk0

/dev/mmcblk0:
Timing cached reads: 134 MB in 2.03 seconds = 65.92 MB/sec
Timing buffered disk reads: 68 MB in 3.07 seconds = 22.16 MB/sec

When you overclock the CPU core clock, timings are skewed and there will be a point at which memory can not get onto the CPU bus fast enough, and this will result in an unstable system.

A model B Pi has a default clock of 700Mhz; current consumption is around 700mA.
Overclock the RPi and its likely to consume more current and get hotter as well, yet
another reason for having an adequate power supply.

stolsvik
Posts: 4
Joined: Sun Oct 13, 2013 12:20 pm

Re: SD Corruption problems with overclocking

Tue Oct 29, 2013 9:26 pm

Do you mean that the SD Card reader follows the clock frequency of the Pi or something like that? That would be really weird, in my humble opinion.

Anyone with a more exact explanation?

bsobel
Posts: 5
Joined: Mon Nov 04, 2013 5:47 pm

Re: SD Corruption problems with overclocking

Mon Nov 04, 2013 5:52 pm

The 'the pi is unstable over clocked' is a non-answer. I just saw three open SD card bugs the kernel developers are looking at, one in which a certain type of card isn't readable during boot (seems this is hit often). A fix for this is in the works. A second where some cards where taking much longer to finish a write than expected (2s vs 500ms). A patch for this was in the works. The last (where I did not see a resolution) was one of the developers reproduced a case where some writes would wind up not completing correctly. It is possible that these bugs (along with other recently fixed sd card bugs) are driving a majority of the corruption issues. I'm hopping we can all test and find out once these three are fixed.

https://github.com/raspberrypi/linux/issues/415
https://github.com/raspberrypi/linux/issues/414
https://github.com/raspberrypi/linux/issues/412

dom
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 5341
Joined: Wed Aug 17, 2011 7:41 pm
Location: Cambridge

Re: SD Corruption problems with overclocking

Mon Nov 04, 2013 8:35 pm

We are testing a possible corruption fix. If you've got sdcard corruption problems then have a look at instructions here:
https://github.com/raspberrypi/linux/issues/415

mcgyver83
Posts: 358
Joined: Fri Oct 05, 2012 11:49 am

Re: SD Corruption problems with overclocking

Mon Nov 04, 2013 10:48 pm

Nice.I was looking for a topic like this.
I also have corruption if I change core-freq.
I red about something related to SD driver freq and a couple of params to be set in cmdline.txt.
Are this things interesting or old stuff?

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 23891
Joined: Sat Jul 30, 2011 7:41 pm

Re: SD Corruption problems with overclocking

Tue Nov 05, 2013 9:18 am

mcgyver83 wrote:Nice.I was looking for a topic like this.
I also have corruption if I change core-freq.
I red about something related to SD driver freq and a couple of params to be set in cmdline.txt.
Are this things interesting or old stuff?
The change was posted yesterday....so bleeding edge
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
“I think it’s wrong that only one company makes the game Monopoly.” – Steven Wright

gsh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 1442
Joined: Sat Sep 10, 2011 11:43 am

Re: SD Corruption problems with overclocking

Tue Nov 05, 2013 4:50 pm

https://github.com/raspberrypi/linux/issues/415

Please help test this fix for the SD card corruption, I don't believe it is limited specifically to overclocking (although changing the clocks will change the probability of corruption) but it would be interesting if you still get problems with this fix

Gordon
--
Gordon Hollingworth PhD
Raspberry Pi - Director of Software Engineering

Return to “Advanced users”