Skip to main content
cPanel Technical Support has been heavily impacted by hurricane Beryl and our ability to respond to tickets has been hindered as a result. We appreciate your understanding and patience as we address these delays.

How to tell if SSD or HDD on a VM?



  • kernow
    I can only think of a speed test, run the below commands, the answer should appear really quickly like < 2seconds if drives are SSD if not around 10 sec.
    time for i in `seq 1 1000`; do > dd bs=4k if=/dev/sda count=1 skip=$(( $RANDOM * 128 )) >/dev/null 2>&1; > done
  • 24x7server
    Hi, May I know what virtualization technology your VM is on?
  • cPanelMichael
    Hello, You may find more user-feedback to this type of question on a website such as StackOverflow. For instance, here's a link you may find helpful: How to know if a disk is an SSD or an HDD Thank you.
    Alternative way to determine if drive is SSD or HDD smartctl is the traditional disk health tool for all system administrators used to check disk health issues, but it can also help to retrieve the disk vendor details. Let"s run smartctl to get the type of HDD that you have: smartctl -a /dev/sda Expected ouput: root@localhost ~]# smartctl -a /dev/sda smartctl 6.4 2015-06-04 r4109 [x86_64-linux-4.4.7-300.fc23.x86_64] (local build) Copyright (C) 2002-15, Bruce Allen, Christian Franke, === START OF INFORMATION SECTION === Model Family: SanDisk based SSDs Device Model: SanDisk SDSSDP128G Serial Number: 130773402659 LU WWN Device Id: 5 001b44 97e48c023 Firmware Version: 2.0.0 User Capacity: 128.035.676.160 bytes [128 GB] Sector Size: 512 bytes logical/physical Rotation Rate: Solid State Device If you see this line "Rotation Rate: Solid State Device" then you haven an Solid State Drive. If smartctl command is not found, try installing it using this command: yum install smartmontools -y
  • Nirjonadda
    We have not working any command. Please do you have any Alternative steps?
    [root@na ~]# cat /sys/block/sda/queue/rotational cat: /sys/block/sda/queue/rotational: No such file or directory [root@na ~]# smartctl -a /dev/sda smartctl 7.0 2018-12-30 r4883 [x86_64-linux-3.10.0-1127.el7.x86_64] (local build) Copyright (C) 2002-18, Bruce Allen, Christian Franke, Smartctl open device: /dev/sda failed: No such device [root@na ~]#
  • dalem
    The above commands need to be ran on the node the best way would be to run this command first you need to find your drive emulator df -h & replace XXX with yours IE xvda, vda, sda, etc time for i in `seq 1 1000`; do dd bs=4k if=/dev/XXX count=1 skip=$(( $RANDOM * 128 )) >/dev/null 2>&1 ;done if its a SSD it will complete in about a second if its a SATA 7200 or even a 15k SAS it will take about 10 seconds caveat: if the the SSD is severely overloaded you may get a slow down either way time to move if that's not what you paid for

Please sign in to leave a comment.