Hello world ![]()
This is my perversion experimet how to use wireless in VLAN
I know - this is stupid, but it works:
vlan1 is a transport vlan between switches and routers
vlan 2-3 are ordinary vlans
vlan 4 is an ordinary vlan with wi-fi AP
clients of all vlans get ip-adresses from another DHCP servers in the networks
DNS’s are on the another servers too
Mikrotik is a just AP with VLAN support
resetting without default config ( it’s important )
/system reset-configuration skip-backup=yes no-defaults=yes
configuring interfaces
/interface ethernet
set ether3 master-port=ether2
set ether4 master-port=ether2
set ether5 master-port=ether2
/interface wireless
set [ find default-name=wlan1 ] band=2ghz-b/g/n channel-width=
20/40mhz-ht-above default-authentication=no dfs-mode=no-radar-detect
disabled=no distance=indoors frequency=2457 l2mtu=2290 mode=ap-bridge
scan-list=2412-2457 wireless-protocol=802.11 default-authentication=yes
/interface wireless security-profiles
set [ find default=yes ] authentication-types=wpa-psk,wpa2-psk eap-methods=“”
mode=dynamic-keys wpa-pre-shared-key=password wpa2-pre-shared-key=
password
adding unusual bridge:
/interface bridge
add mtu=1500 name=bridge1
/interface bridge port
add bridge=bridge1 interface=wlan1
add bridge=bridge1 interface=ether1
time to configure VLANs on swich:
/interface ethernet switch vlan
add independent-learning=no ports=
ether2,ether5,switch1-cpu switch=switch1
vlan-id=2
add independent-learning=no ports=
ether3,ether5,switch1-cpu switch=switch1 vlan-id=3
add independent-learning=no ports=ether4,ether5
switch=switch1 vlan-id=4
add independent-learning=yes ports=ether5,switch1-cpu switch=
switch1 vlan-id=1
dhcp client for future access:
/ip dhcp-client
add comment=“default configuration” dhcp-options=hostname,clientid disabled=
no interface=ether1
configuring ports:
/interface ethernet switch port
set 0 default-vlan-id=2 vlan-header=always-strip vlan-mode=secure
set 1 default-vlan-id=3 vlan-header=always-strip vlan-mode=secure
set 2 default-vlan-id=4 vlan-header=always-strip vlan-mode=secure
set 3 default-vlan-id=1 vlan-header=add-if-missing vlan-mode=secure
set 4 default-vlan-id=1 vlan-mode=disabled
be patient ! interface numbers are different in different swiches !
here (RB751) 0 is ether2, 1 is ether3, 2 is ether4, 3 is ether5 4 is cpu-swich1
and now - my main stupid secret : patch-cord between interfaces 1 and 4
enjoy !
