You should first recognize that this chapter covers advanced router configuration. If your Linux-based router delivers so little traffic that it has no trouble keeping up with the load, and if the router's configuration is simple and static so that it doesn't need to reconfigure itself to work with other routers, then there's no point in using the options described in this chapter. You can simply enable router features by configuring two network cards and enabling routing between them by typing the following command: # echo "1" > /proc/sys/net/ipv4/ip_forward This command, in conjunction with an appropriate routing table configuration for multiple networks, as described in Chapter 2, TCP/IP Network Configuration, is enough to turn a Linux computer into a router. This configuration may work well enough for many networks. NOTE
One type of advanced router configuration described in this chapter, in the "Advanced Kernel Options" and "Using iproute2" sections, relates to modifications of the way Linux decides to route packets based on some feature of the packets, such as their origins, destinations, or protocol type. These options can influence how responsive the Internet appears to be, because you might give priority to packets associated with interactive protocols, or favor traffic from certain computers. Such configurations are most often used on heavily loaded dedicated routers. The second type of advanced router configuration described in this chapter is routing protocols. These are protocols you can use to communicate with other routers. The servers that implement these protocols allow your system to dynamically update its routing table to reflect the best path for packets to travel so that the packets can reach their destinations most quickly. Such protocols can enhance the performance of a network that uses them, but they're most useful for a router that has several network interfaces that reach the Internet. If the router has just one link to the Internet, that link can't be changed in any meaningful way, and so there's no point to running a routing protocol on the server, because the protocol will have no effect on the router's routing table. |