I'm looking for a tool that will scan my GUI-less server and create an easy to digest rough overview of all the block devices and their relationship (disk partitions, mdadm devices, LVM PVs & LVs etc) in some rich visual format (html, pdf, svg, png...).
Here's a simple example visualization:
+--------+---------------------+ +-------------------+
| sda1 | | | sdc1 |
+--------+---------------------+ +-------------------+
+ + +
+--------+---------------------+ +-------------------+
| sdb1 | | | sdd1 |
+--------+---------------------+ +-------------------+
| | |
v v v
+---+---+ +---------+----------+ +--------+----------+
| md0 | | md1 | | md2 |
+-------+ +---------+----------+ +--------+----------+
| /boot | \ /
ext4 \ /
\ /
+
|
v
+------------------------------------------+
| vgmain |
+------+-----------------+-----------------+
|/root | /home | /var |
ext4 btrfs ext4
I don't need detail (I can get that from the CLI tools like lsbls
, fdisk
, mdadm
, pvdisplay
, lvdisplay
, df
)
Your best friend here is a simple
lsblk
command. It will give you an output similar to that:For more information, feel free to read its excellent man page
Perhaps you've already used it, but the
du
command can be used with the--max-depth=1
parameter to understand how the used space is distribuited in the file system tree, for example:In this way you can visually recognize where most of the data are, change into that directory and recursively reuse the
du
command to find where you can free some data.