Z tego co widzę to wywołanie:
Owszem wypisuje mi VLan'y ale to lokalnie zdefiniowane na routerze, a nie te które przychodzą od dostawcy.
Moja konfiguracja:
config 'interface' 'loopback'
option 'ifname' 'lo'
option 'proto' 'static'
option 'ipaddr' '127.0.0.1'
option 'netmask' '255.0.0.0'
config 'interface' 'lan'
option 'type' 'bridge'
option 'proto' 'static'
option 'ipaddr' '192.168.1.1'
option 'netmask' '255.255.255.0'
option 'ifname' 'eth0.1'
config 'interface' 'wan'
option 'ifname' 'eth0.2'
option 'proto' 'dhcp'
config 'switch' 'eth0'
option 'name' 'eth0'
option 'reset' '1'
option 'enable_vlan' '1'
config 'switch_vlan' 'eth0_2'
option 'device' 'eth0'
option 'vlan' '2'
option 'ports' '4 5t'
config 'switch_vlan' 'eth0_1'
option 'device' 'eth0'
option 'vlan' '1'
option 'ports' '2 3 5t'
config 'switch_vlan' 'eth0_3'
option 'device' 'eth'
option 'vlan' '3'
option 'ports' '0 1 5t'
Jestem podpięty do routera na porcie 3 (vlan 1),
Kabel od dostawcy wczepiłem do portu 1 (vlan 3), nie do WAN (WAN u mnie to port 4)
Uruchamiam:
Widzę:
19:30:01.454453 00:30:48:65:e1:2c > ff:ff:ff:ff:ff:ff, ethertype 802.1Q (0x8100), length 64: vlan 3, p 0, ethertype ARP, Request who-has 212.67.151.135 tell 212.67.151.1, length 46
19:30:01.491977 00:30:48:65:e1:2c > ff:ff:ff:ff:ff:ff, ethertype 802.1Q (0x8100), length 64: vlan 3, p 0, ethertype ARP, Request who-has 212.67.151.235 tell 212.67.151.1, length 46
19:30:01.502000 a4:ba:db:c1:a7:00 > ff:ff:ff:ff:ff:ff, ethertype 802.1Q (0x8100), length 64: vlan 3, p 0, ethertype ARP, Request who-has 212.67.151.30 tell 212.67.151.30, length 46
19:30:01.504175 00:22:b0:9a:c3:51 > 00:14:0b:03:cd:1b, ethertype 802.1Q (0x8100), length 1518: vlan 1, p 0, ethertype IPv4, 192.168.1.1.23 > 192.168.1.235.50447: Flags [.], ack 1, win 2920, length 1460
19:30:01.504985 00:14:0b:03:cd:1b > 00:22:b0:9a:c3:51, ethertype 802.1Q (0x8100), length 64: vlan 1, p 0, ethertype IPv4, 192.168.1.235.50447 > 192.168.1.1.23: Flags [.], ack 6319, win 16425, length 0
19:30:01.506176 00:22:b0:9a:c3:51 > 00:14:0b:03:cd:1b, ethertype 802.1Q (0x8100), length 111: vlan 1, p 0, ethertype IPv4, 192.168.1.1.23 > 192.168.1.235.50447: Flags [P.], ack 1, win 2920, length 53
Czyli niby vlan 1 i vlan 3, coś mi nie pasuje że to moje vlany więc zmieniam konfigurację:
config 'switch_vlan' 'eth0_3'
option 'device' 'eth'
option 'ports' '0 1 5t'
option 'vlan' '3'
na:
config 'switch_vlan' 'eth0_5'
option 'device' 'eth'
option 'ports' '0 1 5t'
option 'vlan' '5'
Wiadmo commit, restart.
Uruchamiam:
Widzę:
19:34:16.890480 00:14:0b:03:cd:1b > 00:22:b0:9a:c3:51, ethertype 802.1Q (0x8100), length 64: vlan 1, p 0, ethertype IPv4, 192.168.1.235.50447 > 192.168.1.1.23: Flags [.], ack 6117, win 16177, length 0
19:34:16.891550 00:22:b0:9a:c3:51 > 00:14:0b:03:cd:1b, ethertype 802.1Q (0x8100), length 1394: vlan 1, p 0, ethertype IPv4, 192.168.1.1.23 > 192.168.1.235.50447: Flags [P.], ack 0, win 2920, length 1336
19:34:16.953480 00:30:48:65:e1:2c > ff:ff:ff:ff:ff:ff, ethertype 802.1Q (0x8100), length 64: vlan 5, p 0, ethertype ARP, Request who-has 212.67.154.145 tell 212.67.154.129, length 46
19:34:17.030796 00:12:f0:2c:9e:7d > ff:ff:ff:ff:ff:ff, ethertype 802.1Q (0x8100), length 64: vlan 5, p 0, ethertype ARP, Request who-has 212.67.151.1 (00:30:48:65:e1:2c) tell 212.67.151.88, length 46
19:34:17.043484 00:30:48:65:e1:2c > ff:ff:ff:ff:ff:ff, ethertype 802.1Q (0x8100), length 64: vlan 5, p 0, ethertype ARP, Request who-has 212.67.151.15 tell 212.67.151.1, length 46
Czyli MOJE vlan 1 i vlan 5.
Zatem ponawiam pytanie.
Jak dowiedzieć się z kabla od dostawcy jakie ma tam vlany (identyfikatory vid czy tam pvid dostarczanych vlanów)?
Są na pewno dwa
1. internet - pewnie nietagowany bo działa też bez ich switcha,
2. iptv - pewnie tagowany (bo jest tylko za ich switchem na dwóch portach w innej podsieci)
Proszę o pomoc !!! (drażni mnie ten ich switch, chcę własny, jak zrobię podzielę się pełną wiedzą)
Jakby co służę wszelakimi zrzutami.
TP-Link TL-WDR4300 v1, Reboot (17.01-SNAPSHOT, r3876-efb6ca1)