Community discussions

MikroTik App
 
droussev
just joined
Topic Author
Posts: 3
Joined: Sun Jun 19, 2022 1:42 am

Beginner VLAN Setup

Sun Jun 19, 2022 1:48 am

I am a long time Cisco guy and confused on some VLAN basics. Any help would be greatly appreciated.

All I want to do is configure all the ports on my CRS310-1G-5S-4S to be identical. I would like them to be 802.1Q trunks with vlan 100 as the native VLAN and VLAN 200 tagged. Then the switch to have an IP address on VLAN 100 of 172.16.42.19

Any help would be greatly appreciated!

Dan
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 11587
Joined: Thu Mar 03, 2016 10:23 pm

Re: Beginner VLAN Setup

Sun Jun 19, 2022 1:01 pm

This tutorial nicely describes proper configuration of VLANs in ROS. There are other ways, but your CRS will be able to do the configured stuff using switch chip (rather than general CPU). It shouldn't be too hard for you being network proficient ...
 
droussev
just joined
Topic Author
Posts: 3
Joined: Sun Jun 19, 2022 1:42 am

Re: Beginner VLAN Setup

Sun Jun 19, 2022 6:06 pm

Thank you for the response. I used that tutorial as an example... and I think I must be close, but whenever I enable vlan-filtering, I can no longer talk to the switch.

Here is my config so far...
[admin@HORSE-FIBER] > export
# jan/02/1970 02:28:38 by RouterOS 6.49.6
# software id = CRT4-3BE1
#
# model = CRS310-1G-5S-4S+
# serial number = HC707QWJ949
/interface bridge
add admin-mac=DC:2C:6E:C6:B9:B6 auto-mac=no comment=defconf name=bridge
/interface vlan
add interface=bridge name=BCYF-ADMIN vlan-id=100
/interface wireless security-profiles
set [ find default=yes ] supplicant-identity=MikroTik
/interface bridge port
add bridge=bridge comment=defconf ingress-filtering=yes interface=ether1 pvid=100
add bridge=bridge comment=defconf ingress-filtering=yes interface=sfp-sfpplus1 pvid=100
add bridge=bridge comment=defconf ingress-filtering=yes interface=sfp-sfpplus2 pvid=100
add bridge=bridge comment=defconf ingress-filtering=yes interface=sfp-sfpplus3 pvid=100
add bridge=bridge comment=defconf ingress-filtering=yes interface=sfp-sfpplus4 pvid=100
add bridge=bridge comment=defconf ingress-filtering=yes interface=sfp1 pvid=100
add bridge=bridge comment=defconf ingress-filtering=yes interface=sfp2 pvid=100
add bridge=bridge comment=defconf ingress-filtering=yes interface=sfp3 pvid=100
add bridge=bridge comment=defconf ingress-filtering=yes interface=sfp4 pvid=100
add bridge=bridge comment=defconf ingress-filtering=yes interface=sfp5 pvid=100
/interface bridge vlan
add bridge=bridge comment=BCYF-GUEST tagged=bridge,ether1,sfp1,sfp2,sfp3,sfp4,sfp5,sfp-sfpplus1,sfp-sfpplus2,sfp-sfpplus3,sfp-sfpplus4 vlan-ids=200
add bridge=bridge comment=BCYF-ADMIN untagged=bridge,ether1,sfp1,sfp2,sfp3,sfp4,sfp5,sfp-sfpplus1,sfp-sfpplus2,sfp-sfpplus3,sfp-sfpplus4 vlan-ids=100
/ip address
add address=172.16.42.19/23 interface=BCYF-ADMIN network=172.16.42.0
add address=172.16.42.19/23 interface=bridge network=172.16.42.0
/ip route
add distance=1 gateway=172.16.42.1
/system identity
set name=HORSE-FIBER
/system routerboard settings
set boot-os=router-os
#error exporting /system swos
[admin@HORSE-FIBER] > 
Anything obvious I am screwing up? I have the IP address set twice because it doesn't seem to work as just the VLAN interface..

thanks again.

Dan
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 11587
Joined: Thu Mar 03, 2016 10:23 pm

Re: Beginner VLAN Setup

Sun Jun 19, 2022 6:43 pm

When enabling vlan-filtering on bridge, bridge interface becomes untagged port of VLAN 100 (/interface bridge vlan says so). But to make it propery it would need to be set with pvid (as: /interface bridge set [ find name=bridge ] pvid=100 ). On the other hand having created vlan interface BCYF-ADMIN it seems like you want bridge interface tagged member of VLAN 100. In which case you have to change setting in /interface bridge vlan to reflect that.

You have to decide which way you want to have it. My personal choice would be the second one (bridge tagged for VID 100).
 
droussev
just joined
Topic Author
Posts: 3
Joined: Sun Jun 19, 2022 1:42 am

Re: Beginner VLAN Setup

Sun Jun 19, 2022 7:09 pm

So coming from the Cisco world, I created the VLAN interface BCYF-ADMIN in order to assign an IP address to it for management. But all I really want is for each port to have an access port for vlan 100 and a tagged port for vlan 200. From my reading, I think mikrotik calls that a hybrid port? And then to be able to talk to it over Vlan 100.
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 11587
Joined: Thu Mar 03, 2016 10:23 pm

Re: Beginner VLAN Setup

Sun Jun 19, 2022 7:14 pm

Bridge in ROS has multiple personalities. Read about them, I guess this is what confuses you right now.

Who is online

Users browsing this forum: anav, deatras, Lupin and 38 guests