Giter Site home page Giter Site logo

prometheus-process-exporter's Issues

why can't get metrics

---
# Source: prometheus-process-exporter/templates/psp.yaml
apiVersion: policy/v1beta1
kind: PodSecurityPolicy
metadata:
  labels:
    app: prometheus-process-exporter
  name: release-name-prometheus-process-exporter
spec:
  privileged: false
  volumes:
    - 'configMap'
    - 'emptyDir'
    - 'projected'
    - 'secret'
    - 'downwardAPI'
    - 'persistentVolumeClaim'
    - 'hostPath'
  hostNetwork: true
  hostIPC: false
  hostPID: true
  hostPorts:
    - min: 0
      max: 65535
  runAsUser:
    # Permits the container to run with root privileges as well.
    rule: 'RunAsAny'
  seLinux:
    # This policy assumes the nodes are using AppArmor rather than SELinux.
    rule: 'RunAsAny'
  supplementalGroups:
    rule: 'MustRunAs'
    ranges:
      # Forbid adding the root group.
      - min: 0
        max: 65535
  fsGroup:
    rule: 'MustRunAs'
    ranges:
      # Forbid adding the root group.
      - min: 0
        max: 65535
  readOnlyRootFilesystem: false
---
# Source: prometheus-process-exporter/templates/serviceaccount.yaml
apiVersion: v1
kind: ServiceAccount
metadata:
  name: release-name-prometheus-process-exporter
  labels:
    app: prometheus-process-exporter
automountServiceAccountToken: true
---
# Source: prometheus-process-exporter/templates/configmap.yaml
apiVersion: v1
kind: ConfigMap
metadata:
  namespace: alert
  name: release-name-prometheus-process-exporter
  labels:
    app: prometheus-process-exporter
data:
  config.yml: |-
    process_names:
      - name: "{{.Comm}}"
        cmdline:
        - '.+'
---
# Source: prometheus-process-exporter/templates/psp-clusterrole.yaml
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
  labels:
    app: prometheus-process-exporter
  name: psp-release-name-prometheus-process-exporter
rules:
- apiGroups: ['extensions']
  resources: ['podsecuritypolicies']
  verbs:     ['use']
  resourceNames:
  - release-name-prometheus-process-exporter
---
# Source: prometheus-process-exporter/templates/psp-clusterrolebinding.yaml
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
  labels:
    app: prometheus-process-exporter
  name: psp-release-name-prometheus-process-exporter
roleRef:
  apiGroup: rbac.authorization.k8s.io
  kind: ClusterRole
  name: psp-release-name-prometheus-process-exporter
subjects:
  - kind: ServiceAccount
    name: release-name-prometheus-process-exporter
    namespace: alert
---
# Source: prometheus-process-exporter/templates/daemonset.yaml
apiVersion: apps/v1
kind: DaemonSet
metadata:
  namespace: alert
  name: prometheus-process-exporter
  labels:
    app: prometheus-process-exporter
spec:
  selector:
    matchLabels:
      app: prometheus-process-exporter
  updateStrategy:
    rollingUpdate:
      maxUnavailable: 1
    type: RollingUpdate
  template:
    metadata:
      labels:
        app: prometheus-process-exporter
    spec:
      serviceAccountName: release-name-prometheus-process-exporter
      securityContext:
        runAsNonRoot: true
        runAsUser: 65534
      containers:
        - name: prometheus-process-exporter
          image: xxx
          imagePullPolicy: IfNotPresent
          args:
            - --procfs=/host/proc
            - --config.path=/var/process-exporter/config.yml
            - --web.listen-address=0.0.0.0:9256
            - --debug=true
          ports:
            - containerPort: 9256
          resources:
            requests:
              cpu: 120m
              memory: 120Mi
          volumeMounts:
            - name: proc
              mountPath: /host/proc
              readOnly:  true
            - name: config
              mountPath: /var/process-exporter
      hostPID: true
      tolerations:
      - key: "node-role.kubernetes.io/master"
        operator: "Exists"
        effect: "NoSchedule"
      - effect: NoSchedule
        operator: Exists
      - effect: NoExecute
        operator: Exists
      volumes:
        - name: proc
          hostPath:
            path: /proc
        - name: config
          configMap:
            name: release-name-prometheus-process-exporter

image

I think the pod is running normally. Why can't I get metrics through K8s node ip: 9256/metrics?

image
I want to enter the container to check the problem, but an error is reported!

namedprocess_namegroup_open_filedesc is always zero

Hi,
the namedprocess_namegroup_open_filedesc always return 0 for all process when the process-exporter is deployed with the helm chart!
I have run the process-exporter binary and it is working ok but when we deploy it using helm chart it can't monitor open file descriptors.

Update repository index to reflect the latest version 0.5.0

Currently, the latest Chart version according to repository index is 0.4.2 (prometheus-process-exporter/master/docs)

However, the directory prometheus-process-exporter/charts/prometheus-process-exporter/Chart.yaml has more recent version — 0.5.0

Thank you

pod labels

Hi @mumoshu, great work - Thanks!
Quick question - I couldn't manage to get the PodLabels working, when running the process exporter. I see the nodes, threads aso. but unfortunately, never the Pod names. Any hint or idea how to get that to work?

Thanks

securityContext value not implemented

You have the following values

securityContext:
  runAsNonRoot: true
  runAsUser: 65534

However they are not used anywhere in the chart. In the PSP you have

runAsUser:
    # Permits the container to run with root privileges as well.
    rule: 'RunAsAny'`
  supplementalGroups:
    rule: 'MustRunAs'
    ranges:
      # Forbid adding the root group.
      - min: 0
        max: 65535
  fsGroup:
    rule: 'MustRunAs'
    ranges:
      # Forbid adding the root group.
      - min: 0
        max: 65535

The logic wasn't implemented

Unable to run helm chart

getting Error: INSTALLATION FAILED: unable to build kubernetes objects from release manifest: [resource mapping not found for name: "psp-process-exporter-prometheus-process-exporter" namespace: "" from "": no matches for kind "ClusterRole" in version "rbac.authorization.k8s.io/v1beta1"
ensure CRDs are installed first, resource mapping not found for name: "psp-process-exporter-prometheus-process-exporter" namespace: "" from "": no matches for kind "ClusterRoleBinding" in version "rbac.authorization.k8s.io/v1beta1"
ensure CRDs are installed first]

please can some one help with it

Feature Request: Enable adding custom relabelings configs in service monitor definition

Hi @mumoshu, I have a situation where i needed to attach another label with the process-exporter metrics. Since the existing service-monitor definition does not expose a parameter to add custom relabelings config, i ended up adding a custom service monitor to my source code.

Here is a bitnami sample for adding custom relabelings config.

https://github.com/bitnami/charts/blob/dd62c04776102f90eb54a1f2cf1c901b03af6b3e/bitnami/node-exporter/templates/servicemonitor.yaml#L45C1-L46C1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.