User:Stuart

From Openmoko

(Difference between revisions)
Jump to: navigation, search
m
Line 2: Line 2:
  
 
<pre>
 
<pre>
allow-hotplug eth7
 
        address 192.168.0.200
 
        netmask 255.255.255.252
 
up iptables -A POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE
 
up echo 1 > /proc/sys/net/ipv4/ip_forward
 
down iptables -D POSTROUTING -t nat -s 192.168.0.200/26  -j MASQUERADE
 
 
</pre>
 
</pre>
  
 
<pre>
 
<pre>
 
iptables -A FORWARD --in-interface eth7 -j ACCEPT
 
iptables -A FORWARD --in-interface eth7 -j ACCEPT
 +
allow-hotplug eth7
 +
iface eth7 inet static
 +
        address 192.168.0.200
 +
        netmask 255.255.255.252
 +
up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE
 +
up echo 1 > /proc/sys/net/ipv4/ip_forward
 +
down iptables -D POSTROUTING -t nat -s 192.168.0.200/30  -j MASQUERADE
 
iptables -A FORWARD --out-interface eth7 -j ACCEPT
 
iptables -A FORWARD --out-interface eth7 -j ACCEPT
 
</pre>
 
</pre>

Revision as of 11:40, 16 August 2009

The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have local nameserver.


iptables -A FORWARD --in-interface eth7 -j ACCEPT
allow-hotplug eth7
iface eth7 inet static
        address 192.168.0.200
        netmask 255.255.255.252
	up iptables -A POSTROUTING -t nat -s 192.168.0.200/30 -j MASQUERADE
	up echo 1 > /proc/sys/net/ipv4/ip_forward
	down iptables -D POSTROUTING -t nat -s 192.168.0.200/30  -j MASQUERADE
iptables -A FORWARD --out-interface eth7 -j ACCEPT

I partitioned by hand because of a problem with fdisk.

Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes
4 heads, 16 sectors/track, 62032 cylinders
Units = cylinders of 64 * 512 = 32768 bytes

        Device Boot      Start         End      Blocks  Id System
/dev/mmcblk0p1               1       57984     1855480  83 Linux
/dev/mmcblk0p2           57985       62032      129536  82 Linux swap



OSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all

Personal tools

The entry in /etc/network/interfaces. I use /26 as my home network is 192.168.0.0/24. I have local nameserver.

allow-hotplug eth7
        address 192.168.0.200
        netmask 255.255.255.252
	up iptables -A POSTROUTING -t nat -s 192.168.0.200/26 -j MASQUERADE
	up echo 1 > /proc/sys/net/ipv4/ip_forward
	down iptables -D POSTROUTING -t nat -s 192.168.0.200/26  -j MASQUERADE
iptables -A FORWARD --in-interface eth7 -j ACCEPT
iptables -A FORWARD --out-interface eth7 -j ACCEPT

I partitioned by hand because of a problem with fdisk.

Disk /dev/mmcblk0: 2032 MB, 2032664576 bytes
4 heads, 16 sectors/track, 62032 cylinders
Units = cylinders of 64 * 512 = 32768 bytes

        Device Boot      Start         End      Blocks  Id System
/dev/mmcblk0p1               1       57984     1855480  83 Linux
/dev/mmcblk0p2           57985       62032      129536  82 Linux swap



OSTNAME=stuart INST_MIRROR=http://ftp.fr.debian.org/debian QI=true LOCALEPURGE=true ./install.sh --no-partitioning --swap-size 128 --part1-fs ext3 --with-tasks GAMES,NET,WEB,WIFI,COM all