Photography web hosting - Configuring the Red Hat Linux router To configure

Configuring the Red Hat Linux router To configure your Red Hat Linux computer as a router, you need to have a few things in place. Here s what you need to do before you set up routing: Connect to your LAN. Add a network card and optionally set up the addresses (in /etc/hosts) to the computers on your LAN. (This is described in Chapter 15.) Connect to the Internet. Set up a dial-up or other type of connection from your Red Hat Linux computer to your ISP. This is described earlier in this chapter in the section on setting up outgoing PPP connections. Configure your Red Hat Linux computer as a router. This procedure is described in the rest of this section. The type of IP addresses you are using on your LAN will have an impact on a couple of steps in this procedure. Here are the differences: Private IP addresses If the computers on your LAN use private IP addresses (described in Chapter 15), you need to set up IP masquerading. Because those numbers are private, they must be hidden from the Internet when the Red Hat Linux router forwards their requests. Packets forwarded with masquerading look to the outside world as though they came from the Red Hat Linux computer forwarding the packets. Note IP addresses can be assigned statically (as described in Chapter 15) or using DHCP (as described in Chapter 23). Valid IP addresses If your LAN uses addresses that were officially assigned by your ISP or other registration authority, you don t need to do any special IP masquerading. With your Red Hat Linux computer s LAN and Internet interfaces in place, follow the procedure below to set up Red Hat Linux as a router: 1. Open the /etc/sysconfig/network file in a text editor as the root user. Then add either a default gateway or default gateway device as described below. Your default gateway is where IP addresses are sought that are not on any of your local interfaces. This is where you would identify your Internet connection. Here is how you choose which one to enter: Default Gateway If there is a static IP address you use to reach the Internet, enter that IP address here. For example, if your Internet connection went through a DSL modem on your LAN at address 192.168.0.1, you would enter that address as follows: GATEWAY=192.168.0.1
Note: In case you are looking for affordable webhost to host and run your servlet application check Vision servlet hosting services

Leave a Reply