Originally created by @Lukas-Heiligenbrunner on GitHub (Aug 13, 2024).
When using docker bind mountpoints every mountpoint shows as device and is added multiple times to the total capacity.
Compose file:
```
version: '3'
services:
aurcache_dev:
image: ghcr.io/lukas-heiligenbrunner/aurcache:latest
ports:
- "9095:8080"
- "9096:8081"
volumes:
- aurcache_db_dev:/app/db
- aurcache_repo_dev:/app/repo
- /var/run/docker.sock:/var/run/docker.sock
- artifact_cache:/app/builds
environment:
- BUILD_ARTIFACT_DIR=artifact_cache # also absolute path is possible
- LOG_LEVEL=trace
- MAX_CONCURRENT_BUILDS=2
- CPU_LIMIT=100
- MEMORY_LIMIT=-1
restart: unless-stopped
volumes:
artifact_cache:
driver: local
aurcache_db_dev:
driver: local
driver_opts:
type: none
o: bind
device: "/media/3TBRaid/3TBRaid/Docker/aurcache-dev/db"
aurcache_repo_dev:
driver: local
driver_opts:
type: none
o: bind
device: "/media/3TBRaid/3TBRaid/Docker/aurcache-dev/repo"
```

I think it is reasonable to additionally filter out any disks which appear to be docker volumes: eg. starts with /var/lib/docker/volume/*. I don't see a situation where you would want a volume mounted to a path there to show up in the disk usage report.
There may not be a way for Monitor to reliably infer that a disk report is actually a mount and should be ignored, it just depends on User setup. I can add another configuration field to Server, ignore_mounts, which will allow the user to hard filter out any of mounts that are able to get through the guards I put to keep them out.
@mbecker20 commented on GitHub (Aug 13, 2024):
Hi, thanks for the report.
I am aware of this happening in other cases with docker mounts, in those cases I saw though the file system was able to report as "overlay". And I filter these disks out: [https://github.com/mbecker20/monitor/blob/2d0c1724db77f8b1211dd60436f015ee1000be89/bin/periphery/src/stats.rs#L108](https://github.com/mbecker20/monitor/blob/2d0c1724db77f8b1211dd60436f015ee1000be89/bin/periphery/src/stats.rs#L108) Clearly this isn't working here though.
I see two actions to resolve this:
1. I think it is reasonable to additionally filter out any disks which appear to be docker volumes: eg. starts with /var/lib/docker/volume/*. I don't see a situation where you would want a volume mounted to a path there to show up in the disk usage report.
2. There may not be a way for Monitor to reliably infer that a disk report is actually a mount and should be ignored, it just depends on User setup. I can add another configuration field to Server, `ignore_mounts`, which will allow the user to hard filter out any of mounts that are able to get through the guards I put to keep them out.
Additionally, can now avoid any future edge cases here using the new Server config field ignore_mounts:
@mbecker20 commented on GitHub (Aug 15, 2024):
Hey, should be fixed in this commit: [https://github.com/mbecker20/monitor/commit/a2b0981f7632d8ff2ac5419ec2827228500cd6b6](https://github.com/mbecker20/monitor/commit/a2b0981f7632d8ff2ac5419ec2827228500cd6b6).
Additionally, can now avoid any future edge cases here using the new Server config field `ignore_mounts`:
<img width="988" alt="Screenshot 2024-08-15 at 3 00 21 AM" src="https://github.com/user-attachments/assets/7d58dd5c-f680-4f6b-a839-06e4aafec521">
When you get a chance, could you try out ghcr.io/mbecker20/monitor:latest and confirm the issue is fixed?
@mbecker20 commented on GitHub (Aug 15, 2024):
When you get a chance, could you try out `ghcr.io/mbecker20/monitor:latest` and confirm the issue is fixed?
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Originally created by @Lukas-Heiligenbrunner on GitHub (Aug 13, 2024).
When using docker bind mountpoints every mountpoint shows as device and is added multiple times to the total capacity.
Compose file:
@mbecker20 commented on GitHub (Aug 13, 2024):
Hi, thanks for the report.
I am aware of this happening in other cases with docker mounts, in those cases I saw though the file system was able to report as "overlay". And I filter these disks out: https://github.com/mbecker20/monitor/blob/2d0c1724db77f8b1211dd60436f015ee1000be89/bin/periphery/src/stats.rs#L108 Clearly this isn't working here though.
I see two actions to resolve this:
I think it is reasonable to additionally filter out any disks which appear to be docker volumes: eg. starts with /var/lib/docker/volume/*. I don't see a situation where you would want a volume mounted to a path there to show up in the disk usage report.
There may not be a way for Monitor to reliably infer that a disk report is actually a mount and should be ignored, it just depends on User setup. I can add another configuration field to Server,
ignore_mounts, which will allow the user to hard filter out any of mounts that are able to get through the guards I put to keep them out.@mbecker20 commented on GitHub (Aug 15, 2024):
Hey, should be fixed in this commit: https://github.com/mbecker20/monitor/commit/a2b0981f7632d8ff2ac5419ec2827228500cd6b6.
Additionally, can now avoid any future edge cases here using the new Server config field
ignore_mounts:@mbecker20 commented on GitHub (Aug 15, 2024):
When you get a chance, could you try out
ghcr.io/mbecker20/monitor:latestand confirm the issue is fixed?@Lukas-Heiligenbrunner commented on GitHub (Aug 15, 2024):
Looks good now.
Thanks a lot!