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

Issue when using Ipv6 inhome #19

Closed
Technikte opened this issue Jun 14, 2020 · 5 comments
Closed

Issue when using Ipv6 inhome #19

Technikte opened this issue Jun 14, 2020 · 5 comments

Comments

@Technikte
Copy link

Technikte commented Jun 14, 2020

Every config I was tring I got the same error at the end. Do you know how to stop adding these ipv6 routes since docker on unraid doesnt use any ipv6 connectivity ?
My host is an unraid machine.

Sun Jun 14 14:48:59 2020 us=811355 /sbin/ip link set dev tun0 up mtu 1500
Sun Jun 14 14:48:59 2020 us=813029 /sbin/ip addr add dev tun0 10.4.xxx.xx/24 broadcast 10.4.178.255
Sun Jun 14 14:48:59 2020 us=814025 /sbin/ip -6 addr add fdbf:xxxx:xxxx:0:75:2:xxxx:32/112 dev tun0
RTNETLINK answers: Permission denied
Sun Jun 14 14:39:11 2020 us=803937 Linux ip -6 addr add failed: external program exited with error status: 2
Sun Jun 14 14:39:11 2020 us=803946 Exiting due to fatal error
@DyonR
Copy link
Owner

DyonR commented Jun 14, 2020

I do not have a device available with IPv6 so unfortunately I am unable to test this myself.
Could you connect to the console of the conainer, run the following commands:
1:

bash

2:

echo 'net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.ipv6.conf.lo.disable_ipv6 = 1 ' >> /etc/sysctl.conf

After that, click the JackettVPN container and restart it.
Please let me know if this fixes it, if so, I can include it in the Docker itself.

@Technikte
Copy link
Author

Technikte commented Jun 14, 2020

Well, thanks for that fast response. I am not quite sure if we you should kill ipv6 in the container if somebody want to use the docker container on an other type of host/system with full dual-stack internet (ipv4+6).

After some time I found a way to ignore the all ipv6 stuff that my vpn provider pushed to me. These lines should go in the openvpn (.ovpn) config file.

pull-filter ignore 'route-ipv6'
pull-filter ignore 'ifconfig-ipv6'

If someone is really paranoid, it would be good to fully disable ipv6 so no traffic can leak with ipv6 outside the ipv4 tunnel. A -e variable would be nice to disable or enable ipv6 at the startup.

Many thanks for your hard work to maintain this.

An other error I had was somehting with udp..then I swichted in the ovpn to tcp and it works now. Maybe at some point I will create a new issue for that.

@DyonR
Copy link
Owner

DyonR commented Jun 14, 2020

Thanks for letting me know what should be included in the config files!
I'll probably update the README.md with it or just add a new environment variable.
Adding an environment variable 'ENABLE_IPV6' should be easy to add I think (default disabled).
Will need to look for the cleanest way to disable/enable IPV6.
I will close this issue when I've added that

DyonR added a commit that referenced this issue Jun 14, 2020
This commit adds a new environment variable that allows users to enable IPv6 in the container. By default IPv6 will be disabled and can be enabled by setting the environment variable DISABLE_IPV6 to 0. Closes issue #19 (hopefully)
@DyonR
Copy link
Owner

DyonR commented Jun 14, 2020

I've added a new environment variable called 'DISABLE_IPV6'.
Could you please test to see if this works as expected?
Please check for updates for containers within Unraid and update the JackettVPN container. After that click JackettVPN and select Edit.
At the bottom of the page you see 'Add another Path, Port, Variable, Label or Device', click that and enter the following:
Config Type: Variable
Name: DISABLE_IPV6
Key: DISABLE_IPV6
Value: 1
Click ADD and APPLY the new variable to the container. This should disable IPv6 within the container

Please also remove the following lines you added to your ovpn config file to see if this new environment variable indeed works as expected.

pull-filter ignore 'route-ipv6'
pull-filter ignore 'ifconfig-ipv6'

@Technikte
Copy link
Author

I updated and add all missing Variable and so on..
but I need to include the two lines or openvpn tries to add ipv6 routes and so on, which fails and the whole connection process stops.

So all litte note in the readme for all who are using a vpn provider with ipv6 support in config files should be good then.
Thanks for the quick update.

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