1,330
edits
Line 157: | Line 157: | ||
# inacceptable: e.g. Sandisk Ultra Fit become hot, degrade fast and are unreliable. For cheap sticks to be useful, one must be lucky. | # inacceptable: e.g. Sandisk Ultra Fit become hot, degrade fast and are unreliable. For cheap sticks to be useful, one must be lucky. | ||
=== fill empty space of | === fill empty space of a partition with “zeroes” === | ||
This could be done after deleting large amounts of data from the USB stick, and before saving and compressing an image of it, or before re-using the media with a fresh install. | This could be done after deleting large amounts of data from the USB stick, and before saving and compressing an image of it, or before re-using the media with a fresh install. | ||
USB sticks that support “Deterministic read data after TRIM” according to <code>hdparm</code>, and microSD cards (which always have zeroes in free space after | USB sticks that support “Deterministic read data after TRIM” according to <code>hdparm</code>, and microSD cards (which always have zeroes in free space after <code>fstrim</code> in a SD slot) should be TRIMmed because this does not wear out the storage cells. | ||
Other media: | Other media: as root | ||
dd if=/dev/zero of=/mountpoint_of_partition/delete.me bs=10M # this will stop when filesystem is full | dd if=/dev/zero of=/mountpoint_of_partition/delete.me bs=10M # this will stop when filesystem is full | ||
rm /mountpoint_of_partition/delete.me | rm /mountpoint_of_partition/delete.me | ||
However, this stresses the flash cells; they sustain only a limited number of write cycles. | However, this stresses the flash cells; they sustain only a limited number of write cycles. | ||
=== initializing the media === | === initializing the media === |