我正在尝试在 Ubuntu 22.04 上创建两个独立的 VPN,但不确定是否可行。
使用命令“vpn_service connect”在终端上初始化 VPN #1。这将创建一个以 vpn_service 为名的接口,IP 为 10.5.0.2。
VPN #2 使用 GUI 客户端初始化。我选择服务器并尝试连接。无论使用哪种协议(UDP、TCP、Wireguard),都无法连接。
(我不想有浏览器扩展。我希望 VPN #2 能够隧道传输所有流量)。
VPN #2 尝试在 wlp0s20f3 上创建一个接口,该接口是标准无线接口(因此与 VPN #1 无关)。
我做错了什么?或者有更好的方法来实现这一点?
我已经为这些测试禁用了“ufw”防火墙。
2023.04.01 23:57:06 Routes, add 217.138.xxx.xxx/32 for interface "wlp0s20f3", already exists.
. 2023.04.01 23:57:06 - OpenVPN > OpenVPN 2.5.5 x86_64-pc-linux-gnu [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] built on Jul 14 2022
. 2023.04.01 23:57:06 - OpenVPN > library versions: OpenSSL 3.0.2 15 Mar 2022, LZO 2.10
. 2023.04.01 23:57:06 - OpenVPN > Outgoing Control Channel Encryption: Cipher 'AES-256-CTR' initialized with 256 bit key
. 2023.04.01 23:57:06 - OpenVPN > Outgoing Control Channel Encryption: Using 256 bit message hash 'SHA256' for HMAC authentication
. 2023.04.01 23:57:06 - OpenVPN > Incoming Control Channel Encryption: Cipher 'AES-256-CTR' initialized with 256 bit key
. 2023.04.01 23:57:06 - OpenVPN > Incoming Control Channel Encryption: Using 256 bit message hash 'SHA256' for HMAC authentication
. 2023.04.01 23:57:06 - OpenVPN > TCP/UDP: Preserving recently used remote address: [AF_INET]217.138.xxx.xxx:443
. 2023.04.01 23:57:06 - OpenVPN > Socket Buffers: R=[212992->212992] S=[212992->212992]
. 2023.04.01 23:57:06 - OpenVPN > UDP link local: (not bound)
. 2023.04.01 23:57:06 - OpenVPN > UDP link remote: [AF_INET]217.138.xxx.xxx:443
. 2023.04.01 23:57:06 - OpenVPN > write UDP: Operation not permitted (code=1)
. 2023.04.01 23:57:08 - OpenVPN > write UDP: Operation not permitted (code=1)
. 2023.04.01 23:57:13 - OpenVPN > write UDP: Operation not permitted (code=1)
. 2023.04.01 23:57:38 - Above log line repeated 2 times more
. 2023.04.01 23:57:38 - OpenVPN > [UNDEF] Inactivity timeout (--ping-exit), exiting
. 2023.04.01 23:57:38 - OpenVPN > SIGTERM received, sending exit notification to peer
. 2023.04.01 23:57:43 - OpenVPN > SIGTERM[soft,exit-with-notification] received, process exiting
! 2023.04.01 23:57:43 - Disconnecting