LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 03-18-2007, 11:08 AM   #1
numbers1thru9
LQ Newbie
 
Registered: Nov 2006
Distribution: Debian and Ubuntu
Posts: 18

Rep: Reputation: 0
linux server as a router


Hey everyone, I have Debian sarge installed on a system as a server with no GUI. I have already configured shorewall and dhcp and both are working for me, what I want to do now is make the server function as a router so i can replace my current router. Does anyone know what i need to do or know of a goog guide for making it a router? any help is appreciated.
 
Old 03-18-2007, 11:47 AM   #2
Brian1
LQ Guru
 
Registered: Jan 2003
Location: Seymour, Indiana
Distribution: Distribution: RHEL 5 with Pieces of this and that. Kernel 2.6.23.1, KDE 3.5.8 and KDE 4.0 beta, Plu
Posts: 5,700

Rep: Reputation: 65
Does the machine already have two nics installed and if so how are they configured.
I have never used shorewall but I would think it would have the ability to setup that portion for you. Might read the manual docs and faqs.

I am only familair with using a script that can be gerneated from this site by answering the questions. http://easyfwgen.morizot.net/gen/
If you go this route then shorewall is not needed.

Brian
 
Old 03-19-2007, 06:08 AM   #3
numbers1thru9
LQ Newbie
 
Registered: Nov 2006
Distribution: Debian and Ubuntu
Posts: 18

Original Poster
Rep: Reputation: 0
yes, there are two nics installed, eth0 is set for dhcp since I am on a cable connection and need dhcp for the router. eth1 is set to static as it is the internal nic for my network. I would like to use shorewall because I have learned how to configure the rules and policies but I will have to do some searching of its man pages to see if it actually sets up routing as well or not.
 
Old 03-22-2007, 05:04 AM   #4
mitzadej
LQ Newbie
 
Registered: Jan 2005
Location: romania
Distribution: Debian
Posts: 12

Rep: Reputation: 0
if the machine already has 2 nic`s , i presume that you want to use the it for NAT(network address translation) masquerade
the command is : iptables -t nat -I POSTROUTING -o eth0 -j MASQUERADE
 
Old 03-23-2007, 12:06 PM   #5
numbers1thru9
LQ Newbie
 
Registered: Nov 2006
Distribution: Debian and Ubuntu
Posts: 18

Original Poster
Rep: Reputation: 0
shorewall has a masquerading file that is supposed to setup nat which is what i want to use it for. does this work or do i still need to run that command? also i have found a setting that it says that I need to set in the /etc/sysctl.conf file to say net.ipv4.ip_foward=1 is this true? and if so do i type it as above or do i type it as net/ipv4/ip_foward=1? I can get a dhcp address from the server i just cant get to the internet
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Linux Server on a Linksys router Vexlith Linux - Hardware 5 12-04-2006 08:28 AM
VPN Question Win98->internet->Router->Linux VPN Server->Win2k Server patrickrea Linux - Networking 1 08-10-2004 02:09 AM
Linux server, Win XP and Router petko Linux - Networking 1 05-05-2004 08:24 AM
Linux based Router/Print Server pldobs Linux - Networking 1 12-26-2003 11:11 AM
Linux as DSL router which is better workstation or server? marvc Linux - General 6 03-03-2003 02:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 04:09 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration