Community discussions

MikroTik App
 
ayufan
Member
Member
Topic Author
Posts: 334
Joined: Sun Jun 03, 2007 9:35 pm
Contact:

AR8327

Sun Dec 02, 2012 3:52 pm

Why all devices (RB1100AH, RB1100AHx2, RB751G, RB2011) with AR8327 doesn't support port trunking?

Just simple case, no hybrid ports:
1. one port as tagged
2. one or more ports as untagged

Why there is limitation to one master port per switch group?

I'm asking because this is definitely not hardware limitation.

--

I did some testing. Here are results:

1. I have router (RB751G-2HuND) on which I installed latest attitude adjustment (12.09rc1) (https://forum.openwrt.org/viewtopic.php?id=39171).

2. I have 3 ports in use:
Port 1. WAN connection, uses DHCP
Port 2. Nucleus, Intel Atom, Debian/Squeeze, connected using 100Mbps/FD ethernet.
Port 3. Raspberry PI, OpenWrt 12.09rc1, connected using 100Mbps/FD ethernet.

3. I created 5 VLANs. You can see switch chip configuration on attached screenshot.
VLAN 1. LAN: untagged Port 2 goes as tagged to CPU. In system visible as eth0.1. eth0.1 is bridged with wlan.
VLAN 2. WAN: untagged Port 1 goes as tagged to CPU. In system visible as eth0.2. On eth0.2 dhcp-client is being run.
VLAN 4. untagged Port 3 goes as tagged to Port 2 with VLANID 4.
VLAN 5. untagged Port 4 goes as tagged to Port 2 with VLANID 5.
VLAN 6. untagged Port 5 goes as tagged to Port 2 with VLANID 6.

4. On nucleus I have all VLANIDs configured (eth0.1, eth0.4, eth0.5, eth0.6) and bridged together. So devices connected to port 3, 4 or 5 should always be reachable from router's CPU port.

5. Because I only have one other device (Raspberry PI) i did plug it to port 3, then to port 4 and then to port 5. Each time traffic coming from Raspberry PI to nucleus was coming from different VLANID (as expected).

To support my results here are tcpdump's:

Raspberry PI connected to port 3
root@nucleus:~# tcpdump -i eth0 -e icmp -vn
tcpdump: WARNING: eth0: no IPv4 address assigned
tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 65535 bytes
15:09:08.537500 ac:72:89:24:a1:03 > b8:27:eb:4e:a6:d8, ethertype 802.1Q (0x8100), length 78: vlan 1, p 0, ethertype IPv4, (tos 0x0, ttl 128, id 914, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.12 > 192.168.88.38: ICMP echo request, id 1, seq 4750, length 40
15:09:08.537532 ac:72:89:24:a1:03 > b8:27:eb:4e:a6:d8, ethertype 802.1Q (0x8100), length 78: vlan 4, p 0, ethertype IPv4, (tos 0x0, ttl 128, id 914, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.12 > 192.168.88.38: ICMP echo request, id 1, seq 4750, length 40
15:09:08.538086 b8:27:eb:4e:a6:d8 > ac:72:89:24:a1:03, ethertype 802.1Q (0x8100), length 78: vlan 4, p 0, ethertype IPv4, (tos 0x0, ttl 64, id 49827, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.38 > 192.168.88.12: ICMP echo reply, id 1, seq 4750, length 40
15:09:08.538104 b8:27:eb:4e:a6:d8 > ac:72:89:24:a1:03, ethertype 802.1Q (0x8100), length 78: vlan 1, p 0, ethertype IPv4, (tos 0x0, ttl 64, id 49827, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.38 > 192.168.88.12: ICMP echo reply, id 1, seq 4750, length 40
Raspberry PI connected to port 4
root@nucleus:~# tcpdump -i eth0 -e icmp -vn
tcpdump: WARNING: eth0: no IPv4 address assigned
tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 65535 bytes
15:08:44.802239 ac:72:89:24:a1:03 > b8:27:eb:4e:a6:d8, ethertype 802.1Q (0x8100), length 78: vlan 1, p 0, ethertype IPv4, (tos 0x0, ttl 128, id 864, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.12 > 192.168.88.38: ICMP echo request, id 1, seq 4730, length 40
15:08:44.802259 ac:72:89:24:a1:03 > b8:27:eb:4e:a6:d8, ethertype 802.1Q (0x8100), length 78: vlan 5, p 0, ethertype IPv4, (tos 0x0, ttl 128, id 864, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.12 > 192.168.88.38: ICMP echo request, id 1, seq 4730, length 40
15:08:44.802702 b8:27:eb:4e:a6:d8 > ac:72:89:24:a1:03, ethertype 802.1Q (0x8100), length 78: vlan 5, p 0, ethertype IPv4, (tos 0x0, ttl 64, id 49829, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.38 > 192.168.88.12: ICMP echo reply, id 1, seq 4730, length 40
15:08:44.802720 b8:27:eb:4e:a6:d8 > ac:72:89:24:a1:03, ethertype 802.1Q (0x8100), length 78: vlan 1, p 0, ethertype IPv4, (tos 0x0, ttl 64, id 49829, offset 0, flags [none], proto ICMP (1), length 60)
Raspberry PI connected to port 5
root@nucleus:~# tcpdump -i eth0 -e icmp -vn
tcpdump: WARNING: eth0: no IPv4 address assigned
tcpdump: listening on eth0, link-type EN10MB (Ethernet), capture size 65535 bytes
15:08:12.138500 ac:72:89:24:a1:03 > b8:27:eb:4e:a6:d8, ethertype 802.1Q (0x8100), length 78: vlan 1, p 0, ethertype IPv4, (tos 0x0, ttl 128, id 796, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.12 > 192.168.88.38: ICMP echo request, id 1, seq 4712, length 40
15:08:12.138529 ac:72:89:24:a1:03 > b8:27:eb:4e:a6:d8, ethertype 802.1Q (0x8100), length 78: vlan 6, p 0, ethertype IPv4, (tos 0x0, ttl 128, id 796, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.12 > 192.168.88.38: ICMP echo request, id 1, seq 4712, length 40
15:08:12.139124 b8:27:eb:4e:a6:d8 > ac:72:89:24:a1:03, ethertype 802.1Q (0x8100), length 78: vlan 6, p 0, ethertype IPv4, (tos 0x0, ttl 64, id 49836, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.38 > 192.168.88.12: ICMP echo reply, id 1, seq 4712, length 40
15:08:12.139143 b8:27:eb:4e:a6:d8 > ac:72:89:24:a1:03, ethertype 802.1Q (0x8100), length 78: vlan 1, p 0, ethertype IPv4, (tos 0x0, ttl 64, id 49836, offset 0, flags [none], proto ICMP (1), length 60)
192.168.88.38 > 192.168.88.12: ICMP echo reply, id 1, seq 4712, length 40
Legend:
1. 192.168.88.12 - this is the IP address of my laptop connected to router over wifi. From switch chip perspective is the CPU port.
2. vlan 1 - this is traffic coming from router (wifi too) as described earlier.
3. 192.168.88.38 - this is the IP address of Raspberry PI.
4. vlan 4/5/6 - this is traffic outgoing to Raspberry PI.

Conclusion:
1. Port trunking works as expected on AR8327. Hybrid configuration is not working.
2. Problem with trunking on RouterOS is definitely not hardware related, but buggy implementation of switch chip.
3. Switch chip allows to have multi-master port configuration.
4. If you need port trunking RouterOS is NOGO!
5. OpenWrt supports it out of box: wire speed port trunking (no hybrid configuration) and multi-master port configuration.

My assumptions:
1. RouterOS switch chip configuration is over complicated in some simple use-case as port trunking (Just read: http://wiki.mikrotik.com/wiki/Manual:Sw ... p_Features Example - 802.1Q Trunking with Atheros 8316). In order to use port trunking you have to use switch chip rules? hahaha
2. RouterOS switch chip implementation is messy and buggy. I somehow managed to partially configure hybrid port configuration on RouterOS.
2. RouterOS switch chip configuration maps individual ports to VLANIDs. In system these VLANIDs are separate switch chip ports. Master port configuration groups these ports together to one VLANID.
3. What we really miss is the PVID and trunking port option in Switch Chip port's view. We definitely don't need rules to setup port trunking.

Devices configuration:
root@router:/etc/config# cat network

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 ifname 'eth0.1'
option type 'bridge'
option proto 'static'
option netmask '255.255.255.0'
option ipaddr '192.168.88.1'

config interface 'wan'
option ifname 'eth0.2'
option proto 'dhcp'

config switch
option name 'switch0'
option reset '1'
option enable_vlan '1'

config switch_vlan
option device 'switch0'
option vlan '1'
option vid '1'
option ports '0t 2t'

config switch_vlan
option device 'switch0'
option vlan '2'
option ports '0t 1'
option vid '2'

config switch_vlan
option device 'switch0'
option vlan '3'
option vid '4'
option ports '2t 3'

config switch_vlan
option device 'switch0'
option vlan '4'
option vid '5'
option ports '2t 4'

config switch_vlan
option device 'switch0'
option vlan '5'
option vid '6'
option ports '2t 5'
root@nucleus:~# ifconfig
eth0 Link encap:Ethernet HWaddr 00:21:85:e0:76:b4
eth0.1 Link encap:Ethernet HWaddr 00:21:85:e0:76:b4
eth0.4 Link encap:Ethernet HWaddr 00:21:85:e0:76:b4
eth0.5 Link encap:Ethernet HWaddr 00:21:85:e0:76:b4
eth0.6 Link encap:Ethernet HWaddr 00:21:85:e0:76:b4
vmbr0 Link encap:Ethernet HWaddr c2:3a:c8:ea:f5:dd
root@nucleus:~# brctl show
bridge name bridge id STP enabled interfaces
vmbr0 8000.c23ac8eaf5dd no eth0.1
eth0.4
eth0.5
eth0.6
root@rpi:~# ifconfig
eth0 Link encap:Ethernet HWaddr B8:27:EB:4E:A6:D8
inet addr:192.168.88.38 Bcast:192.168.88.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:5413 errors:0 dropped:0 overruns:0 frame:0
TX packets:3426 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:420831 (410.9 KiB) TX bytes:365166 (356.6 KiB)

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:7792 errors:0 dropped:0 overruns:0 frame:0
TX packets:7792 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:530388 (517.9 KiB) TX bytes:530388 (517.9 KiB)
You do not have the required permissions to view the files attached to this post.
Last edited by ayufan on Sun Dec 16, 2012 12:38 am, edited 2 times in total.
 
mgiammarco
newbie
Posts: 47
Joined: Tue Apr 13, 2010 10:56 pm

Re: AR8327

Sat Dec 15, 2012 3:41 pm

Thanks, I needed this informations. I would like to use wire speed with trunking and I now see it is not possible.

Any news on this?

Thanks,
Mario
 
ayufan
Member
Member
Topic Author
Posts: 334
Joined: Sun Jun 03, 2007 9:35 pm
Contact:

Re: AR8327

Sun Dec 16, 2012 12:35 am

Nope. No response from support. It is not possible on RouterOS and fairly simple on OpenWrt. So... :)
 
resetsa
just joined
Posts: 17
Joined: Mon Apr 18, 2011 8:19 am

Re: AR8327

Sat Feb 15, 2014 7:47 pm

Any progress?
 
becs
MikroTik Support
MikroTik Support
Posts: 499
Joined: Thu Jul 07, 2011 8:26 am

Re: AR8327

Tue Feb 18, 2014 9:06 am

Any progress?
Trunking with AR8327 switch chip is working since RouterOS v6.0:
http://wiki.mikrotik.com/wiki/Manual:Sw ... p_Features
 
User avatar
dasiu
Trainer
Trainer
Posts: 231
Joined: Fri Jan 30, 2009 11:41 am
Location: Reading, UK
Contact:

Re: AR8327

Tue Feb 18, 2014 12:49 pm

Any progress?
I will have a presentation on the next MUM (in 2 days), showing how easy it is :).
 
User avatar
payday
Member Candidate
Member Candidate
Posts: 233
Joined: Thu Aug 16, 2012 11:05 pm

Re: AR8327

Tue Feb 18, 2014 8:00 pm

Any progress?
I will have a presentation on the next MUM (in 2 days), showing how easy it is :).
Will you make your presentation available online (after MUM)?
 
User avatar
dynek
Member Candidate
Member Candidate
Posts: 223
Joined: Tue Jan 21, 2014 10:03 pm

Re: AR8327

Thu Mar 20, 2014 5:39 pm

 
ayufan
Member
Member
Topic Author
Posts: 334
Joined: Sun Jun 03, 2007 9:35 pm
Contact:

Re: AR8327

Thu Mar 20, 2014 6:20 pm

This presentation is not accurate (or only based on what wiki says), because in reality with the switch chip you can use hybrid ports :) At least it works on RB1100AHx2 and RB951G-2HnD. What I've also discovered that VLAN header setting doesn't make any difference at all.

Who is online

Users browsing this forum: Google [Bot], mike7, rudivd and 79 guests