Solved

Making Linux 9 box act as a router

Posted on 2004-09-10
1
184 Views
Last Modified: 2010-04-22
hello,
    I want to act my machine which is installed linux RH9 as a router. with this i also want its nearer pc should make an entry in /proc/net/route as a gateway machine in my LAN. how can i do this?
0
Comment
Question by:b123coder
1 Comment
 
LVL 40

Accepted Solution

by:
jlevie earned 50 total points
ID: 12026934
> I want to act my machine which is installed linux RH9 as a router.

echo 1 > /proc/sys/net/ipv4/ip_forward

A persistant setting on this can be done by editing /etc/sysctl.conf and setting:

net.ipv4.ip_forward = 1

Note that a router implies two interfaces, one for the local network and one as a path to the next.

> i also want its nearer pc should make an entry in /proc/net/route as a gateway machine

Dynamically you can execute:

route add default gw ip-of-router

Or on a RedHat (or similar) edit /etc/sysconfig/network and set:

GATEWAY=ip-of-router

to set the gateway at boot.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
idM Identity Management in Red Hat 6 - setting up 9 269
How to use docker to run your java program on a linux box 9 115
bash file 10 67
rolling back version of firefox 1 32
Have you ever been frustrated by having to click seven times in order to retrieve a small bit of information from the web, always the same seven clicks, scrolling down and down until you reach your target? When you know the benefits of the command l…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…

733 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