monitoring

Configure basic_auth for Prometheus Target

家住魔仙堡 提交于 2021-02-19 07:07:31
问题 One of the targets in static_configs in my prometheus.yml config file is secured with basic authentication. As a result, an error of description "Connection refused" is always displayed against that target in the Prometheus Targets' page. I have researched how to setup prometheus to provide the security credentials when trying to scrape that particular target but couldn't find any solution. What I found was how to set it up on the scrape_config section in the docs. This won't work for me

Docker Container CPU usage Monitoring

眉间皱痕 提交于 2021-02-11 17:55:38
问题 As per the documentation of docker. We can get CPU usage of docker container with docker stats command. The column CPU % will give the percentage of the host’s CPU the container is using. Let say I limit the container to use 50% of hosts single CPU. I can specify 50% single CPU core limit by --cpus=0.5 option as per https://docs.docker.com/config/containers/resource_constraints/ How can we get the CPU% usage of container out of allowed CPU core by any docker command? E.g. Out of 50% Single

Any ways to show file changes (with pyinotify for example)?

泄露秘密 提交于 2021-02-08 06:30:08
问题 Is there any way to print a watched file modification ? let's take an example: I'm monitoring file.txt, Pyinotify can tell me that it has been modified, but It can't seem to be able to output what changes occured ? Am I wrong ? How can I see what changes has been made to a file that I'm monitoring ? Big thanks in advance, sorry for my bad english. 回答1: The inotify mechanism does not embed the deltas in the event, because it should compute it before saving the files and this could affect

How to determine how much CPU load is produced from processes running under some user in Linux? [closed]

雨燕双飞 提交于 2021-02-08 05:15:42
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 9 years ago . Improve this question I would like to make a simple monitoring script that will record CPU load produced by user "abc" in a text file. vmstat, iostat, mpstat and free do not seem to have a capability to filter based on user name. Is it possible at all? EDIT : Btw. I'm running on Red Hat EL 6.0. 回答1: A simple way

How to determine how much CPU load is produced from processes running under some user in Linux? [closed]

左心房为你撑大大i 提交于 2021-02-08 05:14:43
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 9 years ago . Improve this question I would like to make a simple monitoring script that will record CPU load produced by user "abc" in a text file. vmstat, iostat, mpstat and free do not seem to have a capability to filter based on user name. Is it possible at all? EDIT : Btw. I'm running on Red Hat EL 6.0. 回答1: A simple way

Is there any way to set up an alert on low disk space for Azure App Service

老子叫甜甜 提交于 2021-02-07 20:21:01
问题 I'm running an Azure App Service on a Standard App Service Plan which allows usage of max 50 GB of file storage. The application uses quite a lot of disk space for image cache. Currently the consumption level lies at around 15 GB but if cache cleaning policy fails for some reason it will grow up to the top very fast. Vertical autoscaling (scaling up) is not a common practice as it often requires some service downtime according to this Microsoft article: https://docs.microsoft.com/en-us/azure

Is there any way to set up an alert on low disk space for Azure App Service

喜你入骨 提交于 2021-02-07 20:20:00
问题 I'm running an Azure App Service on a Standard App Service Plan which allows usage of max 50 GB of file storage. The application uses quite a lot of disk space for image cache. Currently the consumption level lies at around 15 GB but if cache cleaning policy fails for some reason it will grow up to the top very fast. Vertical autoscaling (scaling up) is not a common practice as it often requires some service downtime according to this Microsoft article: https://docs.microsoft.com/en-us/azure

Monitoring the size of the Netty event loop queues

你。 提交于 2021-02-07 11:28:11
问题 We've implemented monitoring for the Netty event loop queues in order to understand issues with some of our Netty modules. The monitor uses the io.netty.util.concurrent.SingleThreadEventExecutor#pendingTasks method, which works for most modules, but for a module that handle a few thousand HTTP requests per second it seem to be hung, or very slow. I now realize that the docs strictly specify this can be an issue, and I feel pretty lame... so I'm looking for another way to implement this

How do I Monitor Text File Changes with C++? Difficulty: No .NET

主宰稳场 提交于 2021-02-07 07:58:20
问题 Use case: 3rd party application wants to programatically monitor a text file being generated by another program. Text file contains data you want to analyze as it's being updated. I'm finding a lot of answers to this question wrapped around FileSystemWatcher but let's say you are writing an application for a Windows machine and can't guarantee .NET is installed. Are there any libraries out there available for this, or am I just going to have to roll my own solution then? Thanks. 回答1: You can

How do I Monitor Text File Changes with C++? Difficulty: No .NET

别说谁变了你拦得住时间么 提交于 2021-02-07 07:57:54
问题 Use case: 3rd party application wants to programatically monitor a text file being generated by another program. Text file contains data you want to analyze as it's being updated. I'm finding a lot of answers to this question wrapped around FileSystemWatcher but let's say you are writing an application for a Windows machine and can't guarantee .NET is installed. Are there any libraries out there available for this, or am I just going to have to roll my own solution then? Thanks. 回答1: You can