Community discussions

MikroTik App
 
agjini
newbie
Topic Author
Posts: 36
Joined: Mon Jun 08, 2009 11:43 pm

help need with vlan and trunks. interesting theme

Mon Feb 28, 2011 12:02 am

Hello, i need help to pass 3 vlans from mikrotik 433 >>cisco3524>> to mikrotik x86
i have test direct connection mikrotik >mikrotik is ok .but with cisco between them seems imposibbile . i have configured two port trunk on cisco added 3 vlan to them and to vlan database also but i cant ping vlans .
switch config
port trunk
encapsulation dot1q
vlan allowed 400,401,402
native vlan 1

mikrotik 433 ip 10.0.100.130 /24 ......cisco 10.0.100.2/24 ...x86 router mikrotik 10.0.100.95/24
vlans ex: 10.0.40.1/24.....................................................10.0.40.2/24

i want to make a configuration when one antena will serve as hotspot, vpn ,voip. but with divided trafic with vlans and a central x86 router which have services for each vlan.

i need to use cisco becouse all the network is wds trunk cisco vlan in all pop
thank you for your support and time
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: help need with vlan and trunks. interesting theme

Mon Feb 28, 2011 2:20 am

Assuming ether1 on the 433 goes to fa0/1 on the 3524, and ethers on the x86 goes to fa0/2 on the same switch, and that native VLAN 1 is also used, the below is the configuration of all three devices.

433:
/interface vlan
add disabled=no name=vlan400 interface=ether1 vlan-id=400
add disabled=no name=vlan401 interface=ether1 vlan-id=401
add disabled=no name=vlan402 interface=ether1 vlan-id=402
/ip address
add address=10.0.100.1/24 interface=ether1
add address=10.0.40.1/24 interface=vlan400
add address=10.0.41.1/24 interface=vlan401
add address=10.0.42.1/24 interface=vlan402
x86:
/interface vlan
add disabled=no name=vlan400 interface=ether1 vlan-id=400
add disabled=no name=vlan401 interface=ether1 vlan-id=401
add disabled=no name=vlan402 interface=ether1 vlan-id=402
/ip address
add address=10.0.100.2/24 interface=ether1
add address=10.0.40.2/24 interface=vlan400
add address=10.0.41.2/24 interface=vlan401
add address=10.0.42.2/24 interface=vlan402
3524:
configure terminal
vlan 400
name vlan400
vlan 401
name vlan401
vlan 402
name vlan402
interface vlan 1
ip address 10.0.100.3 255.255.255.0
no shutdown
interface range fastethernet 0/1 - 2
switchport trunk encapsulation dot1q
switchport trunk allowed vlan 1,400,401,402
switchport trunk native vlan 1
no shutdown
end
 
agjini
newbie
Topic Author
Posts: 36
Joined: Mon Jun 08, 2009 11:43 pm

Re: help need with vlan and trunks. interesting theme

Mon Feb 28, 2011 10:16 pm

thank you, i have allready tryed that onfiguration but doesnt work with cisco in the midle. its strange . i connect x86>to rb433 and i can ping vlans but if i disconect and connect thru a switcher with that config it stop communicating. i have remake all vlans trunks diffrent times but unsucesefull.

:(
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: help need with vlan and trunks. interesting theme

Mon Feb 28, 2011 10:19 pm

Works fine for me.
 
fewi
Forum Guru
Forum Guru
Posts: 7717
Joined: Tue Aug 11, 2009 3:19 am

Re: help need with vlan and trunks. interesting theme

Mon Feb 28, 2011 10:49 pm

I actually tried it out in a quick lab for you.

Router A, an RB1100, with only the following added to a default configuration (also, all interfaces but the one involved in the Lab have been disabled:
[admin@routerA] > /interface vlan export
# jan/02/1970 00:05:28 by RouterOS 4.15
# software id = JAK5-79ZH
#
/interface vlan
add arp=enabled comment="" disabled=no interface=ether1 l2mtu=1594 mtu=1500 \
    name=vlan400 use-service-tag=no vlan-id=400
[admin@routerA] > /ip address export
# jan/02/1970 00:05:35 by RouterOS 4.15
# software id = JAK5-79ZH
#
/ip address
add address=10.0.100.1/24 broadcast=10.0.100.255 comment="" disabled=no \
    interface=ether1 network=10.0.100.0
add address=10.0.40.1/24 broadcast=10.0.40.255 comment="" disabled=no \
    interface=vlan400 network=10.0.40.0
Router B, an RB1100, with only the following added to a default configuration (also, all interfaces but the one involved in the Lab have been disabled:
[admin@routerB] > /interface vlan export
# jan/02/1970 00:07:54 by RouterOS 4.15
# software id = GV7H-25DP
#
/interface vlan
add arp=enabled comment="" disabled=no interface=ether1 l2mtu=1594 mtu=1500 name=vlan400 use-service-tag=no vlan-id=400
[admin@routerB] > /ip address export
# jan/02/1970 00:07:57 by RouterOS 4.15
# software id = GV7H-25DP
#
/ip address
add address=10.0.100.2/24 broadcast=10.0.100.255 comment="" disabled=no interface=ether1 network=10.0.100.0
add address=10.0.40.2/24 broadcast=10.0.40.255 comment="" disabled=no interface=vlan400 network=10.0.40.0

The ether1 ports are directly connected to one another. Ping works on physical interface as well as VLAN interface:
[admin@routerA] > /ping 10.0.100.2 count=5
10.0.100.2 64 byte ping: ttl=64 time=8 ms
10.0.100.2 64 byte ping: ttl=64 time<1 ms
10.0.100.2 64 byte ping: ttl=64 time<1 ms
10.0.100.2 64 byte ping: ttl=64 time<1 ms
10.0.100.2 64 byte ping: ttl=64 time<1 ms
5 packets transmitted, 5 packets received, 0% packet loss
round-trip min/avg/max = 0/1.6/8 ms
[admin@routerA] > /ping 10.0.40.2 count=5
10.0.40.2 64 byte ping: ttl=64 time=9 ms
10.0.40.2 64 byte ping: ttl=64 time<1 ms
10.0.40.2 64 byte ping: ttl=64 time<1 ms
10.0.40.2 64 byte ping: ttl=64 time<1 ms
10.0.40.2 64 byte ping: ttl=64 time<1 ms
5 packets transmitted, 5 packets received, 0% packet loss
round-trip min/avg/max = 0/1.8/9 ms
Now a Cisco 2950, with the following configuration added to the default configuration:
Switch#sh run int fa0/1
Building configuration...

Current configuration : 93 bytes
!
interface FastEthernet0/1
 switchport trunk allowed vlan 1,400
 switchport mode trunk
end

Switch#sh run int fa0/2
Building configuration...

Current configuration : 93 bytes
!
interface FastEthernet0/2
 switchport trunk allowed vlan 1,400
 switchport mode trunk
end

Switch#sh spann int fa0/1

Vlan             Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
VLAN0001         Desg FWD 19        128.1    P2p
VLAN0400         Desg FWD 19        128.1    P2p
Switch#sh spann int fa0/2

Vlan             Role Sts Cost      Prio.Nbr Type
---------------- ---- --- --------- -------- --------------------------------
VLAN0001         Desg FWD 19        128.2    P2p
VLAN0400         Desg FWD 19        128.2    P2p

Switch#sh run int vlan 1
Building configuration...

Current configuration : 79 bytes
!
interface Vlan1
 ip address 10.0.100.3 255.255.255.0
 no ip route-cache
end

Switch#sh vlan id 400

VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
400  test                             active    Fa0/1, Fa0/2

VLAN Type  SAID       MTU   Parent RingNo BridgeNo Stp  BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------
400  enet  100400     1500  -      -      -        -    -        0      0

Remote SPAN VLAN
----------------
Disabled

Primary Secondary Type              Ports
------- --------- ----------------- ------------------------------------------

Switch#
ether1 on RouterA connects to fa0/1, ether1 on RouterB connects to fa0/2:
Switch#sh cdp nei
Capability Codes: R - Router, T - Trans Bridge, B - Source Route Bridge
                  S - Switch, H - Host, I - IGMP, r - Repeater, P - Phone

Device ID        Local Intrfce     Holdtme    Capability  Platform  Port ID
routerB          Fas 0/2            89            R       MikroTik
routerA          Fas 0/1            101           R       MikroTik
Switch#
Ping still works on VLAN 1 (between switch and the two routers, switch times out once while ARP hasn't resolved yet), as well as VLAN 400:
[admin@routerA] > /ping 10.0.100.2 count=2
10.0.100.2 64 byte ping: ttl=64 time=4 ms
10.0.100.2 64 byte ping: ttl=64 time<1 ms
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max = 0/2.0/4 ms
[admin@routerA] > /ping 10.0.100.3 count=2
10.0.100.3 ping timeout
10.0.100.3 64 byte ping: ttl=255 time=1 ms
2 packets transmitted, 1 packets received, 50% packet loss
round-trip min/avg/max = 1/1.0/1 ms
[admin@routerA] > /ping 10.0.40.2 count=2
10.0.40.2 64 byte ping: ttl=64 time<1 ms
10.0.40.2 64 byte ping: ttl=64 time<1 ms
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max = 0/0.0/0 ms
Post your switch and router configs as well as a network diagram here if you need further help - you've got it misconfigured somewhere.

Who is online

Users browsing this forum: No registered users and 50 guests