I am trying to get a set of VMs to run SSH / Apache
I have VM 2010 at ip 10.0.20.10, it runs SSH & Apache on ports 22 and 80 respectively.
with the following:
iptables -t nat -A PREROUTING -p tcp -m tcp --dport 2010 -j DNAT --to 10.0.20.10:22
iptables -t nat -A PREROUTING -p tcp -m tcp --dport 2011 -j DNAT --to 10.0.20.10:80
I get this:
Chain PREROUTING (policy ACCEPT 72 packets, 9800 bytes)
pkts bytes target prot opt in out source destination
1 52 DNAT tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpt:2010 to:10.0.20.10:22
24 1216 DNAT tcp -- * * 0.0.0.0/0 0.0.0.0/0 tcp dpt:2011 to:10.0.20.10:80
Now, for some reason the connection doesn't go through with Apache, but works perfect with SSH.
Apache is running, but I can't even connect from the main node:
#telnet 10.0.20.10 80
Trying 10.0.20.10...
telnet: connect to address 10.0.20.10: Connection refused
telnet: Unable to connect to remote host: Connection refused
What should I look at?
[Updated on: Mon, 24 December 2007 08:26]
Report message to a moderator