question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Feature] RAID Support

See original GitHub issue

Is your feature request related to a problem? Please describe. The reported disk usage is simply a sum of all disks on the system, not real storage.

Describe the solution you’d like Storage should monitor a configurable list of volumes, not just block devices.

Additional context For example, I have a test server that has two 240 GB SSDs and two 480GB HDDs. Dashdot reports this as 1.4TB of storage with some tiny sliver as “used.” However, those two HDDs and one of the SSDs are in a ZFS pool together. So the actual state of storage on the server is one 240GB volume with 5% used and one 480GB volume with 33% used.

root@test:~# lsblk
NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0 465.8G  0 disk 
├─sda1   8:1    0 465.8G  0 part 
└─sda9   8:9    0     8M  0 part 
sdb      8:16   0 238.5G  0 disk 
└─sdb1   8:17   0 238.5G  0 part /
sdc      8:32   0 238.5G  0 disk 
├─sdc1   8:33   0 238.5G  0 part 
└─sdc9   8:41   0     8M  0 part 
sdd      8:48   0 465.8G  0 disk 
├─sdd1   8:49   0 465.8G  0 part 
└─sdd9   8:57   0     8M  0 part 

root@test:~# df -h /
Filesystem      Size  Used Avail Use% Mounted on
/dev/sdb1       234G  9.7G  213G   5% /

root@test:~# zpool status
  pool: tank
 state: ONLINE
  scan: scrub repaired 0B in 00:42:24 with 0 errors on Sun May  8 01:06:25 2022
config:

        NAME                                              STATE     READ WRITE CKSUM
        tank                                              ONLINE       0     0     0
          mirror-0                                        ONLINE       0     0     0
            ata-WDC_WD5002ABYS-02B1B0_WD-WCASYA237797     ONLINE       0     0     0
            ata-WDC_WD5003ABYX-01WERA2_WD-WMAYP6798572    ONLINE       0     0     0
        cache
          ata-Samsung_SSD_840_PRO_Series_S12RNEACC87965T  ONLINE       0     0     0

errors: No known data errors

root@test:~# zpool list
NAME   SIZE  ALLOC   FREE  CKPOINT  EXPANDSZ   FRAG    CAP  DEDUP    HEALTH  ALTROOT
tank   464G   156G   308G        -         -    17%    33%  1.00x    ONLINE  -

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:1
  • Comments:60 (33 by maintainers)

github_iconTop GitHub Comments

1reaction
MrAlucardDantecommented, Jun 23, 2022

Indeed, ZFS doesn’t set a mount point for the blockDevices.

NAME="loop0" TYPE="loop" SIZE="64925696" FSTYPE="squashfs" MOUNTPOINT="/snap/core20/1494" UUID="" ROTA="0" RO="1" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="loop1" TYPE="loop" SIZE="64933888" FSTYPE="squashfs" MOUNTPOINT="/snap/core20/1518" UUID="" ROTA="0" RO="1" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="loop2" TYPE="loop" SIZE="83832832" FSTYPE="squashfs" MOUNTPOINT="/snap/lxd/22923" UUID="" ROTA="0" RO="1" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="loop3" TYPE="loop" SIZE="46870528" FSTYPE="squashfs" MOUNTPOINT="/snap/snapd/15904" UUID="" ROTA="0" RO="1" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="loop4" TYPE="loop" SIZE="49233920" FSTYPE="squashfs" MOUNTPOINT="/snap/snapd/16010" UUID="" ROTA="0" RO="1" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="sda" TYPE="disk" SIZE="2000398934016" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="1" RO="0" RM="0" TRAN="sata" SERIAL="Z1E5FT5W" LABEL="" MODEL="ST2000DM001-1CH1" OWNER="root"
NAME="sda1" TYPE="part" SIZE="2000389406720" FSTYPE="linux_raid_member" MOUNTPOINT="" UUID="100776c9-bc80-9e31-c6d1-93f8c418c2d1" ROTA="1" RO="0" RM="0" TRAN="" SERIAL="" LABEL="SERVEUR-BB:0" MODEL="" OWNER="root"
NAME="sda9" TYPE="part" SIZE="8388608" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="1" RO="0" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="sdb" TYPE="disk" SIZE="240057409536" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="0" RO="0" RM="0" TRAN="sata" SERIAL="50026B73807757D5" LABEL="" MODEL="KINGSTON SA400S3" OWNER="root"
NAME="sdb1" TYPE="part" SIZE="1048576" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="0" RO="0" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="sdb2" TYPE="part" SIZE="2147483648" FSTYPE="ext4" MOUNTPOINT="/boot" UUID="f4fb588e-039a-40e7-9e7c-be1565cab7ac" ROTA="0" RO="0" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="sdb3" TYPE="part" SIZE="237906165760" FSTYPE="LVM2_member" MOUNTPOINT="" UUID="1yMIdP-6v1A-fXEE-Q8La-3JP4-yGXD-N3tG4Z" ROTA="0" RO="0" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="ubuntu--vg-ubuntu--lv" TYPE="lvm" SIZE="107374182400" FSTYPE="ext4" MOUNTPOINT="/" UUID="e1a4370f-8b50-408a-bf6c-41be77910cb1" ROTA="0" RO="0" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="sdc" TYPE="disk" SIZE="2000398934016" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="1" RO="0" RM="0" TRAN="sata" SERIAL="WFL3ANGQ" LABEL="" MODEL="ST2000DM008-2FR1" OWNER="root"
NAME="sdc1" TYPE="part" SIZE="2000389406720" FSTYPE="linux_raid_member" MOUNTPOINT="" UUID="100776c9-bc80-9e31-c6d1-93f8c418c2d1" ROTA="1" RO="0" RM="0" TRAN="" SERIAL="" LABEL="SERVEUR-BB:0" MODEL="" OWNER="root"
NAME="sdc9" TYPE="part" SIZE="8388608" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="1" RO="0" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="sdd" TYPE="disk" SIZE="2000398934016" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="1" RO="0" RM="0" TRAN="sata" SERIAL="ZK306AYF" LABEL="" MODEL="ST2000DM008-2FR1" OWNER="root"
NAME="sdd1" TYPE="part" SIZE="2000389406720" FSTYPE="zfs_member" MOUNTPOINT="" UUID="15332071847395975336" ROTA="1" RO="0" RM="0" TRAN="" SERIAL="" LABEL="data-pool" MODEL="" OWNER="root"
NAME="sdd9" TYPE="part" SIZE="8388608" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="1" RO="0" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"
NAME="sde" TYPE="disk" SIZE="2000398934016" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="1" RO="0" RM="0" TRAN="sata" SERIAL="ZFL5QNFC" LABEL="" MODEL="ST2000DM008-2FR1" OWNER="root"
NAME="sde1" TYPE="part" SIZE="2000389406720" FSTYPE="zfs_member" MOUNTPOINT="" UUID="15332071847395975336" ROTA="1" RO="0" RM="0" TRAN="" SERIAL="" LABEL="data-pool" MODEL="" OWNER="root"
NAME="sde9" TYPE="part" SIZE="8388608" FSTYPE="" MOUNTPOINT="" UUID="" ROTA="1" RO="0" RM="0" TRAN="" SERIAL="" LABEL="" MODEL="" OWNER="root"

After investigating with sebhildebrant, the issue on my end, The labels and types weren’t fully erased and set when I switched from linux-raid to zfs.

Thank you for your time and help.

0reactions
MauriceNinocommented, Jun 23, 2022

Technically there is an option for that, but I don’t think it will work for your setup as of right now.

Normally, every disk in blockDevices lists its partitions and mountpoints, but your mountpoint /mnt/host_data is not claimed by any partition, so it would get assigned to your overlay network, which would result in one big graph again.

Read more comments on GitHub >

github_iconTop Results From Across the Web

What RAID means and why you might want one
Best answer: Redundant Array of Independent/Inexpensive Disks (RAID) is a technology that allows storing data across multiple hard drives.
Read more >
RAID (redundant array of independent disks) By - TechTarget
RAID 5. This level is based on parity block-level striping. The parity information is striped across each drive, enabling the array to function, ......
Read more >
RAID level 0, 1, 5, 6 and 10 | Advantage, disadvantage, use
RAID 5 is the most common secure RAID level. It requires at least 3 drives but can work with up to 16. Data...
Read more >
RAID - Wikipedia
RAID is a data storage virtualization technology that combines multiple physical disk drive ... Apple's macOS and macOS Server support RAID 0, RAID...
Read more >
The features of RAID technology : Fujitsu Global
These are typically divided into 6 levels ; RAID 0, RAID 1, RAID 2, RAID 3, RAID 4, RAID 5. They all differ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found