gleilson
(usa Ubuntu)
Enviado em 30/10/2012 - 11:00h
#INTERFACES
auto lo
iface lo inet loopback
#INTERNET
auto eth0
iface eth0 inet static
address 192.168.0.1
netmask 255.255.255.0
network 192.168.0.0
#REDE LOCAL
auto eth1
iface eth1 inet static
address 10.0.0.1
netmask 255.0.0.0
network 10.0.0.0
#rc.local
echo 1 > /proc/sys/net/ipv4/ip_forward
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
iptables -t nat -A PREROUTING -i eth1 -p tcp --dport 80 -j REDIRECT --to-port 3128
#DHCP
subnet 10.0.0.0 netmask 255.0.0.0 {
range 10.0.0.2 10.0.0.253;
option routers 192.168.0.1;
option broadcast-address 10.255.255.255;
option domain-name-servers 8.8.8.8, 8.8.4.4;
default-lease-time 600;
max-lease-time 7200;
}