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

prom query again.. #1274

Closed
mysterytree opened this Issue Dec 24, 2015 · 7 comments

Comments

Projects
None yet
6 participants
@mysterytree
Copy link

mysterytree commented Dec 24, 2015

Hi @juliusv
I want to monitor the container memory used rate.
I write this query

sum(container_memory_usage_bytes{name!=""})by(name)/machine_memory_bytes 

And respones no date.
Maybe both

sum(container_memory_usage_bytes{name!=""})by(name)

and

machine_memory_bytes 

return a list.
So I have to write

sum(container_memory_usage_bytes{name!=""})by(name)/16829906944*100

I have two vm with same the memory
So it can works.
But if they are different ,what should I do ?

@beorn7 beorn7 added the question label Dec 28, 2015

@roman-vynar

This comment has been minimized.

Copy link
Contributor

roman-vynar commented Jan 2, 2016

sum(container_memory_usage_bytes{name!=""})by(name)/ on (LABEL) machine_memory_bytes
where LABEL is common label between those metrics, i.e. jobname or some host definition.

@fabxc fabxc closed this Jan 22, 2016

@cemo

This comment has been minimized.

Copy link

cemo commented Apr 4, 2017

@roman-vynar where container_memory_usage_bytes metrics is coming from? I would like to have this metric too but could not find where I should scrape to get this metric.

@roman-vynar

This comment has been minimized.

Copy link
Contributor

roman-vynar commented Apr 4, 2017

@cemo cadvisor

@cemo

This comment has been minimized.

Copy link

cemo commented Apr 5, 2017

@roman-vynar I am using https://github.com/prometheus/prometheus/blob/master/documentation/examples/prometheus-kubernetes.yml but I could not be sure that this configuration contains scraping kubelets as well. Is there a part for kubelet inside it?

@roman-vynar

This comment has been minimized.

Copy link
Contributor

roman-vynar commented Apr 5, 2017

@cemo We are not using Kubernetes, we run cadvisor standalone on each docker host.

@juliusv

This comment has been minimized.

Copy link
Member

juliusv commented Apr 5, 2017

@lock

This comment has been minimized.

Copy link

lock bot commented Mar 23, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked and limited conversation to collaborators Mar 23, 2019

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.