Open jelbo opened 3 years ago
Please start the diagnostics by commenting out the PostUp
and PostDown
lines in wg0.conf and trying to run the interface manually by sudo wg-quick up wg0
.
That works. ip link
now adds
8: wg0: <POINTOPOINT,NOARP,UP,LOWER_UP> mtu 1420 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1
link/none
Routing table:
root@VirtualDSM:~# netstat -rt
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
default 172.27.1.1 0.0.0.0 UG 0 0 0 eth0
10.0.0.0 0.0.0.0 255.255.0.0 U 0 0 0 wg0
172.27.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
For what purpose in PostUp
are you manually adding routing?
For what purpose in
PostUp
are you manually adding routing?
I did that because I think it was needed on my DS713+ bare metal installation. I got it from this post.
I'm no networking expert by far, but you think it should work without? Can't get a connection from clients yet, but I haven't double checked all the steps again.
Remove the ; sleep 5; ip route add 10.0.0.0/16 dev %i
fragment from PostUp
and verify that the connection works.
That's what I did and it didn't work yet. No client communication to be seen from the server. I'll double check everything later when I have time and get back.
Good news, it works! Fantastic. It needed a little time I guess. Hope this helps others :) Thanks for your help again.
ip route add 10.0.0.0/16 dev wg0
fails with "RTNETLINK answers: File exists" because your interface config for wg0, already try to add this route.
Description I'm trying to get WireGuard running on VirtualSDM 7.0-41222. I'm almost there, thanks to @Matige's work, but the
wg0
interface refuses to come up.My goal is to be able to access LAN addresses remotely. In my case that's
172.27.1.0/24
.Steps to reproduce I'm running a self built .spk in my VirtualDSM running 7.0-41222, following these instructions. The package is running, kernel modules are loaded;
I created (by hand) a
/etc/wireguard/wg0.conf
and a client configuration (see bottom). I did the autostart step usingsudo wg-autostart enable wg0
and I also made a scheduled task that runs after booting and does this as root:After a reboot and waiting a bit,
sudo wg show
doesn't show anything.ip link
doesn't show me awg0
interface; only these:When I do a
sudo wg-quick up wg0
I get this:It seems to mean the route is already in the routing table. I checked that, but I don't see it:
So yeah, I'm pretty lost at this point.
Expected behavior It should just work™
Synology NAS model DS920+ running VirtualDSM
wg0.conf
Peer:
172.27.1.0/24
is my LAN subnet, in which both DSM and VirtualDSM live.