Skip to content

fix(inputs.disk): Preserve device tag for virtual filesystems#18335

Merged
srebhan merged 2 commits intoinfluxdata:masterfrom
skartikey:inputs_disk
Feb 16, 2026
Merged

fix(inputs.disk): Preserve device tag for virtual filesystems#18335
srebhan merged 2 commits intoinfluxdata:masterfrom
skartikey:inputs_disk

Conversation

@skartikey
Copy link
Copy Markdown
Contributor

Summary

  • gopsutil v4.26.1 (PR #1931) changed disk.Partitions() to return Device="none" for virtual filesystems (tmpfs, sysfs, devtmpfs, etc.) where the mount source doesn't start with /
  • This causes the device metric tag to change from e.g. device=tmpfs to device=none, breaking user dashboards and queries that filter on this tag
  • Fix: fall back to Fstype when the device is "none" or empty, preserving backwards compatibility

Opened upstream: shirou/gopsutil#2001

Checklist

Related issues

resolves #18293

gopsutil v4.26.1 changed disk.Partitions() to return "none" as the
device for virtual filesystems (tmpfs, sysfs, etc.) instead of the
mount source name.

Fall back to the filesystem type when the device is "none" or empty
to maintain backwards compatibility.
@telegraf-tiger telegraf-tiger bot added fix pr to fix corresponding bug plugin/input 1. Request for new input plugins 2. Issues/PRs that are related to input plugins labels Feb 10, 2026
@skartikey skartikey changed the title fix(inputs.disk): preserve device tag for virtual filesystems fix(inputs.disk): Preserve device tag for virtual filesystems Feb 10, 2026
…ystems

Cover both "none" and empty device name cases to verify that the
fstype fallback preserves backwards compatibility with gopsutil v4.26.1.
@telegraf-tiger
Copy link
Copy Markdown
Contributor

Copy link
Copy Markdown
Member

@mstrandboge mstrandboge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Backwards compatibility patch looks good, thanks for looking into this!

@mstrandboge mstrandboge removed their assignment Feb 12, 2026
@mstrandboge mstrandboge added the ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review. label Feb 12, 2026
Copy link
Copy Markdown
Member

@srebhan srebhan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot @skartikey!

@srebhan srebhan merged commit 3b2d17c into influxdata:master Feb 16, 2026
27 checks passed
@github-actions github-actions bot added this to the v1.37.3 milestone Feb 16, 2026
mstrandboge pushed a commit that referenced this pull request Feb 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fix pr to fix corresponding bug plugin/input 1. Request for new input plugins 2. Issues/PRs that are related to input plugins ready for final review This pull request has been reviewed and/or tested by multiple users and is ready for a final review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants