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

关于在docker运行的相关问题 #4

Open
treasuring opened this issue Jan 31, 2020 · 2 comments
Open

关于在docker运行的相关问题 #4

treasuring opened this issue Jan 31, 2020 · 2 comments

Comments

@treasuring
Copy link

楼主,我视图通过你生成好的docker镜像运行ss-tproxy或者自行编译,但都不成功,提示如下:
dnsmasq: setting capabilities failed: Operation not permitted iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: host/network proxy' not found
Try iptables -h' or 'iptables --help' for more information. ipset v7.1: Error in line 1: Kernel error received: Operation not permitted getsockopt failed strangely: Operation not permitted iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. iptables v1.4.21: host/network proxy' not found
Try iptables -h' or 'iptables --help' for more information. getsockopt failed strangely: Operation not permitted getsockopt failed strangely: Operation not permitted iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
iptables v1.4.21: can't initialize iptables table mangle': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. getsockopt failed strangely: Operation not permitted getsockopt failed strangely: Operation not permitted iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root)
Perhaps iptables or your kernel needs to be upgraded.
getsockopt failed strangely: Operation not permitted
iptables v1.4.21: can't initialize iptables table nat': Permission denied (you must be root) Perhaps iptables or your kernel needs to be upgraded. getsockopt failed strangely: Operation not permitted RTNETLINK answers: Operation not permitted RTNETLINK answers: Operation not permitted mount: mount point /etc/resolv.conf is not a directory mode: chnroute pxy/tcp: [stopped] pxy/udp: [stopped] dnsmasq: [stopped] chinadns: [running] tail: cannot open '/var/log/ssr-redir.log' for reading: No such file or directory tail: no files remaining
请问如何解决呀?

@treasuring
Copy link
Author

treasuring commented Jan 31, 2020

解决了前面的报错,运行起来2个服务,但还是没能通过代理出去。
前面报错原因:
1.复制ssr配置文件到/etc/ss-tproxy/路径
2.在/etc/dnsmasq.conf配置文件增加user=root
3.运行容器需要增加参数--cap-add=NET_ADMIN

新问题:
dnsmasq: failed to create listening socket for port 53: Address already in use
mount: mount point /etc/resolv.conf is not a directory
mode: gfwlist
pxy/tcp: [running]
pxy/udp: [running]
dnsmasq: [stopped]

@treasuring
Copy link
Author

端口被占用的也解决了,是因为服务已经启动了,dnsmasq的状态stopped也是因为53端口没显示进程名称所以没检测到,但就算是所有服务都启动了,然鹅还是没法转发数据出去。

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

1 participant