R
R
Raul Duke2020-10-12 20:21:14
VPN
Raul Duke, 2020-10-12 20:21:14

How to set up routing in windows 10 for two providers?

Two Internet providers, two routers. Target PC with windows 10, with two network adapters on subnets 192.168.0.0/24 and 192.168.100.0/24 for each of the providers.
Through one provider, you need to periodically raise the VPN tunnel (PPTP) (at the moment - using the built-in tools of Windows 10), through the second provider - always access the Internet. However, if you set the second provider as the main system gateway, then the VPN connection also tries to connect through it (and it needs to be through the first one). At the moment, you have to constantly change the main gateway back and forth, which, of course, is completely inconvenient.
How to set up routing and is it possible when using the built-in PPTP client of WIndows 10? Ideally, the PPTP connection (through the required provider) should be raised automatically when the OS boots)

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dmitry, 2020-10-12
@dushako

Write a static route to the vpn server through the desired router

A
Artem @Jump, 2020-10-12
curated by the

then the VPN connection also tries to connect through it (and it needs to be through the first one)
You need to write a route.
The logic is simple - any packet goes clearly along a given route, if there is no special route - it goes to the default gateway, and it already understands what to do with it.
Just add a route - specify the target address or network and gateway for packets following this address and a metric to manage priorities.
Ideally, the PPTP connection (through the required provider) should be raised automatically when the OS boots)
Yes, no problem - for such purposes there is a task scheduler.
Add a task by trigger - turn on the computer
rasdial [Имя_VPN_подключения]  [имя_пользователя] [пароль]

How to set up routing
In windows, see the help for the route command

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question