[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: port forwarding configuration [solve]



hi,

i solved it :))
actually, there are 2 ways :
first : install a local dns server...
second : add all your domain and sub domain in your /etc/hosts

ex :
you have :
www.domain.org
sub.domain.org
sub2.domain.org

if the ip of your server is 192.168.0.1

you have to add in the /etc/hosts file this line :

192.168.0.1    www.domain.org
192.168.0.1    sub.domain.org
192.168.0.1    sub2.domain.org

hope that can help somebody

Yoann

Shestopyorov D.G. wrote:

On Sun, 23 Mar 2003 20:23:23 +0100
yoann <debian-yoann@ifrance.com> wrote:

Hi,

I have a small network at home :
gateway + server (web+ftp) + laptop

I have a domaine name and use port forwarding with iptables for the ftp
and web server :

iptables -A PREROUTING -t nat -p tcp -d my_domaine_name --dport 80 -j
DNAT --to 192.168.0.1:80

iptables -A OUTPUT -t nat -p tcp -d my_domaine_name --dport 80 -j DNAT
--to 192.168.0.1:80

iptables -A PREROUTING -t nat -p tcp -d my_domaine_name --dport 21 -j
DNAT --to 192.168.0.1:21
echo -n $DEBUG

iptables -A OUTPUT -t nat -p tcp -d my_domaine_name --dport 21 -j DNAT
--to 192.168.0.1:21

from outside everything work well but if I try to connecte from my local
network on my domain, I can't access to my server.

there is a time out. nothing appear in the firewall log and wer server log

for the ftp it's not a problem but for the web server it is.
I have sub domain and I can access only with my domain name and not
directly with the local name for the server.

I haven't DNS on my network

any idea ?

thanks for you help

Yoann


I had the same problem and i didn't solve it.



_____________________________________________________________________
GRAND JEU SMS : Pour gagner un NOKIA 7650, envoyez le mot IF au 61321
(prix d'un SMS + 0.35 euro). Un SMS vous dira si vous avez gagné.
Règlement : http://www.ifrance.com/_reloc/sign.sms



Reply to: