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

Monitoring host network does not work while the networking of container is not host #4505

Closed
amiraliucsc opened this issue Aug 2, 2018 · 1 comment

Comments

@amiraliucsc
Copy link

amiraliucsc commented Aug 2, 2018

Feature Request

Opening a feature request kicks off a discussion.

Proposal:

I am running Telegraf 1.7 as a docker container. I have a network defined which both telegraf and influx are using it. When I mount /proc/net/dev inside the container in /rootfs/proc/net/dev, that files only contains loopback and one more interface. But I need to pass all the information of the host. If I do cat /proc/net/dev in the host, I see all the interfaceses wherease if I cat /rootfs/proc/net/dev I see only one interface beside loopbak.

Current behavior:

Desired behavior:

I would like to see all the interfaces in the docker container.

Use case: [Why is this important (helps with prioritizing requests)]

To run Telegraf as docker and be able to collect network metrics of the host

@glinton
Copy link
Contributor

glinton commented Aug 9, 2018

This is a network namespace limitation, you will need to use --net=host on your telegraf container in order to monitor host interfaces. see here for similar question

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants