Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Disk module doesn't work as expected (again) #48

@Ongy

Description

@Ongy

The problem is, that the resolution hacks in the disk module don't seem to work.
I'll use this issue to give a rough overview of what's currently happening, when a Device Disk module is created (ignoring BTRFS).

First in here the tag is evaluated and gives us back a device name.

Then that device name is resolved to the "lowest" device it comes from, resolving through mappers (here)[https://github.com/monky-hs/monky/blob/master/Monky/Disk/Device.hs#L118]. Most of that work is done in (getMapperDev)[https://github.com/monky-hs/monky/blob/master/Monky/Disk/Common.hs#L70].

This is done to get "accurate" values for read/write rates, those can be messy in mapped devices.

In (devToMount)[https://github.com/monky-hs/monky/blob/master/Monky/Disk/Device.hs#L63] that device is then followed "UP" again to get the mount point.

Most of that happens in (devtoMapper)[https://github.com/monky-hs/monky/blob/master/Monky/Disk/Common.hs#L182] which works by looking into /sys/class/block/<>/holders and building up a tree from there.

The basic concept of this can't deal well with lvm, since it asumes that only one mount point exists for the "bottom most" block device.
Also it seems to be buggy, since @donat-b reportet that it doesn't work for him.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions