Answer the question
In order to leave comments, you need to log in
Routing between 2 interfaces using route?
Hello.
I have a Raspberry Pi with two interfaces eth0 and wlan0 . A DHCP server (isc-dhcp-server) is installed on it, eth0 is specified as an interface on the DHCP server . Through wlan0 it is connected to WiFi and has Internet access. The scheme is as follows:
On the Raspberry Pi itself, there is Internet access in the console, but the PC does not. But if you run the command:
# iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE
default via 192.168.0.1 dev wlan0
Answer the question
In order to leave comments, you need to log in
Without Nat? No way.
Computers on the Internet know nothing about your internal network and your routing.
It's easier to remember the rule in iptables.
iptables-save > /etc/iptables/iptables.rules this command will save the active configuration to a file.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question