V
V
virus1x2021-05-09 16:27:44
linux
virus1x, 2021-05-09 16:27:44

How to configure packet forwarding between interfaces?

there is a machine with two interfaces eth1 10.8.0.3/24 and eth0 192.168.1.1/22 enabled forwarding and configured static routes.
From the network 192.168.0.0 to the network 10.8.0.0 ping passes, but not from the network 10.8.0.0 to the network 192.168.0.0.
traceroute is stuck on 10.8.0.3.
iptables cleared.
Where to dig?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Dmitriev, 2021-05-10
@SignFinder

If you are just building a router between two networks to which it is physically connected, then you need to:
1. open FORWARD in the kernel (via sysctl)
2. check for the absence of firewall rules in the FORWARD chain, or add allowing ones.
3. client machines from both subnets must have routes to the opposite network. Either your router must be the default gateway of the clients must be selected, or static routes must be added to the opposite network.
You do not need to do any manipulations with routes on the router.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question