S
S
Sa1ta2021-09-27 15:21:15
linux
Sa1ta, 2021-09-27 15:21:15

How to properly set up port forwarding in Ubuntu?

Port forwarding.
3 computers are participating (windows, Ubuntu server, Ubuntu client).
There is an apache server on the ubuntu server, on the ubuntu client machine do port forwarding using iptables, so that when you write the ip address of the ubuntu client in the browser on windows, it transfers it to the ubuntu server.
What is the correct way to set up iptables on the client for this?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Dmitriev, 2021-09-27
@Sa1ta

1. check if IPv4 FORWARD is open in the kernel.
2. Google "iptables dnat", make the correct rule and run the command.
3. Ensure that the rule is saved and applied when the server is restarted.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question