2 [ -e /etc
/config
/network
] && exit 0
7 if grep 'mtd0: 00060000' /proc
/mtd
2>&- >&-; then
11 strings /dev
/mtdblock
/3
15 if (c[name] != "") print name "=\"" c[name] "\""
21 c["lan_ifnames"]="vlan0 eth1"
23 c["wan_ifname"]="vlan1"
24 c["vlan0ports"]="1 2 3 4 5*"
28 ($1 == "boardnum") || ($1 == "boardtype") || ($1 == "boardflags") {
34 if (nvram["boardtype"] == "bcm94710dev") {
36 if (nvram["boardnum"] == "42") {
39 c["lan_ifnames"]="vlan2 eth2"
43 if (nvram["boardnum"] == "asusX") {
44 c["lan_ifnames"]="eth0 eth1 eth2" # FIXME
48 if (nvram["boardtype"] == "wgt634u") {
49 c["vlan0ports"] = "0 1 2 3 5*"
50 c["vlan1ports"] = "4 5"
51 c["lan_ifnames"] = "vlan0 ath0"
53 if ((nvram["boardtype"] == "0x0467") || (nvram["boardtype"] == "0x042f")) {
54 c["vlan0ports"] = "0 1 2 3 5*"
55 c["vlan1ports"] = "4 5"
59 if ((nvram["boardnum"] == "2") || \
60 (nvram["boardnum"] == "1024")) {
61 c["lan_ifnames"]="eth0 eth1"
65 print "#### VLAN configuration "
66 print "vlan0hwname=et0"
67 print "vlan1hwname=et0"
73 print "#### LAN configuration"
74 print "lan_proto=\"static\""
77 print "lan_ipaddr=\"192.168.1.1\""
78 print "lan_netmask=\"255.255.255.0\""
79 print "# lan_dns=\"192.168.1.1\""
80 print "# lan_gateway=\"192.168.1.1\""
85 print "#### WAN configuration"
86 print "# wan_proto: WAN protocol, available protocols:"
87 print "# none: disable"
89 print "# static: Static IP"
90 print "# pppoe: PPP over Ethernet"
91 print "# pptp: Point-to-Point tunneling Protocol"
92 print "# for pppoe and pptp you need to use wan_ifname=\"ppp0\""
94 print "wan_proto=dhcp"
96 print "wan_device=\"" c["wan_ifname"] "\""
97 print "# wan_ipaddr=\"192.168.0.2\""
98 print "# wan_netmask=\"255.255.255.0\""
99 print "# wan_gateway=\"192.168.0.1\""
100 print "# wan_dns=\"192.168.0.1\""
102 print "## PPP over Ethernet and PPTP"
103 print "# wan_ifname=\"ppp0\""
104 print "# ppp_username=\"my_username\""
105 print "# ppp_passwd=\"my_password\""
106 print "# pptp_server_ip=\"192.168.0.1\""
108 ' > /etc
/config
/network
This page took 0.056033 seconds and 5 git commands to generate.