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

cAdvisor logs errors when a container it monitors is removed #1772

Closed
AaronKalair opened this issue Oct 16, 2017 · 8 comments · Fixed by #2006
Closed

cAdvisor logs errors when a container it monitors is removed #1772

AaronKalair opened this issue Oct 16, 2017 · 8 comments · Fixed by #2006
Labels

Comments

@AaronKalair
Copy link

Hi,

cAdvisor version - v0.25.0-17543be
On AWS AMI - amzn-ami-2017.03.f-amazon-ecs-optimized (ami-9eb4b1e5)
Using the devicemapper storage driver.

We're seeing our cAdvisor logs full of:

E1016 09:16:47.508913       1 fs.go:333] Stat fs failed. Error: no such file or directory
E1016 09:16:48.487228       1 fs.go:333] Stat fs failed. Error: no such file or directory

Which appears to be coming from here - https://github.com/google/cadvisor/blob/v0.25.0/fs/fs.go#L333

This starts happening after containers have been removed.

To replicate:

  1. Start any random docker container
  2. Start cAdvisor
  3. Tail the cAdvisor containers logs
  4. Note there are no error messages
  5. Docker stop the container
  6. Docker rm the container
  7. You'll now see the above error printed every second in the cAdvisor logs

This will continue until the cAdvisor container is restarted

Is this the intended behaviour?

Thanks!

@janderson2
Copy link

Still seeing this behaviour with version 0.28.3 (1e567c2) while running the binary natively on an EC2 instance running ubuntu 16.04 and using aufs storage driver .

@dashpole
Copy link
Collaborator

The reason for this is that cAdvisor attempts to collect metrics on all filesystems on the host when it starts up. We should lower the verbosity of the log message or ignore devicemapper filesystems.

@tiagoad
Copy link

tiagoad commented Feb 6, 2018

I'm still getting my logs filled with this message every second. Any fix possible while the image is not updated?

@rhuddleston
Copy link

rhuddleston commented Feb 20, 2018

#1847 any plans on a new release soon?

@amihura
Copy link

amihura commented Feb 26, 2018

+++

@nightah
Copy link
Contributor

nightah commented May 4, 2018

@dashpole while it doesn't look like #1847 is necessarily a fix for this, is it likely there might be a change to lower the log verbosity of said error in the instance of devicemapper/zfs filesystems?

At this point, even if we run cadvisor with --v=0 option, the error still appears. You can imagine if containers are being removed frequently, without cadvisor being restarted it can result in hundreds of lines of error logs per second.

@joshperry
Copy link

FYI, having this problem with the btrfs driver as well.

@eklitzke
Copy link
Contributor

eklitzke commented Jul 20, 2018

In addition to lowering the log verbosity, I suggest adding an option like prometheus-node-exporter's --collector.filesystem.ignored-fs-types which would tell cadvisor to ignore the listed filesystem types. This could be used to explicitly ignore aufs etc.

eklitzke added a commit to eklitzke/cadvisor that referenced this issue Jul 20, 2018
eklitzke added a commit to eklitzke/cadvisor that referenced this issue Jul 20, 2018
dashpole added a commit that referenced this issue Aug 15, 2018
Lower log verbosity for statfs failures, fixes #1772
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

9 participants