Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 21 Mar 2016 21:47:39 -0600
From:      Warner Losh <imp@bsdimp.com>
To:        bob prohaska <fbsd@www.zefox.net>
Cc:        Ian Lepore <ian@freebsd.org>, freebsd-arm@freebsd.org
Subject:   Re: Effect of partitioning on wear-leveling
Message-ID:  <E985EBE6-E062-4C5E-8F85-ECB7BDE98DE8@bsdimp.com>
In-Reply-To: <20160322032832.GC83908@www.zefox.net>
References:  <20160321175952.GA83908@www.zefox.net> <1458586884.68920.96.camel@freebsd.org> <20160321221153.GB83908@www.zefox.net> <1458600070.68920.107.camel@freebsd.org> <20160322032832.GC83908@www.zefox.net>

next in thread | previous in thread | raw e-mail | index | archive | help

--Apple-Mail=_8C9DC301-4A05-4F2E-A703-6D525CB13CFC
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain;
	charset=utf-8


> On Mar 21, 2016, at 9:28 PM, bob prohaska <fbsd@www.zefox.net> wrote:
>=20
> On Mon, Mar 21, 2016 at 04:41:10PM -0600, Ian Lepore wrote:
>>=20
>> Also, it's been my experience that it's impossible to "wear out" an
>> sdcard.  I once ran a program that just wrote random data =
continuously
>> at full speed to a 512MB card for several months nonstop.  No =
noticible
>> effect on the card.  I actually still use that card today (in one of
>> our older products whose filesystem image only needs about 40MB).
>>=20
>>=20
> Have you ever checked to see how much of the 512 MB capacity remains?
> Seems that quite a lot of decay wouldn't show up if you're using less
> than 10% of the device's capacity.

If you are writing to only 10% of the LBA range, you should have 90% of
the LBA range in addition to the normal reserve. This should mean that =
you=E2=80=99ve
got 10x the normal reserve (since normally the reserve is in the 10% =
range,
give or take). SD cards don=E2=80=99t lose capacity. Then tend to fail =
read-only or read-never
when they reach their end of life.

So let=E2=80=99s do the math. 512MB cards tended to have write speeds of =
maybe 6MB/s.
At 6MB/s, that=E2=80=99s about 518MB/day, or one drive write per day. =
Most SD cards,
when you can find a rating, are good for between 0.3 and 1 drive write =
per day
over their life (some are more durable, granted). 0.3 DWPD would mean =
that we=E2=80=99re
putting wear not he part at 3x the normal rate. Over several month, =
that=E2=80=99s nowhere
near the 3 year design point that most SD cards implement. It=E2=80=99s =
maybe 2 years of
wear tops. If it=E2=80=99s a better card, it isn=E2=80=99t even one year =
worth of writes.

So it isn=E2=80=99t too surprising that Ian=E2=80=99s experience =
wasn=E2=80=99t so horrible. I ran a similar
experiments and failed to wear things out. It wasn=E2=80=99t until I =
worked at a NAND
card maker that I ever wore out NAND. And to do that I had to wear out =
some
tiny percentage of the drive by artificially limiting the range of NAND =
used to
a range of erase blocks (usually around 50 or maybe 10 GB of space) and =
writing
at full speed (something in the neighborhood of 1GB/s) would give maybe
50 P/E cycles an hour (due to swell limitations), leading to wear out =
over a long
weekend=E2=80=A6 And that=E2=80=99s using ~1% of the capacity of the =
drive at a time.

Warner

--Apple-Mail=_8C9DC301-4A05-4F2E-A703-6D525CB13CFC
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename=signature.asc
Content-Type: application/pgp-signature;
	name=signature.asc
Content-Description: Message signed with OpenPGP using GPGMail

-----BEGIN PGP SIGNATURE-----
Comment: GPGTools - https://gpgtools.org

iQIcBAEBCgAGBQJW8MBcAAoJEGwc0Sh9sBEAJWkP/R/Jf+tROSgcTlhhJC2Z4S5W
zi0knjml1KFchPzEpxkAwvmmBVrNLewbDgAYYO9UZtzw4b+wAtLBG/Hj/AB1V/tR
RcCtvsm8ovTjpJQxzDEZ7UvGW1oecjMwjYHkrW11JbkGmuMsrH03KyxYv+E7YLc/
hdEFjNA9+jFy52lTIsu2r37/CXshyzt1BLIJS1enyGXq7ByV1e7XJ/E23AaXXoNe
3y4FRqddZIHE9vK8wp2HPEksCk9BGqtaqThtSWB0VuOK0gsxiP+kgS+ARrwHBv90
KjZReSTtScQlDFg0jNj2V2LV/cjL6QGITSUsO3fAiPHrfkQErrfdNVx91WHAF1EK
lKRa59MGyxcA4zYPtvJ3be+z7O6DCVDZ8e4dYgkqPDPma3YucotSzHaX+XczomAa
76WiBB4oRRifmlqMjdSjKd+NCNQx3z/dyzjSlwISv9JHHcX14SMNFDX2OlWCd9WH
dJvO8qXlGWC3bFBYjfISlvNKuTKLkl3CktKPQDb4PVknZG3VVzTLrJa4gXoizkQo
vAcAEBcYjY3DUdAA5nkfdVe4nJV0tJUiEiwt7iRAisy5wuCwhDh4/TXSVebwFss0
c605dUMFHXNciCzGG9mBf0wTR7QFDgWwzkxCA3cgJHVy32epHRmacNW/iLXrjLDm
XTEfRIa8Fs3pS0vPoYCc
=k5q9
-----END PGP SIGNATURE-----

--Apple-Mail=_8C9DC301-4A05-4F2E-A703-6D525CB13CFC--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E985EBE6-E062-4C5E-8F85-ECB7BDE98DE8>