Skip to content
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

Mount a volume with the mmsdrfs/ZIMonsensors.cfg file #190

Closed
SckyzO opened this issue Mar 4, 2024 · 2 comments
Closed

Mount a volume with the mmsdrfs/ZIMonsensors.cfg file #190

SckyzO opened this issue Mar 4, 2024 · 2 comments
Assignees
Labels
documentation Improvements or additions to documentation enhancement New feature or request prometheus

Comments

@SckyzO
Copy link

SckyzO commented Mar 4, 2024

As discussed in this issue : #169, it would be interesting to allow the container to mount a volume with the mmsdrfs/ZIMonsensors.cfg file rather than having to integrate it before manually or automatically building the container. Especially since this file can be updated.

@SckyzO SckyzO added the enhancement New feature or request label Mar 4, 2024
@Helene Helene added documentation Improvements or additions to documentation prometheus labels Mar 5, 2024
@Helene
Copy link
Member

Helene commented Mar 5, 2024

Hi @SckyzO ,
I have double-checked that no changes are required to the Docker file itself. You can mount ZIMonSensors.cfg file using podman run --mount option (https://docs.podman.io/en/latest/markdown/podman-run.1.html)
Here is an example:

[root@RHEL92-32 ~]# podman run -dt -p 9250:9250 -e "SERVER=9.152.187.158" -e "APIKEYVALUE=dc8c2900-e642-488d-b5a8-a67bf70a9389" -e "PROMETHEUS=9250" -e "TLSKEYPATH=/etc/bridge_ssl/certs" -e "TLSKEYFILE=privkey.pem" -e "TLSCERTFILE=cert.pem" -v /tmp:/var/log/ibm_bridge_for_grafana -v /etc/bridge_ssl/certs:/etc/bridge_ssl/certs --mount type=bind,src=/opt/IBM/zimon/ZIMonSensors.cfg,target=/opt/IBM/zimon/ZIMonSensors.cfg,ro=true --pod new:my-bridge-mount-test-pod --name bridge-mount-test scale_bridge:test_8.0.0_dev
b15bca01aa6c7f66103c76f6badb2a59d24702fe9ebef3ff6dde04b41da3f980

Verify by using /sensorsconfig endpoint

[root@RHEL92-32 ~]# podman container inspect -f '{{.NetworkSettings.IPAddress}}' bridge-mount-test
10.88.0.37
[root@RHEL92-32 tmp]# curl https://10.88.0.37:9250/sensorsconfig -u scale_grafana:dc8c2900-e642-488d-b5a8-a67bf70a9389 -k | jq .
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  2437  100  2437    0     0  76156      0 --:--:-- --:--:-- --:--:-- 78612
[
  {
    "name": "\"CPU\"",
    "period": "1"
  },
  {
    "name": "\"Load\"",
    "period": "1"
  },
  {
    "name": "\"Memory\"",
    "period": "1"
  },
  {
    "filter": "\"netdev_name=veth.*|docker.*|flannel.*|cali.*|cbr.*\"",
    "name": "\"Network\"",
    "period": "1"
  },
  {
    "name": "\"Netstat\"",
    "period": "10"
  },
  {
    "name": "\"Diskstat\"",
    "period": "0"
  },
  {
    "filter": "\"mountPoint=/.*/docker.*|/.*/kubelet.*\"",
    "name": "\"DiskFree\"",
    "period": "600"
  },
  {
    "name": "\"Infiniband\"",
    "period": "0"
  },
  {
    "name": "\"GPFSDisk\"",
    "period": "0"
  },
  {
    "name": "\"GPFSFilesystem\"",
    "period": "10"
  },
  {
    "name": "\"GPFSNSDDisk\"",
    "period": "10",
    "restrict": "\"nsdNodes\""
  },
  {
    "name": "\"GPFSPoolIO\"",
    "period": "0"
  },
  {
    "name": "\"GPFSVFSX\"",
    "period": "10"
  },
  {
    "name": "\"GPFSIOC\"",
    "period": "0"
  },
  {
    "name": "\"GPFSVIO64\"",
    "period": "0"
  },
  {
    "name": "\"GPFSPDDisk\"",
    "period": "10",
    "restrict": "\"nsdNodes\""
  },
  {
    "name": "\"GPFSvFLUSH\"",
    "period": "0"
  },
  {
    "name": "\"GPFSNode\"",
    "period": "10"
  },
  {
    "name": "\"GPFSNodeAPI\"",
    "period": "10"
  },
  {
    "name": "\"GPFSFilesystemAPI\"",
    "period": "10"
  },
  {
    "name": "\"GPFSLROC\"",
    "period": "0"
  },
  {
    "name": "\"GPFSCHMS\"",
    "period": "0"
  },
  {
    "name": "\"GPFSAFM\"",
    "period": "0"
  },
  {
    "name": "\"GPFSAFMFS\"",
    "period": "0"
  },
  {
    "name": "\"GPFSAFMFSET\"",
    "period": "0"
  },
  {
    "name": "\"GPFSRPCS\"",
    "period": "10"
  },
  {
    "name": "\"GPFSWaiters\"",
    "period": "10"
  },
  {
    "name": "\"GPFSFilesetQuota\"",
    "period": "3600",
    "restrict": "\"@CLUSTER_PERF_SENSOR\""
  },
  {
    "name": "\"GPFSFileset\"",
    "period": "300",
    "restrict": "\"@CLUSTER_PERF_SENSOR\""
  },
  {
    "name": "\"GPFSPool\"",
    "period": "300",
    "restrict": "\"@CLUSTER_PERF_SENSOR\""
  },
  {
    "name": "\"GPFSDiskCap\"",
    "period": "86400",
    "restrict": "\"@CLUSTER_PERF_SENSOR\""
  },
  {
    "name": "\"GPFSEventProducer\"",
    "period": "0"
  },
  {
    "name": "\"GPFSMutex\"",
    "period": "0"
  },
  {
    "name": "\"GPFSCondvar\"",
    "period": "0"
  },
  {
    "name": "\"TopProc\"",
    "period": "60"
  },
  {
    "name": "\"GPFSQoS\"",
    "period": "0"
  },
  {
    "name": "\"GPFSFCM\"",
    "period": "0"
  },
  {
    "name": "\"GPFSBufMgr\"",
    "period": "30"
  },
  {
    "name": "\"NFSIO\"",
    "period": "0",
    "restrict": "\"cesNodes\"",
    "type": "\"Generic\""
  },
  {
    "name": "\"SMBStats\"",
    "period": "0",
    "restrict": "\"cesNodes\"",
    "type": "\"Generic\""
  },
  {
    "name": "\"SMBGlobalStats\"",
    "period": "0",
    "restrict": "\"cesNodes\"",
    "type": "\"Generic\""
  },
  {
    "name": "\"CTDBStats\"",
    "period": "0",
    "restrict": "\"cesNodes\"",
    "type": "\"Generic\""
  },
  {
    "name": "\"CTDBDBStats\"",
    "period": "0",
    "restrict": "\"cesNodes\"",
    "type": "\"Generic\""
  }
]

@Helene
Copy link
Member

Helene commented Mar 12, 2024

Applied updates to the instructions for creating containers
https://github.com/IBM/ibm-spectrum-scale-bridge-for-grafana/wiki/Running-the-IBM-Spectrum-Scale-Performance-Monitoring-Bridge-in-a-docker-container

@Helene Helene closed this as completed Mar 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request prometheus
Projects
None yet
Development

No branches or pull requests

2 participants