Forrest logo
back to the hdparm tool

hdparm:tldr:05db8

hdparm: Test the read speed of a specific device.
$ sudo hdparm -tT ${device}
try on your machine

This command is composed of multiple parts as follows:

  • sudo: This is a command used in Unix-like operating systems that allows a user with administrative privileges to execute a command as the superuser or another user. Using sudo before a command gives it elevated privileges.

  • hdparm: This is a command-line utility in Linux used to get and set various hard disk parameters. It can also be used to measure the performance of a storage device.

  • -tT: These are options or flags that can be appended to the hdparm command. The -t option tests the read speed of the specified storage device, while the -T option tests the caching speed of the device.

  • ${device}: This is a placeholder for the name of the storage device you want to test. You need to replace ${device} with the actual device name, such as /dev/sda or /dev/nvme0n1. The device name is typically found in the /dev directory and represents a specific hard disk or solid-state drive.

When executed, this command with the appropriate device name will measure the read and caching speed of the specified storage device. The result will provide information on the device's performance, allowing you to assess its capabilities or benchmark it against other devices.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the hdparm tool