英文:
Mounted volume not shown in prometheus node export
问题
我有一个云服务器,挂载了卷/dev/sdb到/mnt/HC_Volume_1111
lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 0 38.2G 0 disk
├─sda1 8:1 0 38G 0 part /
├─sda14 8:14 0 1M 0 part
└─sda15 8:15 0 122M 0 part /boot/efi
sdb 8:16 0 100G 0 disk /mnt/HC_Volume_1111
sr0 11:0 1 1024M 0 rom
我尝试在我的Prometheus Grafana仪表板中获取这个卷的剩余空间,但我只收到了关于我的/dev/sda的信息。
这是我的Grafana查询:
100 - (node_filesystem_avail_bytes{instance="testurl.com:9100", fstype="ext4"} / node_filesystem_size_bytes{instance="testurl.com:9100", fstype="ext4"} * 100)
如何获取挂载卷的信息?
提前感谢
英文:
I have a cloud server with a mounted volume /dev/sdb on /mnt/HC_Volume_1111
# lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sda 8:0 0 38.2G 0 disk
├─sda1 8:1 0 38G 0 part /
├─sda14 8:14 0 1M 0 part
└─sda15 8:15 0 122M 0 part /boot/efi
sdb 8:16 0 100G 0 disk /mnt/HC_Volume_1111
sr0 11:0 1 1024M 0 rom
I try to get the free space of this volume in my prometheus grafana dashboard, but I only receive the information for my /dev/sda.
This is my query in Grafana:
100 - (node_filesystem_avail_bytes{instance="testurl.com:9100", fstype="ext4"} / node_filesystem_size_bytes{instance="testurl.com:9100", fstype="ext4"} * 100)
How to get the information for my mounted volume as well?
Thanks in advice
答案1
得分: 1
我向我的Prometheus Node Exporter服务添加了以下参数,现在它正常工作:
--collector.filesystem.ignored-mount-points=^/(dev|proc|sys|var/lib/docker/.+)($|/) --collector.filesystem.ignored-fs-types=^(tmpfs|autofs|binfmt_misc|cgroup|configfs|debugfs|devpts|devtmpfs|fusectl|hugetlbfs|mqueue|overlay|proc|procfs|pstore|rpc_pipefs|securityfs|sysfs|tracefs)$
英文:
I added the the following args to my prometheus-node-exporter service and now it's working
--collector.filesystem.ignored-mount-points=^/(dev|proc|sys|var/lib/docker/.+)($|/) --collector.filesystem.ignored-fs-types=^(tmpfs|autofs|binfmt_misc|cgroup|configfs|debugfs|devpts|devtmpfs|fusectl|hugetlbfs|mqueue|overlay|proc|procfs|pstore|rpc_pipefs|securityfs|sysfs|tracefs)$
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论