Multiple IP's on one Router

Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking
Author Message
clogue77
DD-WRT Novice


Joined: 26 Jul 2012
Posts: 1

PostPosted: Thu Jul 26, 2012 4:10    Post subject: Multiple IP's on one Router Reply with quote
I have followed the guide from http://www.dd-wrt.com/wiki/index.php/One-to-one_NAT to add an external IP address to an internal ip address. For some reason I can see everything within the network but I can't get out of the network on the PC I have assigned this address to.

Here is what I put in the ADMINISTRATION -> COMMAND section:

STARTUP

WANIF=`get_wanface`
ifconfig $WANIF:1 xx.xx.xx.181 netmask 255.255.255.252 broadcast xx.xx.xx.183

FIREWALL

# Save Firewall

# WAN .181 -> LAN .5
iptables -t nat -I PREROUTING -d xx.xx.xx.181 -j DNAT --to 192.168.1.5
iptables -t nat -I POSTROUTING -s 192.168.1.5 -j SNAT --to xx.xx.xx.181
iptables -I FORWARD -d 192.168.1.5 -p tcp --dport 21 -j ACCEPT
iptables -I FORWARD -d 192.168.1.5 -p tcp --dport 80 -j ACCEPT
iptables -I FORWARD -d 192.168.1.5 -p tcp --dport 5900 -j ACCEPT

Additional info: I am paying for a block of 4 IP addresses. One primary and 2 useable static addresses. The primary static is grabbed by the router's DHCP. I have assigned 192.168.1.5 to a static lease within the router. It will be hosting websites.

I am unsure of what I have done wrong here that I cannot get outside of the router from the webserver. When I delete all of the above settings from within the router's COMMAND section, it starts to connect with no issues. I am confident my issue is with the programming as I an quite the novice. Any help would be appreciated.

Also, this is a Netgear WNDR3700
Firmware Version DD-WRT v24-sp2 (06/08/12) std - build 19342
Sponsor
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Advanced Networking All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum