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

[BUG] <title> hertzbeat-collector version:newest can not collect cpu info of Host Machine but only hertzbeat-collector's docker #2841

Closed
1 task done
xiaoguolong opened this issue Nov 27, 2024 · 4 comments
Labels
collector question Further information is requested

Comments

@xiaoguolong
Copy link
Contributor

xiaoguolong commented Nov 27, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

最新的版本hertzbeat部署到宿主机192.168.16.43机器,并通过在另外一台机192.168.16.173机器部署最新版本hertzbeat-collector,用的是linux脚本模板
image
image
上面收集到的信息是进去collector容器里面进程信息
image

Expected Behavior

收集到宿主机上的CPU信息
image

Steps To Reproduce

No response

Environment

HertzBeat version(s):

Debug logs

No response

Anything else?

No response

@zuobiao-zhou
Copy link
Member

Since Docker containers operate in an isolated environment, each container has its own process space. If the container is configured to share the PID namespace (using --pid=host), it can access the host's PID namespace, but this reduces security. If possible, it is recommended to deploy the collector by downloading the hertzbeat-collector-xx.tar.gz package.

@xiaoguolong
Copy link
Contributor Author

ok thanks . I have a try of deploy of tar

@zuobiao-zhou zuobiao-zhou added question Further information is requested collector and removed bug Something isn't working labels Nov 29, 2024
@xiaoguolong
Copy link
Contributor Author

xiaoguolong commented Nov 29, 2024

image

thank you . use your point of deploy ,it's ok

Since Docker containers operate in an isolated environment, each container has its own process space. If the container is configured to share the PID namespace (using --pid=host), it can access the host's PID namespace, but this reduces security. If possible, it is recommended to deploy the collector by downloading the hertzbeat-collector-xx.tar.gz package.

@zuobiao-zhou
Copy link
Member

image

thank you . use your point of deploy ,it's ok

Since Docker containers operate in an isolated environment, each container has its own process space. If the container is configured to share the PID namespace (using --pid=host), it can access the host's PID namespace, but this reduces security. If possible, it is recommended to deploy the collector by downloading the hertzbeat-collector-xx.tar.gz package.

Thank you for your feedback. I had not fully considered this issue before. I will include relevant notes in the official documentation to better guide users.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
collector question Further information is requested
Projects
Development

No branches or pull requests

2 participants