Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose mdadm status in host/advanced #7634

Open
olivierlambert opened this issue May 3, 2024 · 0 comments
Open

Expose mdadm status in host/advanced #7634

olivierlambert opened this issue May 3, 2024 · 0 comments

Comments

@olivierlambert
Copy link
Member

olivierlambert commented May 3, 2024

We need to expose mdadm health info, leveraging the relevant XAPI plugin doing this.

Here is an example with xe:

$ xe host-call-plugin host-uuid=<uuid> plugin=raid.py fn=check_raid_pool
{"raid": {"Working Devices": "2", "Raid Devices": "2", "Raid Level": "raid1", "Creation Time": "Wed Jul 17 13:29:42 2019", "Used Dev Size": "52428672 (50.00 GiB 53.69 GB)", "UUID": "1766eb6e:85762159:4c98b42e:2da92c97", "Array Size": "52428672 (50.00 GiB 53.69 GB)", "Failed Devices": "0", "State": "clean", "Version": "1.0", "Events": "44", "Persistence": "Superblock is persistent", "Spare Devices": "0", "Name": "localhost:127", "Active Devices": "2", "Total Devices": "2", "Update Time": "Tue Jul 30 01:58:48 2019"}, "volumes": [["0", "8", "0", "0", "active sync", "/dev/sda"], ["1", "8", "16", "1", "active sync", "/dev/sdb"]]}
  1. If the plugins reports {} it means there's no mdadm RAID, so it's not useful to even display anything
  2. If there's something else than {}, for any State other than active or clean, we should provide a red/warning and display the state. If it's doable, it might worth a warning in the Home/host view, where we already have our alerts displayed.
  3. Otherwise it's active or clean and comes with a "All mdadm RAID are healthy ✅"

Debouncing

We should debounce the plugin call as possible, there's no need to call it every load, once per 10min is far than enough for now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant