You can use the below CURL request to send custom metric in Prometheus using Push Gateway.
echo “CUSTOM_METRIC-NAME-HERE STATUS_HERE” | curl -X POST –data-binary @- http://PUSHGATEWAYIP:9091/metrics/job/JOBNAMEHERE/instance/INSTANCENAMEHERE
We have successfully Send custom metric using Prometheus Push Gateway Kindly report in case you are facing difficulties with following details.
- OS name
- OS version
- Package name
- Logs – Error / Warning / failed