I need to get all the hardisk connected to my PC like,
/dev/sda
/dev/sdb
/dev/sdc
later I have to use it in script and monitor using iostat
I alrady found fdisk
command, it seems to be hard for me to extract all the device from the output of fdisk
using grep
.
Is there any simple way ?
Best Answer
easier than fdisk for your purpose is lsblk:
or if you just want the drives: