I
I
Ivan Ivanov2020-12-04 14:15:08
Network routing
Ivan Ivanov, 2020-12-04 14:15:08

How to set up static routing?

There are two objects located in different cities. It is necessary to configure the network between them so that the devices see each other in the Windows Network Neighborhood as if they are on the same network.
At object A, the network is 192.168.0.1/24 and object B is 192.168.1.0/24. Both networks are connected to the Internet through routers that have dedicated IP addresses IP_A and IP_B.
I suppose that I need to register a static route for the network at object A

route -p add 192.168.1.0 mask 255.255.255.0 IP_B

and for the network at object B

route -p add 192.168.0.1 mask 255.255.255.0 IP_A

and everything should work or am I missing something?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
N
Nird, 2020-12-04
@Nird_o

Opening the balls to the outside by a white IP address is not the best idea. You need a VPN. And in terms of routing, think in the right direction. Configure routing based on the VPN server.

A
Akina, 2020-12-04
@Akina

Both networks are connected to the Internet through routers that have dedicated IP addresses IP_A and IP_B.

See if both routers (optimum - if they are also the same model, or at least one vendor) can establish a VPN connection.
If you can, set it up. Then on client computers nothing needs to be configured to provide access. If not, it's easier to change the hardware (if they don't know how, then it's some kind of cheap SOHO). And then - to configure VPN.
There will be certain difficulties if the external address of both networks is dynamic. At least one will have to make a static white IP.
But with visibility in a networked environment is more difficult. Depends on the presence of a domain in each of the networks. If yes, establish trust. If not, at least one network will have to raise a WINS server and configure all stations to it.
And for simple access by NetBIOS name without visibility in the network environment, it is enough to make the necessary entries in LMHOSTS.

D
Drno, 2020-12-04
@Drno

As they wrote above - make a VPN between them, make routes into the tunnel already

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question