Skip to content

Add disk usage metrics to hostmetrics dashboard#173

Open
oleksandr-shostak wants to merge 1 commit intoSigNoz:mainfrom
oleksandr-shostak:feat/add-disk-usage-to-hostmetrics
Open

Add disk usage metrics to hostmetrics dashboard#173
oleksandr-shostak wants to merge 1 commit intoSigNoz:mainfrom
oleksandr-shostak:feat/add-disk-usage-to-hostmetrics

Conversation

@oleksandr-shostak
Copy link

PR Description

## Summary
This PR adds comprehensive disk usage monitoring capabilities to the hostmetrics dashboard, including disk usage tables and percentage graphs per mountpoint.

## Changes Made

### Added Features
1. **Disk Usage Table** (Overview section)
   - Shows disk usage per mountpoint with used and total space in bytes
   - Displays Used % and Free % columns calculated from used/total space
   - Grouped by mountpoint and device

2. **Disk Usage Percentage Graph** (Disk section)
   - Time-series graph showing disk usage percentage over time
   - One line per mountpoint showing usage percentage (0-100%)
   - Helps track disk space trends and identify which disks are filling up

3. **Disk Usage Percentage Table** (Disk section)
   - Table showing current disk usage percentage per mountpoint
   - Quick reference for which disks are near capacity

### Technical Details
- Uses `system.filesystem.usage` metric from hostmetrics receiver
- Calculates percentages using formula: `(used / total) * 100` for used percentage
- Calculates free percentage using formula: `((total - used) / total) * 100`
- All widgets properly organized under the Disk section
- Units configured as `bytes` (auto-formats to KB/MB/GB/TB) and `percentunit` for percentages

### Files Changed
- `hostmetrics/hostmetrics.json` - Added 3 new widgets (table + 2 graphs) with proper layout and queries

## Testing
- ✅ JSON syntax validated
- ✅ All widgets properly configured with queries
- ✅ Layout positions adjusted correctly
- ✅ Widgets organized under Disk section

- Add disk usage table showing used and total space per mountpoint with percentages
- Add disk usage percentage graph over time per mountpoint
- Add disk usage percentage table per mountpoint
- Move disk usage percentage widgets to Disk section
- Include Used % and Free % columns in disk usage table
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant