fbpx blkid Command in Linux: View UUID and Filesystem Type | Certificação Linux

blkid Command in Linux: View UUID and Filesystem Type of Disks

📅 12/06/2021 ⏱ 1 min ✍️ Uira Ribeiro
Linuxcommands
blkid Command in Linux: View UUID and Filesystem Type of Disks
Exam Pass App — mais de 7.000 questões LPI, offline, em 5 idiomas, disponível no Android e na App Store
Available on
Google Play
Available on
App Store

The blkid command in Linux shows what type of content a block device (disks) contains and its attributes such as device name, and other metadata.

If a device is specified, it will only show information for that particular device. If no parameter is specified, it will show information for all connected block devices.

Example:

# blkid/dev/sda1: UUID="1c3b15b1-cd13-4a73-b2a8-449fa3aa039f" TYPE="xfs" /dev/sda2: UUID="GZXwoc-7Zia-AdE3-ZFwD-SUgd-8hK3-j003qr" TYPE="LVM2_member" /dev/mapper/cl-root: UUID="602fcf7d-d716-4f5b-aa6b-fb34d85a0169" TYPE="xfs" /dev/mapper/cl-swap: UUID="a873901e-5b33-4c78-84f5-e9eeadd9fba3" TYPE="swap" /dev/mapper/cl-home: UUID="fcbdceb1-9053-460b-908c-f7913f91dbe6" TYPE="xfs" 

It also shows information about the disk topology:

$ sudo blkid -i /dev/sda1DEVNAME=/dev/sda1MINIMUM_IO_SIZE=4096PHYSICAL_SECTOR_SIZE=4096LOGICAL_SECTOR_SIZE=512

Learn much more about Linux in our online course. You can enroll here. If you already have an account, or want to create one, just log in or create your user here.

Liked it? Share

Uira Ribeiro

Prof. Uirá Ribeiro

Chair do Board do Linux Professional Institute

After years of watching professionals waste hours on simple tasks because they didn't know the right Linux tools, I decided to teach.
Today I'm the author of most of LPI's official Learning Materials and mentor to over 14,000 certified students.

See my full story →

That was just one piece. The course teaches the whole path — from your first command to exam day.

Certificação Linux — a plataforma líder em certificações Linux no Brasil
WhatsApp