Options available in `blkid` Command in Linux
Here is a list of some common options for the blkid command:
option |
long option |
description |
---|---|---|
-d |
–no-encoding |
Don’t encode non-printing characters. |
-g |
–garbage-collect |
Remove devices that no longer exist. |
-h |
–help |
Display a usage message and exit. |
-k |
–list-filesystems |
List all known filesystems and RAIDs and exit. |
-o |
–output FORMAT |
Use the specified output format. FORMAT can be:
and so on. |
-t |
–match-token NAME=VALUE |
Search for block devices having attributes named NAME and value as VALUE. NAME can be TYPE, LABEL or UUID. |
-U |
–uuid [UUID] |
Look up the device that uses this filesystem UUID. |
For more options and details for the command check out the manual for the blkid command:
man blkid
blkid Command Examples in Linux
blkid is a command to locate or print block device attributes. A block device can be a hard drive, solid-state drive (SSD), or removable storage device, such as a USB drive. It can determine the type of content (e.g., filesystem or swap) that a block device holds, and also the attributes (tokens, NAME=value pairs) from the content metadata (e.g., LABEL or UUID fields). The blkid command is part of the util-linux package. You need a Linux terminal to use this command.