Article: KB-030

This page shows you how to test SSD Data Retention in your system. When we talk about Data retention, it refers to how long the SSD retains data integrity without power. The table below provides the approximate data retention times at some typical storage temperatures.

The key takeaways are:

  • When installing a new SSD, the data is good for ten years when storage temperature is under 55ºC. If we store a new SSD at 85º data retention on an MLC SSD is around two years, and the data retention on a TLC SSD is around half-a-year.
  • For applications that need to store the SSD without power for an extended period, the data retention is only days or months when the SSD is more than 70% used. One example application is video recording for transportation. Once we remove the SSD from the train and bring it to the station, we want to pay attention to the data retention time and temperature we store the SSD without power. If necessary, transfer the data to the central storage or plug the SSD into a power source before the data retention time expires.

How to Test

Suppose there is a need to characterize data retention yourselves. In that case, we at Virtium strive to make your engineering life a lot less cumbersome. Below are the steps for this test. On the right, we describe how StorKit Software simplifies the test and saves you time.

Software Tools

We provide a few embedded software tools to save you time and make life easier.

  • vtTestCmd to write to and verify data.
  • Python script to automate data retention test.
  • coredelegate-sample is a sample software. We include it here to demonstrate how to use StorKit API and build your software.
  • You can change the Python script to set LBA ranges, add your tool to record temperatures, etc. The possibilities are endless.

If your system is ARM CPU or Embedded Linux (Yocto, OpenWRT), we will compile the software tool for your environment.

Overview of the Operation

Below is an overview of the test operations. All software is a command line so that you can incorporate it with your automation software and scripts. API and source code upon request.

  1. Select a test temperature
  2. StorKit writes a unique data pattern to each LBA
  3. StorKit uses the condition of the drive to estimate retention times
  4. StorKit records test logs in the local directory

Step 1 - Set up the Software

  1. Setup Python on a Linux or Windows system.
  2. Download our or If your OS is Embedded Linux (Yocto, OpenWRT), please contact us. We will compile the tool for your OS.
  3. Copy vtTestCmd, coredelegate-sample, and into the same directory.
  4. chmod +x ./vtTestCmd
  5. chmod +x ./coredelegate-sample
  6. The Python script,, is for you to get started. Modify this script to fit your test environment, or to expand your test.
  7. coredelegate-sample is a fully functional sample software built on top of our StorKit API. It will take minimum coding to create a similar test for your environment.

Step 2 - Start the Test


Enter administrative mode on your terminal

  • sudo -s

Start the test

  • python ./


  • Start a command window or a PowerShell with Administrative privilege
  • python

Embedded Linux (Yocto, OpenWRT) on ARM and Raspberry PI

  • Contact us to provide information about the development environment
  • We compile the tools and can provide tests for embedded Linux.

Step 3 - Expand your test

Below are a few suggestions to expand your test.

  1. Modify the script to write different parts of the SSD at different temperatures.
  2. Simulate your operating environment.
  3. This test does not stop at data retention. We can use the same script and software to test data integrity and ECC characteristics of the SSD.

Doing more with StorKit API

In this test, we build a fully functional application, coredelegate-sample, with a few lines of C++ code, as shown below. You can develop similar tests with minimum effort using our StorKit API. Visit our StorKit page for the API reference and examples.

#include "StorageKitCoreDelegateFactory.h"
#include "StorageKitCoreDelegate.h"

void getDataRetentionEstimateExample (const string &driveName)

SKCDataRetentionInfo info;

// Scan device
SKStorageDevice *storageDevice = SKStorageDeviceUtils::scanDevice (driveName);
SKCCoreDelegate* coreDelegate = SKCCoreDelegateFactory::create (storageDevice);

info = coreDelegate->getPowerOffDataRetentionEstimate ();

delete coreDelegate;
printDataRetention (info);