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

use proot with a recent kernel (4.8.4 and above) I got a segv #25

Closed
magicalyak opened this issue Mar 22, 2017 · 12 comments
Closed

use proot with a recent kernel (4.8.4 and above) I got a segv #25

magicalyak opened this issue Mar 22, 2017 · 12 comments

Comments

@magicalyak
Copy link

As a known issue, you get a segv with a kernel higher than 4.8.4
If you would update your README to include the following information it would eliminate your known issue

adding -e "ROOT_NO_SECCOMP=1" to disable SEGV it will work (of course you disable SEGV though).

Issue is brought up here - proot-me/proot#106

@jangaraj
Copy link
Member

Hi Tom, thx for your feedback. Did you test it? I was testing it a month ago and it was still a problem.

@magicalyak
Copy link
Author

Tested less than a day but I'm using it on a rockstor system (centos7 with new kernel and btrfs and docker). The docker apps listed and I tried to pass custom commands via -e but couldn't tell if they worked. However the base functionality worked! I had to use 172.16.0.1 as the server ip since I'm running the server on the same system as a docker container (I know you can force the ip but using the docker networking ip locally works fine.) external systems just use the rockstor (centos7 nas) as the ip. I've made a docker json to run the server as a "rockon" and plan to add the agent. What else can I test with the agent?

@jangaraj
Copy link
Member

Try to verify these zabbix items pls: docker.discovery, docker.cpu[/<some_container_name>,user], vfs.fs.discovery, net.if.discovery.

@magicalyak
Copy link
Author

magicalyak commented Mar 23, 2017 via email

@jangaraj
Copy link
Member

I've retested ROOT_NO_SECCOMP=1 and it's still a problem:

[root@fedora-512mb-lon1-01 ~]# uname -a
Linux fedora-512mb-lon1-01.localdomain 4.8.6-300.fc25.x86_64 #1 SMP Tue Nov 1 12:36:38 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
[root@fedora-512mb-lon1-01 ~]# docker version
Client:
 Version:      17.03.0-ce
 API version:  1.26
 Go version:   go1.7.5
 Git commit:   3a232c8
 Built:        Tue Feb 28 08:21:51 2017
 OS/Arch:      linux/amd64

Server:
 Version:      17.03.0-ce
 API version:  1.26 (minimum version 1.12)
 Go version:   go1.7.5
 Git commit:   3a232c8
 Built:        Tue Feb 28 08:21:51 2017
 OS/Arch:      linux/amd64
 Experimental: false
[root@fedora-512mb-lon1-01 ~]# docker run \
>   --name=dockbix-agent-xxl \
>   --net=host \
>   --privileged \
>   -v /:/rootfs \
>   -v /var/run:/var/run \
>   --restart unless-stopped \
>   -e "ROOT_NO_SECCOMP=1" \
>   -e "ZA_Server=<ZABBIX SERVER IP/DNS NAME>" \
>   -e "ZA_ServerActive=<ZABBIX SERVER IP/DNS NAME>" \
>   -d monitoringartist/dockbix-agent-xxl-limited:latest
953071bea62c2e40a766216b7e0f895fc410980b891c823935ed67b34891b023
[root@fedora-512mb-lon1-01 ~]# docker logs dockbix-agent-xxl
Dockbix Agent XXL v0.0.1b limited version
Copyright (C) 2014-2017 Jan Garaj - www.monitoringartist.com
Freeware licence - Usage of this binary is restricted to official monitoringartist Docker images only.
proot info: pid 9: terminated with signal 11

Unfortunately, it's not a proper workaround. I will add a note to the Readme.

jangaraj added a commit that referenced this issue Mar 23, 2017
@antgubarev
Copy link

antgubarev commented Mar 29, 2017

docker run \
 --name=dockbix-agent-xxl \
 --net=host \
 --privileged \
 -v /:/rootfs \
 -v /var/run:/var/run \
 -e "ZA_Server=ip" \
 -e "ROOT_NO_SECCOMP=1" \
 -e "ZA_ServerActive=ip" \
 -d monitoringartist/dockbix-agent-xxl-limited:latest

kernel 4.9.8-040908-generic
OS Ubuntu 16.04.1 LTS

Result: proot info: pid 9: terminated with signal 11

@magicalyak
Copy link
Author

magicalyak commented Mar 29, 2017 via email

@alexbarton
Copy link

Probably this issue should be reopened, because the problem still exists?

root@hurzel:~ # uname -a
Linux hurzel 4.8.0-0.bpo.2-amd64 #1 SMP Debian 4.8.11-1~bpo8+1 (2016-12-14) x86_64 GNU/Linux
root@hurzel:~ # docker --version
Docker version 17.04.0-ce, build 4845c56
# docker run --name=dockbix-agent-xxl --net=host --privileged -v /:/rootfs -e "ROOT_NO_SECCOMP=1" -e "ZA_Server=172.31.1.100" -e "ZA_ServerActive=172.31.1.100" -d monitoringartist/dockbix-agent-xxl-limited:latest
bed50d89c47051321f3482e2ce074f1fffb07738cdf8fb1e342f84f465a2ce41
# docker logs dockbix-agent-xxl
Dockbix Agent XXL v0.0.1b limited version
Copyright (C) 2014-2017 Jan Garaj - www.monitoringartist.com
Freeware licence - Usage of this binary is restricted to official monitoringartist Docker images only.
proot info: pid 10: terminated with signal 11
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x626403]

goroutine 1 [running]:
main.main()
	/root/git/dockbix-agent-xxl-private/dockbix-agent-xxl/src/dockbix-agent-xxl.go:257 +0x9f3

@jangaraj
Copy link
Member

jangaraj commented May 2, 2017

Probably this issue should be reopened.

Nope, because this issue is not in this code. It's in the README as known issue. Also I mentioned it above ROOT_NO_SECCOMP=1 is not a proper workaround.

@alexbarton
Copy link

So this is a bug in Docker or the Linux kernel itself? Would it work again with a newer kernel?
Any pointers? Or any other workaround?

Thanks for your work and support @jangaraj!

@jangaraj
Copy link
Member

jangaraj commented May 2, 2017

proot issue proot-me/proot#106

Safe solution: use https://github.com/monitoringartist/zabbix-docker-monitoring on host directly = don't run zabbix agent in the container.

@aviramartac
Copy link

-e "PROOT_NO_SECCOMP=1" works fine for me, I'm getting all metrics.

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

5 participants