-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SMART is not displayed on a web page but available in a container through smartctl #2916
Comments
Hi @v-bulynkin the Smart plugin is disable by default in the Glances configuration file. You can enable by editing your glances.conf file (/etc/glances/glances.conf inside the container):
or via the command line:
Keep us inform. |
I wrote that I enabled it in the first message:
I mount the glances.conf file in docker-compose.yml the following way: volumes:
- ./glances/glances.conf:/etc/glances/glances.conf Is it not enough? |
@v-bulynkin
If that works, then could you just try running glances in debug mode ( Should be present at |
I have this configuration now in docker-compose.yml: glances:
image: nicolargo/glances:dev
container_name: glances
hostname: example.com
restart: unless-stopped
pid: host
privileged: true
devices:
- "/dev/nvme0"
environment:
GLANCES_OPT: "-w -d --enable-plugin smart"
volumes:
- ./glances/glances.conf:/etc/glances/glances.conf
- /var/run/docker.sock:/var/run/docker.sock:ro
- /etc/os-release:/etc/os-release:ro
labels:
- "traefik.enable=true"
- "traefik.http.services.glances.loadbalancer.server.port=61208"
- "traefik.http.routers.glances.rule=Host(`example.com`) && (PathPrefix(`/mon/`) || Path(`/mon`))"
- "traefik.http.routers.glances.tls.certresolver=le"
- "traefik.http.routers.glances.entrypoints=websecure" In logs:
|
Note for Glances developer. A mode exist to run PySmart in sudo:
But password should be enter...
or sudoers file configure correctly... |
I'm running glances (not the current version) on a Fedora server as root and seeing similar output - just formatted slightly differently. I'll try testing a newer version:
Testing pySMART directly:
I figured there might be some SELinux interference but there are no log entries from setroubleshootd corresponding with the time this is being tested. Also of course, executing pySMART directly does seem to work. |
Running the current version I get good output:
|
This issue is stale because it has been open for 3 months with no activity. |
Hello dear sir,
I'm trying to display the SMART information from Docker container. What I've done:
disable=False
in glances.conf.After that:
docker exec glances glances --stdout smart
is empty too:docker exec glances smartctl -a /dev/nvme0n1
works well:Why the SMART plugin can't show the information? Does it support NVMe drives?
The text was updated successfully, but these errors were encountered: