prometheus / prometheus/node_exporter

磁盘数据大小采集出错

Open
#3,483 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
13.8k
Forks
2.7k
Avg merge
1d 23h
Merged PRs (30d)
8

Description

真实大小为:3T
/dev/mapper/centos-home xfs 3.0T 2.2T 813G 74% /home

实际采集之后:4G
node_filesystem_size_bytes{device="/dev/mapper/centos-home",device_error="",fstype="xfs",mountpoint="/home"} 4.100632576e+09

[root@-storage home]# df -hT
文件系统 类型 容量 已用 可用 已用% 挂载点
devtmpfs devtmpfs 3.9G 0 3.9G 0% /dev
tmpfs tmpfs 3.9G 0 3.9G 0% /dev/shm
tmpfs tmpfs 3.9G 201M 3.7G 6% /run
tmpfs tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup
/dev/mapper/centos-root xfs 50G 2.9G 48G 6% /
/dev/sda2 xfs 1014M 151M 864M 15% /boot
/dev/mapper/centos-home xfs 3.0T 2.2T 813G 74% /home
tmpfs tmpfs 783M 0 783M 0% /run/user/0
[root@-storage home]#

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the filesystem metrics entry point that emits node_filesystem_size_bytes and reproduce the discrepancy against the provided df -hT output for /dev/mapper/centos-home. Trace how the 3.0T filesystem size becomes 4.100632576e+09, then verify that the metric reports the actual filesystem size without affecting other mounts.

Written by the indexing model from the issue text.

Assessment

Tech stack
centos, go
Domain
observability-sre, operating-systems
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.