tags:

views:

54

answers:

2

I have an app that downloads a good amount of data to the iPad and a couple thousand images. Just looking into concerns about wearing out the flash disk.

Does checking to see if a file exists wear in the drive as well?

Editing and saving of data using Core Data?

A: 

Checking to see if the file exists does cause wear, but a negligible amount. I wouldn't worry about it. Editing and saving obviously causes more, but flash drive life expectancy is overall not bad.

Kira
I really hope Apple is not doing anything like atime on Linux, were a file access would cause a write to update the access timestamp.
Venza
+1  A: 

NAND flash has a life of about 100K write cycles per block. And each block is usually 128KB or 256KB. I don't know which exact type of NAND flash to iPad is using, but with the 16GB version, a perfect wear levelling algorithm, writing a block every 5 seconds means:

16GB / 128KB = 131072 blocks
131072 blocks * 5 seconds = 655360 seconds to write every block once (7.6 days)
655360 seconds * 100K writes = 2078 years of continuous use.

These numbers are obviously there just to give an idea of the order of magnitude. In reality wear levelling is not a perfect art, writes are not so regular in time and almost always are not of the perfect size to fit in a flash block. Anyway I expect Apple's iOS to be quite smart to managing flash, as it is used only on flash-based devices.

If you know how much data your application writes and how often, you can do similar calculations to have a rough idea of how it goes. I had problems, but with a 128MB flash with 50milliseconds writes.

Venza