Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win


Network Config with my DSL to Host Site

Posted on 2003-11-21
Medium Priority
Last Modified: 2010-05-18
Hello Experts!

I have been trying to configure my servers but no luck...
My problem goes this way. I have acquired a DSL to an ISP with a /29 IP block. I setup a firewall/gateway with a linux rh9 server with 2 nic. with 1 nic pointing at the net and one on my Lan. I have added an additional server which I intent to be my web server. How will I add my additional server to my network considering that it must have a routable ip, the same with my Internet gateway?

I tried to setup alias on my Lan's Interface but I am not able to do it? Should I do NAT on my firewall? Im not so familiar with NAT?

What would be the best thing to do?
Thank you for your advance answeres.

{{email addr removed by jmcg during cleanup}}
Question by:elmerph
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
LVL 40

Accepted Solution

jlevie earned 1000 total points
ID: 9801728
The easiest solution would be to set up static NAT translations for each server on the inside of your firewall.  You need to create an IP alias on your outside NIC for each of the routable IP's that will be statically mapped and then use a pair of rules or each NAT'ed IP, something like:

# To Statically NAT an outside IP ( to an inside IP ( you'd
# do something like:
iptables -t nat -A PREROUTING -i $OUTSIDE -d -j DNAT --to-destination
iptables -t nat -A POSTROUTING -i $OUTSIDE -s -j SNAT --to-source

The usual rules about allowing inbound connections also apply.

Author Comment

ID: 9801807
how will i test it that way?

can i do this..-> create an alias on my LAN Interface with an ip the same ipblock of INTERNET Interface? then change the ip of my web machine to the same block ?

LVL 40

Expert Comment

ID: 9810357
From outside you'd obviously just go to the routable IP of your web server, but from inside of the firewall you'd us the inside IP of the server. If you are using name based virtual hosts of the web server you'll need to either have a local DNS that equates the host name to private IP of the server or create hosts file records on each of the systems.

Assisted Solution

Netelligen earned 1000 total points
ID: 9835516
A great source of information on this can be found at www.shorewall.net.

Shorewall is a set of IP Tables wrapper scripts that is the easiest and most flexible that I have found... but the best part of this is the excellent documentation that this site provides.

Hope this helps.


Expert Comment

ID: 12210621
you can run the webserver on a private ip inside your network.
Then set up the gateway with Shorewall to NAT any traffic going out and to DNAT any incoming port 80 requests to your webserver private IP.

This is VERY easy if you are using webmin.  :P

let me know if you need more info on configuring NAT/DNAT...
jlevie's solution also sounds appropriate.


Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question