[clug] lsblk
Sam Parkinson
sam at sam.today
Sun Oct 8 20:40:45 UTC 2017
Ah, lsblk is one of the most useful commands hands down. It beats
fumbeling around watching /dev/{sd*,mmcblk*} to find what name your
drive gets.
According to this question [1], the /dev/sd* was to keep things in the
place users expected, rather than renaming them. Interestingly,
/dev/mmcblk*p* seems to be an exception to this rule.
These days, there is also /dev/disk/by-*. That features disks
catogrized by useful things; such as GUIDs or partition labels. So it
is better to use, as it is stable across reboots - things aren't just
named based on the order they are mounted.
[1] https://superuser.com/questions/558156/what-does-dev-sda-for-linux-
mean id="-x-evo-selection-start-marker">
On Mon, 2017-10-09 at 00:24 +1100, Bryan Kilgallin via linux wrote:
> This says that my ancient MS-DOS formatted Flash card is a
> rotational
> disk! Whereas it appears to me rectangular and static.
>
> lsblk -oNAME,LABEL,RM,FSTYPE,TYPE,ROTA,SIZE
>
> NAME LABEL RM FSTYPE TYPE ROTA SIZE
> sr0 1 rom 1 1024M
> sdc 1 disk 1 15.3M
> └─sdc1 FLASH 16 1 vfat part 1 15.3M
>
> --
> members.iinet.net.au/~kilgallin/
>
--
Thanks,
Sam
Check out this narrative tech podcast: https://www.sam.today/podcast/
https://www.sam.today/
More information about the linux
mailing list