You can detect the disk type from the following file:
/sys/block/sda/queue/rotational
Just cat it. 1 means it's rotational, 0 means it is an SSD. Just change sda to be the disk you want to inspect. You will also need root privileges to view the file.
You can detect the disk type from the following file:
/sys/block/ sda/queue/ rotational
Just cat it. 1 means it's rotational, 0 means it is an SSD. Just change sda to be the disk you want to inspect. You will also need root privileges to view the file.