October 11, 20223 yr Just updated to 6.11.1 from 6.10.3 and my wireguard tunnels doesn't seem to start? And yes, I did refresh the tunnel configs as instructed in the release notes 🙂  My remote clients will start, but only show send activity. Nothing for recieved. There is a slider in the settings for the tunnel showing "INACTIV". When clicking it it slides to "ACTIVE" and then directly back again.  In the syslog I can see Oct 11 11:55:49 XXX wireguard: Tunnel WireGuard-wg1 started and nothing else.  I also see there is a wg.quick.log file that updates when I updated a tunnel and there I see some errors, but I do not understand what they mean. wg-quick up wg0 (autostart) [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 10.253.0.1 dev wg0 [#] ip link set mtu 1420 up dev wg0 [#] ip -4 route add 10.253.0.5/32 dev wg0 [#] ip -4 route add 10.253.0.4/32 dev wg0 [#] ip -4 route add 10.253.0.3/32 dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 started' [#] iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o bond0 -j MASQUERADE wg-quick up wg1 (autostart) [#] ip link add wg1 type wireguard [#] wg setconf wg1 /dev/fd/63 [#] ip -4 address add 10.253.1.1 dev wg1 [#] ip link set mtu 1420 up dev wg1 [#] ip -4 route add 10.253.1.4/32 dev wg1 [#] ip -4 route add 10.253.1.3/32 dev wg1 [#] ip -4 route add 10.253.1.2/32 dev wg1 [#] logger -t wireguard 'Tunnel WireGuard-wg1 started' [#] iptables -t nat -A POSTROUTING -s 10.253.1.0/24 -o bond0 -j MASQUERADE wg-quick down wg0 [#] ip link delete dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 stopped' [#] iptables -t nat -D POSTROUTING -s 10.253.0.0/24 -o bond0 -j MASQUERADE wg-quick up wg0 [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 10.253.0.1 dev wg0 [#] ip link set mtu 1420 up dev wg0 [#] ip -4 route add 10.253.0.5/32 dev wg0 [#] ip -4 route add 10.253.0.4/32 dev wg0 [#] ip -4 route add 10.253.0.3/32 dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 started' [#] iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 200 [#] ip -4 route add default via 10.253.0.1 dev wg0 table 200 [#] ip -4 route add 192.168.xxx.xxx/24 via 192.168.xxx.xxx dev table 200 Error: either "to" is duplicate, or "200" is a garbage. [#] ip link delete dev wg0 wg-quick down wg1 [#] ip link delete dev wg1 [#] logger -t wireguard 'Tunnel WireGuard-wg1 stopped' [#] iptables -t nat -D POSTROUTING -s 10.253.1.0/24 -o bond0 -j MASQUERADE wg-quick up wg1 [#] ip link add wg1 type wireguard [#] wg setconf wg1 /dev/fd/63 [#] ip -4 address add 10.253.1.1 dev wg1 [#] ip link set mtu 1420 up dev wg1 [#] ip -4 route add 10.253.1.4/32 dev wg1 [#] ip -4 route add 10.253.1.3/32 dev wg1 [#] ip -4 route add 10.253.1.2/32 dev wg1 [#] logger -t wireguard 'Tunnel WireGuard-wg1 started' [#] iptables -t nat -A POSTROUTING -s 10.253.1.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 201 [#] ip -4 route add default via 10.253.1.1 dev wg1 table 201 [#] ip -4 route add 192.168.xxx.xxx/24 via 192.168.xxx.xxx dev table 201 Error: either "to" is duplicate, or "201" is a garbage. [#] ip link delete dev wg1 wg-quick down wg1 wg-quick: `wg1' is not a WireGuard interface wg-quick up wg0 [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 10.253.0.1 dev wg0 [#] ip link set mtu 1420 up dev wg0 [#] ip -4 route add 10.253.0.5/32 dev wg0 [#] ip -4 route add 10.253.0.4/32 dev wg0 [#] ip -4 route add 10.253.0.3/32 dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 started' [#] iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 200 [#] ip -4 route add default via 10.253.0.1 dev wg0 table 200 [#] ip -4 route add 192.168.xxx.xxx/24 via 192.168.xxx.xxx dev table 200 Error: either "to" is duplicate, or "200" is a garbage. [#] ip link delete dev wg0 wg-quick down wg0 wg-quick: `wg0' is not a WireGuard interface wg-quick up wg0 [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 10.253.0.1 dev wg0 [#] ip link set mtu 1420 up dev wg0 [#] ip -4 route add 10.253.0.5/32 dev wg0 [#] ip -4 route add 10.253.0.4/32 dev wg0 [#] ip -4 route add 10.253.0.3/32 dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 started' [#] iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 200 [#] ip -4 route add default via 10.253.0.1 dev wg0 table 200 [#] ip -4 route add 192.168.xxx.xxx/24 via 192.168.xxx.xxx dev table 200 Error: either "to" is duplicate, or "200" is a garbage. [#] ip link delete dev wg0 wg-quick down wg0 wg-quick: `wg0' is not a WireGuard interface wg-quick up wg1 [#] ip link add wg1 type wireguard [#] wg setconf wg1 /dev/fd/63 [#] ip -4 address add 10.253.1.1 dev wg1 [#] ip link set mtu 1420 up dev wg1 [#] ip -4 route add 10.253.1.4/32 dev wg1 [#] ip -4 route add 10.253.1.3/32 dev wg1 [#] ip -4 route add 10.253.1.2/32 dev wg1 [#] logger -t wireguard 'Tunnel WireGuard-wg1 started' [#] iptables -t nat -A POSTROUTING -s 10.253.1.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 201 [#] ip -4 route add default via 10.253.1.1 dev wg1 table 201 [#] ip -4 route add 192.168.xxx.xxx/24 via 192.168.xxx.xxx dev table 201 Error: either "to" is duplicate, or "201" is a garbage. [#] ip link delete dev wg1 wg-quick down wg1 wg-quick: `wg1' is not a WireGuard interface wg-quick up wg0 [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 10.253.0.1 dev wg0 [#] ip link set mtu 1420 up dev wg0 [#] ip -4 route add 10.253.0.5/32 dev wg0 [#] ip -4 route add 10.253.0.4/32 dev wg0 [#] ip -4 route add 10.253.0.3/32 dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 started' [#] iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 200 [#] ip -4 route add default via 10.253.0.1 dev wg0 table 200 [#] ip -4 route add 192.168.xxx.xxx/24 via 192.168.xxx.xxx dev table 200 Error: either "to" is duplicate, or "200" is a garbage. [#] ip link delete dev wg0 wg-quick down wg0 wg-quick: `wg0' is not a WireGuard interface wg-quick down wg0 wg-quick: `wg0' is not a WireGuard interface wg-quick up wg0 [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 10.253.0.1 dev wg0 [#] ip link set mtu 1420 up dev wg0 [#] ip -4 route add 10.253.0.5/32 dev wg0 [#] ip -4 route add 10.253.0.4/32 dev wg0 [#] ip -4 route add 10.253.0.3/32 dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 started' [#] iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 200 [#] ip -4 route add default via 10.253.0.1 dev wg0 table 200 [#] ip -4 route add 192.168.xxx.xxx/24 via 192.168.xxx.xxx dev table 200 Error: either "to" is duplicate, or "200" is a garbage. [#] ip link delete dev wg0 wg-quick down wg0 wg-quick: `wg0' is not a WireGuard interface wg-quick down wg0 wg-quick: `wg0' is not a WireGuard interface wg-quick down wg1 wg-quick: `wg1' is not a WireGuard interface wg-quick up wg0 [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 10.253.0.1 dev wg0 [#] ip link set mtu 1420 up dev wg0 [#] ip -4 route add 10.253.0.5/32 dev wg0 [#] ip -4 route add 10.253.0.4/32 dev wg0 [#] ip -4 route add 10.253.0.3/32 dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 started' [#] iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 200 [#] ip -4 route add default via 10.253.0.1 dev wg0 table 200 [#] ip -4 route add 192.168.xxx.xxx/24 via 192.168.xxx.xxx dev table 200 Error: either "to" is duplicate, or "200" is a garbage. [#] ip link delete dev wg0 wg-quick down wg0 wg-quick: `wg0' is not a WireGuard interface wg-quick up wg1 [#] ip link add wg1 type wireguard [#] wg setconf wg1 /dev/fd/63 [#] ip -4 address add 10.253.1.1 dev wg1 [#] ip link set mtu 1420 up dev wg1 [#] ip -4 route add 10.253.1.4/32 dev wg1 [#] ip -4 route add 10.253.1.3/32 dev wg1 [#] ip -4 route add 10.253.1.2/32 dev wg1 [#] logger -t wireguard 'Tunnel WireGuard-wg1 started' [#] iptables -t nat -A POSTROUTING -s 10.253.1.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 201 [#] ip -4 route add default via 10.253.1.1 dev wg1 table 201 [#] ip -4 route add 192.168.xxx.xxx/24 via 192.168.xxx.xxx dev table 201 Error: either "to" is duplicate, or "201" is a garbage. [#] ip link delete dev wg1 wg-quick down wg1 wg-quick: `wg1' is not a WireGuard interface Spoiler  Â
October 11, 20223 yr I do not use Wireguard, so I am not sure it is relevant for your situation but there was a mention of Wireguard in the release notes for 6.11.1 Did you check that ? Â Â Â
October 11, 20223 yr Author Yes, it is relevant, but I did perform the "Users are advised to regenerate the WG configs" as instructed. I included that information in my description, but mayby I wasn't clear enough. Thank you anyways for responding
October 13, 20223 yr Author Still have this problem and made some more tests. Tried deleting peers and set up new, but have the same problems so I deleted all tunnels and started anew.   I can start this tunnel which add these lines to wg-quick.log wg-quick down wg0 wg-quick: `/etc/wireguard/wg0.conf' does not exist  But it does exist. Looks like this: [Interface] #test05 PrivateKey=ANoWVzWStD+5FBt3OoeOv4UDhDEayUDwd6n43ZmLr0M= Address=10.253.0.1 ListenPort=51820 PostUp=logger -t wireguard 'Tunnel WireGuard-wg0 started' PostUp=iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE PostDown=logger -t wireguard 'Tunnel WireGuard-wg0 stopped' PostDown=iptables -t nat -D POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE  And I can start it, which add these lines to wg-quick.log wg-quick up wg0 [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 10.253.0.1 dev wg0 [#] ip link set mtu 1420 up dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 started' [#] iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE  Ok, so a tunnel seems to be up, but when I add a peer it goes wrong and the tunnel goes from ACTIVE to INACTIVE I see this added in the wg-quick.log wg-quick down wg0 [#] ip link delete dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 stopped' [#] iptables -t nat -D POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE wg-quick up wg0 [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 10.253.0.1 dev wg0 [#] ip link set mtu 1420 up dev wg0 [#] ip -4 route add 10.253.0.2/32 dev wg0 [#] logger -t wireguard 'Tunnel WireGuard-wg0 started' [#] iptables -t nat -A POSTROUTING -s 10.253.0.0/24 -o eth0 -j MASQUERADE [#] ip -4 route flush table 200 [#] ip -4 route add default via 10.253.0.1 dev wg0 table 200 [#] ip -4 route add 192.168.100.0/24 via 192.168.100.1 dev  table 200 Error: either "to" is duplicate, or "200" is a garbage. [#] ip link delete dev wg0  What is the table 200 problem here? Is there a wg0 missing in the second route add? Seems to be double space there?  Any pointers would be apriciated - hanging on by a thread here with the server in questions far away in a different country. Also posting my diagnostics diagnostics-20221013-1053.zip
October 13, 20223 yr Author Solution This is driving me nuts and I think I have figured it out. At least I can get it work, but maybe I do not understand all the implications.  In the file /etc/wireguard/wg0.conf there is this line PostUp=ip -4 route add 192.168.100.0/24 via 192.168.100.1 dev  table 200  The same line that throws the error in wg-quick.log [#] ip -4 route add 192.168.100.0/24 via 192.168.100.1 dev  table 200 Error: either "to" is duplicate, or "200" is a garbage.  I refreched some knowledge about routing in Linux and I don't think the "dev " (notice the extra space) should be there. If I edit /etc/wireguard/wg0.conf and remove "dev " the tunnel can stay started and there is no error in wg-quick.log PostUp=ip -4 route add 192.168.100.0/24 via 192.168.100.1 table 200  This solution works and are stable for starting/stopping the tunnel. If I however add a peer or update a peer, the config is overwritten with the "dev " in the line and it needs to be edited again.  I have only tested this for "remote access to server" and have not changed anything from default values.  Why do I have this problem? I saw the upgrade note that you should refresh Wireguard tunnels to get it to work. So there is an issue with Wireguard, but somehow my system/setup is different.  I'll guess this is a workarond for now and maybe someone else can give a +1 if they had the same?
October 18, 20223 yr I have the same problem. I have even deleted the tunnel/peers and started from scratch. The workaround works. WG on Unraid is not very stable...
October 20, 20223 yr Author On 10/18/2022 at 8:32 PM, ercoppa said: I have the same problem. I have even deleted the tunnel/peers and started from scratch. The workaround works. WG on Unraid is not very stable... Well, when WG is running it is very stable. Extremely so imho. To me it seems the error lies with UnRAID's WG config implementation in 6.11.1. I think it's an easy fix but we prabably need to wait for 6.11.2 for that. The workaround is stable
October 20, 20223 yr There are several threads about this, I've been responding in this one: Â Â https://forums.unraid.net/topic/129257-6111-vpn-tunnel-failing/#comment-1181934 Â I believe I have what we need to track down the issue and get it resolved in the next release. Thanks!
October 20, 20223 yr @tetrapod @ercoppa @ChatNoir please see the fix here:   https://forums.unraid.net/topic/129257-6111-vpn-tunnel-failing/page/2/#comment-1182737 Â
October 21, 20223 yr Author 13 hours ago, ljm42 said: @tetrapod @ercoppa @ChatNoir please see the fix here:   https://forums.unraid.net/topic/129257-6111-vpn-tunnel-failing/page/2/#comment-1182737  Thank you for providing a solution. However, I applied this without thinking :-$ Not your fault, but I think I cut of the branch I'm sitting on. Got to the [Apply] and then lost communication with the server that is four country boarders north of me. I have a remote access to monitor and power button through a PiKVM, but I'm afraid to order a reboot. Do not know what I could have changed to make this happen?!? I shouldn't have changed anything when hitting [Apply]. But maybe I did? I (think) I chnged one of the top Yes/No switches - something "* binding" - from Yes to No and then back again befor hitting [Apply]. Could that have changes something else? Can I check a settings file somewhere?
October 21, 20223 yr 3 hours ago, tetrapod said: Thank you for providing a solution. However, I applied this without thinking :-$ Not your fault, but I think I cut of the branch I'm sitting on. Got to the [Apply] and then lost communication with the server that is four country boarders north of me. I have a remote access to monitor and power button through a PiKVM, but I'm afraid to order a reboot. Do not know what I could have changed to make this happen?!? I shouldn't have changed anything when hitting [Apply]. But maybe I did? I (think) I chnged one of the top Yes/No switches - something "* binding" - from Yes to No and then back again befor hitting [Apply]. Could that have changes something else? Can I check a settings file somewhere? Â The good news is that with the PiKVM you'll always have access to the console, so if it doesn't join the network properly after rebooting you can login, type "rm /boot/config/network.cfg" and then type "reboot", Unraid will generate a default networking config when it boots back up. Assuming you have DHCP you should be good at that point, although you'll need to make a dummy change and hit Apply again to get past the bug we're talking about here. Â Still, let's see if anyone else in the community has a better idea on how to recover. Â
October 21, 20223 yr Author 4 hours ago, tetrapod said: Thank you for providing a solution. However, I applied this without thinking :-$ Not your fault, but I think I cut of the branch I'm sitting on. Got to the [Apply] and then lost communication with the server that is four country boarders north of me. I have a remote access to monitor and power button through a PiKVM, but I'm afraid to order a reboot. Do not know what I could have changed to make this happen?!? I shouldn't have changed anything when hitting [Apply]. But maybe I did? I (think) I chnged one of the top Yes/No switches - something "* binding" - from Yes to No and then back again befor hitting [Apply]. Could that have changes something else? Can I check a settings file somewhere? Back up again thanks to reboot via PiKVM (prais be it's name). Waiting for 6.11.2 before I touch anything more with network involved. VPN was now able to start without any changes to the config file. Marking the issue as solved
October 21, 20223 yr 2 hours ago, tetrapod said: Back up again thanks to reboot via PiKVM (prais be it's name)  I really do like the PiKVM, great little box. Glad you are back up and running!
October 24, 20223 yr Author On 10/21/2022 at 5:53 PM, ljm42 said: ...type "rm /boot/config/network.cfg" and then type "reboot", Unraid will generate a default networking config when it boots back up. Assuming you have DHCP you should be good at that point... Â That's really good to know - thank you.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.