Answer the question
In order to leave comments, you need to log in
Why does the Internet disappear when connecting to OpenVPN?
Set up OpenVPN as in this video . I also wrote push "redirect-gateway def1 bypass-dhcp" on the server to change the ip-address in the client to the server, but nothing happens ...
More specifically, the Internet just disappeared on my client and that's it. How can this be fixed?
Server:
dev-node "ServerVPN"
mode server
port 12345
proto tcp4-server
dev tun
tls-server
tls-auth "C:\\Program Files\\OpenVPN\\easy-rsa\\keys\\ta.key" 0
tun-mtu 1500
tun-mtu-extra 32
mssfix 1450
ca "C:\\Program Files\\OpenVPN\\easy-rsa\\keys\\ca.crt"
cert "C:\\Program Files\\OpenVPN\\easy-rsa\\keys\\ServerVPN.crt"
key "C:\\Program Files\\OpenVPN\\easy-rsa\\keys\\ServerVPN.key"
dh "C:\\Program Files\\OpenVPN\\easy-rsa\\keys\\dh2048.pem"
server 10.10.10.0 255.255.255.0
client-to-client
keepalive 10 120
cipher AES-128-CBC
comp-lzo
persist-key
persist-tun
client-config-dir "C:\\Program Files\\OpenVPN\\config"
verb 3
route-delay 5
route-method exe
push "route 192.168.0.0 255.255.255.0"
push "redirect-gateway def1 bypass-dhcp"
route 192.168.182.0 255.255.255.0
remote 192.168.1.1 ip для примера
client
port 12345
proto tcp4-client
dev tun
tls-client
tls-auth "C:\\Program Files\\OpenVPN\\config\\ta.key" 1
remote-cert-tls server
tun-mtu 1500
tun-mtu-extra 32
mssfix 1450
ca "C:\\Program Files\\OpenVPN\\config\\ca.crt"
cert "C:\\Program Files\\OpenVPN\\config\\ClientVPN.crt"
key "C:\\Program Files\\OpenVPN\\config\\ClientVPN.key"
cipher AES-128-CBC
comp-lzo
persist-key
persist-tun
verb 3
mute 20
===========================================================================
Список интерфейсов
15...00 ff cb c6 07 3a ......TAP-Windows Adapter V9
14...d8 f2 ca c4 2e 9a ......Microsoft Wi-Fi Direct Virtual Adapter
2...da f2 ca c4 2e 99 ......Microsoft Wi-Fi Direct Virtual Adapter #2
10...d8 f2 ca c4 2e 99 ......Intel(R) Wireless-AC 9560 160MHz
18...d8 f2 ca c4 2e 9d ......Bluetooth Device (Personal Area Network)
1...........................Software Loopback Interface 1
===========================================================================
IPv4 таблица маршрута
===========================================================================
Активные маршруты:
Сетевой адрес Маска сети Адрес шлюза Интерфейс Метрика
0.0.0.0 0.0.0.0 192.168.1.1 192.168.1.122 35
0.0.0.0 128.0.0.0 10.10.10.5 10.10.10.6 281
10.10.10.0 255.255.255.0 10.10.10.5 10.10.10.6 281
10.10.10.4 255.255.255.252 On-link 10.10.10.6 281
10.10.10.6 255.255.255.255 On-link 10.10.10.6 281
10.10.10.7 255.255.255.255 On-link 10.10.10.6 281
127.0.0.0 255.0.0.0 On-link 127.0.0.1 331
127.0.0.1 255.255.255.255 On-link 127.0.0.1 331
127.255.255.255 255.255.255.255 On-link 127.0.0.1 331
128.0.0.0 128.0.0.0 10.10.10.5 10.10.10.6 281
178.44.196.105 255.255.255.255 192.168.1.1 192.168.1.122 291
192.168.0.0 255.255.255.0 10.10.10.5 10.10.10.6 281
192.168.1.0 255.255.255.0 On-link 192.168.1.122 291
192.168.1.122 255.255.255.255 On-link 192.168.1.122 291
192.168.1.255 255.255.255.255 On-link 192.168.1.122 291
224.0.0.0 240.0.0.0 On-link 127.0.0.1 331
224.0.0.0 240.0.0.0 On-link 10.10.10.6 281
224.0.0.0 240.0.0.0 On-link 192.168.1.122 291
255.255.255.255 255.255.255.255 On-link 127.0.0.1 331
255.255.255.255 255.255.255.255 On-link 10.10.10.6 281
255.255.255.255 255.255.255.255 On-link 192.168.1.122 291
===========================================================================
Постоянные маршруты:
Отсутствует
IPv6 таблица маршрута
===========================================================================
Активные маршруты:
Метрика Сетевой адрес Шлюз
1 331 ::1/128 On-link
15 281 fe80::/64 On-link
10 291 fe80::/64 On-link
15 281 fe80::5105:7c9d:a5c0:c8dc/128
On-link
10 291 fe80::e1e3:a6c6:ab15:60c8/128
On-link
1 331 ff00::/8 On-link
15 281 ff00::/8 On-link
10 291 ff00::/8 On-link
===========================================================================
Постоянные маршруты:
Отсутствует
===========================================================================
Список интерфейсов
15...00 ff cb c6 07 3a ......TAP-Windows Adapter V9
14...d8 f2 ca c4 2e 9a ......Microsoft Wi-Fi Direct Virtual Adapter
2...da f2 ca c4 2e 99 ......Microsoft Wi-Fi Direct Virtual Adapter #2
10...d8 f2 ca c4 2e 99 ......Intel(R) Wireless-AC 9560 160MHz
18...d8 f2 ca c4 2e 9d ......Bluetooth Device (Personal Area Network)
1...........................Software Loopback Interface 1
===========================================================================
IPv4 таблица маршрута
===========================================================================
Активные маршруты:
Сетевой адрес Маска сети Адрес шлюза Интерфейс Метрика
0.0.0.0 0.0.0.0 192.168.1.1 192.168.1.122 35
127.0.0.0 255.0.0.0 On-link 127.0.0.1 331
127.0.0.1 255.255.255.255 On-link 127.0.0.1 331
127.255.255.255 255.255.255.255 On-link 127.0.0.1 331
192.168.1.0 255.255.255.0 On-link 192.168.1.122 291
192.168.1.122 255.255.255.255 On-link 192.168.1.122 291
192.168.1.255 255.255.255.255 On-link 192.168.1.122 291
224.0.0.0 240.0.0.0 On-link 127.0.0.1 331
224.0.0.0 240.0.0.0 On-link 192.168.1.122 291
255.255.255.255 255.255.255.255 On-link 127.0.0.1 331
255.255.255.255 255.255.255.255 On-link 192.168.1.122 291
===========================================================================
Постоянные маршруты:
Отсутствует
IPv6 таблица маршрута
===========================================================================
Активные маршруты:
Метрика Сетевой адрес Шлюз
1 331 ::1/128 On-link
10 291 fe80::/64 On-link
10 291 fe80::e1e3:a6c6:ab15:60c8/128
On-link
1 331 ff00::/8 On-link
10 291 ff00::/8 On-link
===========================================================================
Постоянные маршруты:
Отсутствует
Answer the question
In order to leave comments, you need to log in
Typical mistake. The VPN server has set itself as the default route for the client. And now all packets on the Internet go to the VPN server.
The option
It does not do what you think is to blame.
Just comment out this option and restart the server.
push "redirect-gateway def1 bypass-dhcp"
On the server in the registry, you need to
HKLM\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\IPEnableRouter
set to 1. Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question