Assuming you actually want to see physical devices, and not just all block devices:
My recommendation will then be:
lsblk -a -d -e 230
Let us review what these command line options do, from the man page:
Also list empty devices. (By default they are skipped.)
lsblk shows my laptop's DVD burner even when it is empty, without
-a. But it doesn't seem to hurt anything to leave it present.
Do not print holder devices or slaves. For example, lsblk
--nodeps /dev/sda prints information about the sda device only.
This means we don't see partitions on a device, just the device itself.
-e, --exclude list
Exclude the devices specified by the comma-separated list of
major device numbers. Note that RAM disks (major=1) are
excluded by default. The filter is applied to the top-level
Finally, I use
-e 230 to exclude ZFS zvols, which use this major number. They are entirely logical block devices, but the ZFS driver makes them appear in
lsblk the same as physical disk devices. If you use ZFS, you can exclude zvols from display with
[root@dalaran ~]# lsblk -a -d -e 230
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 0 894.3G 0 disk
sr0 11:0 1 1024M 0 rom
nvme0n1 259:0 0 477G 0 disk
I do not recommend using
-S option, as this will cause NVMe devices to not be displayed.
There are several other options in the
lsblk man page which allow for making the output more machine readable, in case you want to write a shell script. For instance