Troubleshooting APST Issues in Ubuntu 22.04: A Guide to Fixing NVMe SSD Wake-Up Errors
The NVMe Autonomous Power State Transition (APST) feature: What it is and How to Troubleshoot it in Ubuntu 22.04
Have you ever come across an error message stating that your NVMe SSD has failed to wake up within the specified time when using the APST feature? If yes, then you have encountered a phenomenon related to the NVMe Autonomous Power State Transition (APST) feature. In this blog, we will explain what APST is and how you can troubleshoot it in Ubuntu 22.04.
What is APST?
APST (Autonomous Power State Transition) is a feature in NVMe (Non-Volatile Memory Express) SSDs that allows the NVMe controller to switch between different power management states automatically. The NVMe controller provides information on how much time it requires to enter and exit each power-saving state, and the operating system uses this information to configure the state transition rules.
APST can help improve the power efficiency of NVMe SSDs by allowing them to enter low-power states when idle. The operating system can then wake the NVMe SSD from these low-power states when necessary.
Troubleshooting APST in Ubuntu 22.04
If your NVMe SSD is failing to wake up within the specified time when using APST, then the first step is to disable APST and see if the issue persists. To disable APST in Ubuntu 22.04, you can add the following line to your boot configuration file:
“nvme_core.default_ps_max_latency_us=0
“
This line tells the maximum allowed time for waking up from APST power management states is 0 microseconds, which disables the APST feature. You can add this line to your boot configuration file by using the following command:
sudo nano /etc/default/grub
Once you have added the line, save the file and run the following command to update the boot configuration:
sudo update-grub
After disabling APST, you can restart your computer and see if the issue persists. If the issue does not persist after disabling APST, then the problem is likely related to the APST feature.
If the issue persists even after disabling APST, then you may need to check for any NVMe SSD firmware updates. The manufacturer of your NVMe SSD should be able to provide information on available firmware updates. Updating the firmware may resolve the issue.
On some WD NVMe a workaround could be to set the latency state to 5500
nvme_core.default_ps_max_latency_us=5500
Conclusion:
The NVMe Autonomous Power State Transition (APST) feature can help improve the power efficiency of NVMe SSDs by allowing them to enter low-power states when idle. If you encounter issues with APST, you can disable the feature by adding a line to your boot configuration file, and if the issue persists, check for any available firmware updates. By following these steps, you can troubleshoot APST issues in Ubuntu 22.04.