myfreax / myfreax-blog-issue

myfreax blog feedback
2 stars 0 forks source link

how-to-set-up-wireguard-vpn-on-ubuntu-20-04/ #6

Open utterances-bot opened 3 years ago

utterances-bot commented 3 years ago

如何在Ubuntu 20.04上设置WireGuard VPN

在本文中,我们将讨论如何在Ubuntu 20.04上设置充当VPN服务器的WireGuard VPN。 我们还将向您展示如何将WireGuard配置为客户端。 客户端的流量将通过Ubuntu 20.04服务器路由

https://www.myfreax.com/how-to-set-up-wireguard-vpn-on-ubuntu-20-04/

psyvirgin commented 3 years ago

在启动网络的时候出现以下错误,系统Ubuntu20.04 前面的代码都是复制的,这个怎样解决?

wg-quick up wg0

[#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 Key is not the correct length or format: `SERVER_PRIVATE_KEY' Configuration parsing error [#] ip link delete dev wg0

myfreax commented 3 years ago

@psyvirgin 记得修改你的 /etc/wireguard/wg0.conf

[Interface]
Address = 10.0.0.1/24
SaveConfig = true
ListenPort = 51820
PrivateKey =  你的private key 来自 cat /etc/wireguard/privatekey