A message for Linux.com registered users: We are in the process of making changes to the Linux forums. Starting Monday, 8/13/18 at 6:00 PM PT, you will be unable to access the forums. They will re-launch as soon as possible on Wednesday, 8/15/18 with new features and improved functionality. Thank you for your patience and stay tuned for the new improved forums.
IP Table with single interface
I need to set up Linux to forward traffic for specific hosts. My VM only has one NIC. I’m struggling to get IPTables to work. Is it because of the single NIC? Is it just plain easier to do with 2 NIC’s?
when I try to SSH or HTTP, or * to 10.0.0.7, the traffic goes to 10.0.0.5 (router takes care of this). Have 10.0.0.5 forward the traffic to 10.0.0.7.
What I ran:
iptables -A FORWARD -s 0/0 -i eth0 -d 10.0.0.7 -o eth0 -p TCP -j ACCEPT