Bit of openwrt Vlan newbie here
I want to create a single vlan on port 4, seemed straight forward...
default install then I add the following nvram vars & reboot then the router is not pingable
but with the right timing on the reset button it back in failsafe & I can unset the vars & reboot
nvram set vlan0ports="1 2 3 5*"
nvram set lan_ifnames="vlan0 eth1 vlan2"
nvram set lan2_hwaddr="00:0F:66:C5:D2:93"
nvram set lan2_iface="vlan2"
nvram set lan2_ifname="vlan2"
nvram set lan2_ifnames="vlan2"
nvram set lan2_ipaddr="192.168.2.2"
nvram set lan2_netmask="255.255.255.0"
nvram set lan2_proto="static"
nvram set vlan2ports="4 5"
nvram set vlan2hwname="et0"
nvram commit
interesting if i dont set lan2_ipaddr, lan2_netmask, lan2_proto
and just reboot then ifconfig vlan2 192.168.2.2 netmask 255.255.255.0
it still works the interface on vlan2 is self pingable
@OpenWrt:/# ping 192.168.2.2
PING 192.168.2.2 (192.168.2.2): 56 data bytes
64 bytes from 192.168.2.2: icmp_seq=0 ttl=64 time=1.7 ms
64 bytes from 192.168.2.2: icmp_seq=1 ttl=64 time=1.0 ms
but it will not ping another box on the same subnet conncted to port 4
and the route looks I think OK
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.2.0 * 255.255.255.0 U 0 0 0 vlan2
192.168.1.0 * 255.255.255.0 U 0 0 0 br0
24.68.216.0 * 255.255.252.0 U 0 0 0 vlan1
default 24.68.216.1 0.0.0.0 UG 0 0 0 vlan1
and the ifconfig
@OpenWrt:/# ifconfig
br0 Link encap:Ethernet HWaddr 00:0F:66:C5:D2:93
inet addr:192.168.1.254 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:270 errors:0 dropped:0 overruns:0 frame:0
TX packets:206 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:20439 (19.9 KiB) TX bytes:22233 (21.7 KiB)
eth0 Link encap:Ethernet HWaddr 00:0F:66:C5:D2:93
UP BROADCAST RUNNING PROMISC MULTICAST MTU:1500 Metric:1
RX packets:478 errors:0 dropped:0 overruns:0 frame:0
TX packets:446 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:48770 (47.6 KiB) TX bytes:49861 (48.6 KiB)
Interrupt:5 Base address:0x2000
eth1 Link encap:Ethernet HWaddr 00:0F:66:C5:D2:95
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:38
TX packets:3 errors:25 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:1794 (1.7 KiB)
Interrupt:4 Base address:0x1000
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
vlan0 Link encap:Ethernet HWaddr 00:0F:66:C5:D2:93
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:272 errors:0 dropped:0 overruns:0 frame:0
TX packets:206 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:21787 (21.2 KiB) TX bytes:23057 (22.5 KiB)
vlan1 Link encap:Ethernet HWaddr 00:0F:66:C5:D2:93
inet addr:XX.XX.XX.XX Bcast:255.255.255.255 Mask:255.255.252.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:204 errors:0 dropped:0 overruns:0 frame:0
TX packets:212 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:18241 (17.8 KiB) TX bytes:22497 (21.9 KiB)
vlan2 Link encap:Ethernet HWaddr 00:0F:66:C5:D2:93
inet addr:192.168.2.2 Bcast:192.168.2.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:28 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:4307 (4.2 KiB)
(Last edited by tclark on 6 Nov 2005, 00:28)