1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-29 23:24:55 +02:00
tldr/pages/linux/lsblk.md

37 lines
790 B
Markdown
Raw Normal View History

2016-01-05 20:41:55 +05:30
# lsblk
2016-01-13 12:04:46 +01:00
> Lists information about devices.
> More information: <https://manned.org/lsblk>.
2016-01-05 20:41:55 +05:30
2016-01-13 12:04:46 +01:00
- List all storage devices in a tree-like format:
2016-01-05 20:41:55 +05:30
`lsblk`
2016-01-13 12:04:46 +01:00
- Also list empty devices:
2016-01-05 20:41:55 +05:30
2025-03-12 21:05:58 +02:00
`lsblk {{[-a|--all]}}`
2016-01-05 20:41:55 +05:30
2016-01-13 12:04:46 +01:00
- Print the SIZE column in bytes rather than in a human-readable format:
2016-01-05 20:41:55 +05:30
2025-03-12 21:05:58 +02:00
`lsblk {{[-b|--bytes]}}`
2016-01-05 20:41:55 +05:30
2016-01-13 12:04:46 +01:00
- Output info about filesystems:
2016-01-05 20:41:55 +05:30
2025-03-12 21:05:58 +02:00
`lsblk {{[-f|--fs]}}`
2016-01-05 20:41:55 +05:30
2016-01-13 12:04:46 +01:00
- Use ASCII characters for tree formatting:
2016-01-05 20:41:55 +05:30
2025-03-12 21:05:58 +02:00
`lsblk {{[-i|--ascii]}}`
2016-01-05 20:41:55 +05:30
2016-01-13 12:04:46 +01:00
- Output info about block-device topology:
2016-01-05 20:41:55 +05:30
2025-03-12 21:05:58 +02:00
`lsblk {{[-t|--topology]}}`
- Exclude the devices specified by the comma-separated list of major device numbers:
2025-03-12 21:05:58 +02:00
`lsblk {{[-e|--exclude]}} {{1,7,...}}`
- Display a customized summary using a comma-separated list of columns:
2025-03-12 21:05:58 +02:00
`lsblk {{[-o|--output]}} {{NAME,SERIAL,MODEL,TRAN,TYPE,SIZE,FSTYPE,MOUNTPOINT,...}}`