Results 1 to 2 of 2
my plan for the network is:
LAN (10.0.0.0/24) > (eth0: 10.0.0.62) Debian Router (eth1: 172.16.0.62) > modem (172.16.0.1) > internet
I have change /proc/sys/net/ipv4/ip_forward from 0 to 1
and Routing ...
- 05-07-2009 #1Just Joined!
- Join Date
- May 2009
- Posts
- 1
Help me! config debian become to linux box routing
my plan for the network is:
LAN (10.0.0.0/24) > (eth0: 10.0.0.62) Debian Router (eth1: 172.16.0.62) > modem (172.16.0.1) > internet
I have change /proc/sys/net/ipv4/ip_forward from 0 to 1
and Routing table is:
But client not connect internet when use debian routerCode:Destination Gateway Genmask Flags Metric Ref Use Iface 172.16.0.62 * 255.255.255.255 UH 0 0 0 eth0 10.0.0.62 * 255.255.255.255 UH 0 0 0 eth0 10.0.0.0 10.0.0.62 255.255.255.0 UG 0 0 0 eth0 10.0.0.0 * 255.255.255.0 U 0 0 0 eth0 172.16.0.0 172.16.0.62 255.255.255.0 UG 0 0 0 eth1 172.16.0.0 * 255.255.255.0 U 0 0 0 eth1 default 172.16.0.1 0.0.0.0 UG 0 0 0 eth1
Help me config debian router. Thank pro so mush.
- 05-18-2009 #2Just Joined!
- Join Date
- May 2009
- Posts
- 2
Edit IP Address configuration at /etc/network/interfaces file :
Restart networking.Code:# The loopback network interface auto lo iface lo inet loopback # The primary network interface allow-hotplug eth1 auto eth1 iface eth1 inet static address 172.16.0.1 netmask 255.255.255.0 network 172.16.0.0 gateway 172.16.0.1 dns-nameservers 172.16.0.1 #change with your DNS from your ISP allow-hotplug eth0 auto eth0 iface eth0 inet static address 10.0.0.62 netmask 255.255.255.0 network 10.0.0.0
Then, install shorewall.Code:# /etc/init.d/networking restart
Edit /etc/default/shorewallCode:#apt-get install shorewall
Edit /etc/shorewall/zonesCode:startup=1
Edit /etc/shorewall/interfacesCode:loc ipv4 net ipv4
Edit /etc/shorewall/masqCode:net eth1 detect blacklist loc eth0 detect blacklist
Edit /etc/shorewall/policy . Close all port as default.Code:eth1 eth0
Edit /etc/shorewall/rules. Open port for special port and clients.Code:fw net REJECT fw loc REJECT loc fw REJECT loc net REJECT net all DROP all all DROP
Edit /etc/shorewall/routestoppedCode:ACCEPT loc net tcp 25,143,110,80,443 #smtp,imap,pop,http,https ACCEPT fw loc tcp 25,143,110,80,443 #smtp,imap,pop,http,https
Start ShorewallCode:eth0 - eth1 -
Edit DNS resolve /etc/resolv.confCode:# /etc/init.d/shorewall start
Code:nameserver 172.16.0.1 #change with your DNS from your ISP


Reply With Quote
