Forrest logo
tool overview
On this page you find all important commands for the CLI tool hdparm. If the command you are looking for is missing please ask our AI.

hdparm

HDparm is a powerful command-line utility used in various operating systems, including Linux, to interact with and manipulate hard disk and solid-state drives. It provides extensive functionality and control over various features and parameters of storage devices.

  1. HDparm allows users to access information about their drives, such as model number, firmware version, and serial number, by simply running the command with the drive as an argument.

  2. It enables users to analyze the performance of their drives, including reading and writing speeds, disk latency, and cache size, by conducting benchmark tests.

  3. The tool provides options to set various drive parameters like read/write cache configuration, power management settings, and acoustic management.

  4. With HDparm, users can enable or disable Advanced Power Management (APM) feature to regulate power usage and prolong drive lifespan.

  5. The tool facilitates the Secure Erase command, which securely wipes all data from the drive, making it unrecoverableā€”a useful feature when reusing or selling drives.

  6. It allows users to adjust the Automatic Acoustic Management (AAM) setting, which controls the noise levels of the drive by modifying seek speeds.

  7. HDparm supports setting the Advanced Host Controller Interface (AHCI) mode, which can improve performance on certain systems.

  8. It enables users to turn on the Direct Memory Access (DMA) mode for faster data transfer rates or revert to the older Programmed Input/Output (PIO) mode.

  9. The tool allows setting the Advanced Technology Attachment (ATA) features like 48-bit addressing, which allows larger hard drives to be recognized by the system.

  10. HDparm is highly flexible and customizable, as it provides numerous command-line options and parameters to fine-tune drive settings and optimize performance to suit individual needs.

List of commands for hdparm:

  • hdparm:tldr:05db8 hdparm: Test the read speed of a specific device.
    $ sudo hdparm -tT ${device}
    try on your machine
    explain this command
  • hdparm:tldr:12384 hdparm: Get the Advanced Power Management level.
    $ sudo hdparm -B /dev/${device}
    try on your machine
    explain this command
  • hdparm:tldr:2c1a4 hdparm: Display the device's current power mode status.
    $ sudo hdparm -C /dev/${device}
    try on your machine
    explain this command
  • hdparm:tldr:79640 hdparm: Put the drive into idle (low-power) mode, also setting its standby timeout.
    $ sudo hdparm -S ${standby_timeout} ${device}
    try on your machine
    explain this command
  • hdparm:tldr:de3d9 hdparm: Request the identification info of a given device.
    $ sudo hdparm -I /dev/${device}
    try on your machine
    explain this command
  • hdparm:tldr:f5cf4 hdparm: Set the Advanced Power Management value (values 1-127 permit spin-down, and values 128-254 do not).
    $ sudo hdparm -B ${1} /dev/${device}
    try on your machine
    explain this command
tool overview