Community discussions

MikroTik App
 
xslimakx
just joined
Topic Author
Posts: 6
Joined: Sat Aug 22, 2015 9:23 pm

MT CRS as router on the stick for ESXi host

Sun Sep 13, 2015 9:18 pm

Hi,

I'm trying to do router on the stick for ESXi host. But i'm stuck with this one. I have port 24 connected to esxi, two vlans 33 and 44. From two virtual machines I can ping default gateway (MT with .1) but machines cannot ping each other. Can you please tell me what I'm doing wrong?
/interface bridge
add name=br-1
add name=br-vlan-11
add name=br-vlan-33
add name=br-vlan-44
/interface ethernet
set [ find default-name=ether1 ] name=ether1-mt8-1
set [ find default-name=ether2 ] master-port=ether1-mt8-1 name=ether2-router-1
set [ find default-name=ether3 ] name=ether3-slave-local
set [ find default-name=ether4 ] master-port=ether1-mt8-1 name=ether4-slave-local
set [ find default-name=ether5 ] master-port=ether1-mt8-1 name=ether5-slave-local
set [ find default-name=ether6 ] master-port=ether1-mt8-1 name=ether6-slave-local
set [ find default-name=ether7 ] master-port=ether1-mt8-1 name=ether7-slave-local
set [ find default-name=ether8 ] master-port=ether1-mt8-1 name=ether8-slave-local
set [ find default-name=ether9 ] name=ether9-syno-2hd
set [ find default-name=ether10 ] master-port=ether3-slave-local name=ether10-syno-1hd
set [ find default-name=ether11 ] master-port=ether3-slave-local name=ether11-esxi-mgmt
set [ find default-name=ether12 ] master-port=ether3-slave-local name=ether12-mac
set [ find default-name=ether13 ] master-port=ether3-slave-local name=ether13-raspi
set [ find default-name=ether14 ] master-port=ether1-mt8-1 name=ether14-slave-local
set [ find default-name=ether15 ] master-port=ether1-mt8-1 name=ether15-slave-local
set [ find default-name=ether16 ] master-port=ether1-mt8-1 name=ether16-slave-local
set [ find default-name=ether17 ] master-port=ether1-mt8-1 name=ether17-slave-local
set [ find default-name=ether18 ] master-port=ether1-mt8-1 name=ether18-slave-local
set [ find default-name=ether19 ] master-port=ether1-mt8-1 name=ether19-slave-local
set [ find default-name=ether20 ] master-port=ether1-mt8-1 name=ether20-slave-local
set [ find default-name=ether21 ] master-port=ether1-mt8-1 name=ether21-esxi-4-4
set [ find default-name=ether22 ] master-port=ether1-mt8-1 name=ether22-esxi-4-3
set [ find default-name=ether23 ] master-port=ether1-mt8-1 name=ether23-esxi-4-2
set [ find default-name=ether24 ] name=ether24-esxi-4-1
set [ find default-name=sfp1 ] master-port=ether1-mt8-1 name=sfp1-slave-local
/interface vlan
add interface=ether24-esxi-4-1 l2mtu=1584 name=vlan-11 vlan-id=11
add interface=ether24-esxi-4-1 l2mtu=1584 name=vlan-22 vlan-id=22
add interface=ether24-esxi-4-1 l2mtu=1584 name=vlan-33 vlan-id=33
add interface=ether24-esxi-4-1 l2mtu=1584 name=vlan-44 vlan-id=44
/port
set 0 name=serial0
/interface bridge port
add bridge=br-vlan-11 interface=vlan-11
add bridge=br-vlan-11 interface=ether3-slave-local
add bridge=br-vlan-11 interface=ether9-syno-2hd
add bridge=br-vlan-33 interface=vlan-33
add bridge=br-vlan-44 interface=vlan-44
/interface ethernet switch egress-vlan-tag
add tagged-ports=switch1-cpu vlan-id=33
add tagged-ports=switch1-cpu vlan-id=44
/interface ethernet switch ingress-vlan-translation
add customer-vid=33 new-customer-vid=44 ports=ether24-esxi-4-1 sa-learning=yes
add customer-vid=44 new-customer-vid=33 ports=ether24-esxi-4-1 sa-learning=yes
/ip address
add address=192.168.11.133/27 interface=vlan-11 network=192.168.11.128
add address=192.168.33.1/24 interface=vlan-33 network=192.168.33.0
add address=192.168.44.1/24 interface=vlan-44 network=192.168.44.0
/ip dns static
add address=192.168.11.131 name=raspi
/ip route
add distance=1 gateway=192.168.11.129
/lcd
set backlight-timeout=2h default-screen=interfaces time-interval=hour
/lcd interface pages
set 2 interfaces=ether3-slave-local
/system clock
set time-zone-autodetect=no time-zone-name=Europe/Warsaw
/system routerboard settings
set protected-routerboot=disabled
 
User avatar
shadowskippie
Member Candidate
Member Candidate
Posts: 213
Joined: Tue Dec 21, 2010 6:20 pm

Re: MT CRS as router on the stick for ESXi host

Tue Sep 15, 2015 12:53 pm

not sure if this will do anything the IPs onto the bridge instead.
 
xslimakx
just joined
Topic Author
Posts: 6
Joined: Sat Aug 22, 2015 9:23 pm

Re: MT CRS as router on the stick for ESXi host

Tue Sep 15, 2015 12:57 pm

could you please write the configuration that you are thinking about
 
User avatar
shadowskippie
Member Candidate
Member Candidate
Posts: 213
Joined: Tue Dec 21, 2010 6:20 pm

Re: MT CRS as router on the stick for ESXi host

Tue Sep 15, 2015 1:07 pm

/ip address
add address=192.168.11.133/27 interface=br-vlan-11 network=192.168.11.128
add address=192.168.33.1/24 interface=br-vlan-33 network=192.168.33.0
add address=192.168.44.1/24 interface=br-vlan-44 network=192.168.44.0


I hope you see what i did. I'm having lunch right now and hammered this out on my cell phone
 
xslimakx
just joined
Topic Author
Posts: 6
Joined: Sat Aug 22, 2015 9:23 pm

Re: MT CRS as router on the stick for ESXi host

Tue Sep 15, 2015 1:11 pm

ok i will check this
 
xslimakx
just joined
Topic Author
Posts: 6
Joined: Sat Aug 22, 2015 9:23 pm

Re: MT CRS as router on the stick for ESXi host

Thu Sep 17, 2015 8:48 pm

This didn't solve the problem. I'm still able to ping default gateway but cannot ping host.
 
User avatar
shadowskippie
Member Candidate
Member Candidate
Posts: 213
Joined: Tue Dec 21, 2010 6:20 pm

Re: MT CRS as router on the stick for ESXi host

Fri Sep 18, 2015 12:00 am

Okay. First, putting the IPs onto the bridge is the proper way of doing this. Moving beyond this lets checks some stuff.

First, stupid question but did you set the machines gateway to their respective ips on the switch.

Next, do you have any firewall filter rules.

Can you send me a print of your ip routes, ip addresses, interfaces. Of coarse removing any sensitive information before hand.

Can't think of anything more right now but if I do I'll post it here for you to try.
 
xslimakx
just joined
Topic Author
Posts: 6
Joined: Sat Aug 22, 2015 9:23 pm

Re: MT CRS as router on the stick for ESXi host

Fri Sep 18, 2015 7:02 am

Default gateways on machines are correct - checked
No firewall on MT or on ubuntu machines
This MT is my first MT so there is no sensitive info - see below /export
[admin@MikroTik] > /export 
# sep/18/2015 06:00:42 by RouterOS 6.27
# software id = XXXX-XXXX
#
/interface bridge
add name=br-1
add name=br-vlan-11
add name=br-vlan-33
add name=br-vlan-44
/interface ethernet
set [ find default-name=ether1 ] name=ether1-mt8-1
set [ find default-name=ether2 ] master-port=ether1-mt8-1 name=ether2-router-1
set [ find default-name=ether3 ] name=ether3-slave-local
set [ find default-name=ether4 ] master-port=ether1-mt8-1 name=ether4-slave-local
set [ find default-name=ether5 ] master-port=ether1-mt8-1 name=ether5-slave-local
set [ find default-name=ether6 ] master-port=ether1-mt8-1 name=ether6-slave-local
set [ find default-name=ether7 ] master-port=ether1-mt8-1 name=ether7-slave-local
set [ find default-name=ether8 ] master-port=ether1-mt8-1 name=ether8-slave-local
set [ find default-name=ether9 ] name=ether9-syno-2hd
set [ find default-name=ether10 ] master-port=ether3-slave-local name=ether10-syno-1hd
set [ find default-name=ether11 ] master-port=ether3-slave-local name=ether11-esxi-mgmt
set [ find default-name=ether12 ] master-port=ether3-slave-local name=ether12-mac
set [ find default-name=ether13 ] master-port=ether3-slave-local name=ether13-raspi
set [ find default-name=ether14 ] master-port=ether1-mt8-1 name=ether14-slave-local
set [ find default-name=ether15 ] master-port=ether1-mt8-1 name=ether15-slave-local
set [ find default-name=ether16 ] master-port=ether1-mt8-1 name=ether16-slave-local
set [ find default-name=ether17 ] master-port=ether1-mt8-1 name=ether17-slave-local
set [ find default-name=ether18 ] master-port=ether1-mt8-1 name=ether18-slave-local
set [ find default-name=ether19 ] master-port=ether1-mt8-1 name=ether19-slave-local
set [ find default-name=ether20 ] master-port=ether1-mt8-1 name=ether20-slave-local
set [ find default-name=ether21 ] master-port=ether1-mt8-1 name=ether21-esxi-4-4
set [ find default-name=ether22 ] master-port=ether1-mt8-1 name=ether22-esxi-4-3
set [ find default-name=ether23 ] master-port=ether1-mt8-1 name=ether23-esxi-4-2
set [ find default-name=ether24 ] name=ether24-esxi-4-1
set [ find default-name=sfp1 ] master-port=ether1-mt8-1 name=sfp1-slave-local
/interface vlan
add interface=ether24-esxi-4-1 l2mtu=1584 name=vlan-11 vlan-id=11
add interface=ether24-esxi-4-1 l2mtu=1584 name=vlan-22 vlan-id=22
add interface=ether24-esxi-4-1 l2mtu=1584 name=vlan-33 vlan-id=33
add interface=ether24-esxi-4-1 l2mtu=1584 name=vlan-44 vlan-id=44
/port
set 0 name=serial0
/interface bridge port
add bridge=br-vlan-11 interface=vlan-11
add bridge=br-vlan-11 interface=ether3-slave-local
add bridge=br-vlan-11 interface=ether9-syno-2hd
add bridge=br-vlan-33 interface=vlan-33
add bridge=br-vlan-44 interface=vlan-44
/ip address
add address=192.168.11.133/27 interface=vlan-11 network=192.168.11.128
add address=192.168.44.1/24 interface=br-vlan-44 network=192.168.44.0
add address=192.168.33.1/24 interface=br-vlan-33 network=192.168.33.0
/ip dns static
add address=192.168.11.131 name=raspi
/ip route
add distance=1 gateway=192.168.11.129
/lcd
set backlight-timeout=2h default-screen=interfaces time-interval=hour
/lcd interface pages
set 2 interfaces=ether3-slave-local
/system clock
set time-zone-autodetect=no time-zone-name=Europe/Warsaw
/system routerboard settings
set protected-routerboot=disabled
[admin@MikroTik] > 
 
xslimakx
just joined
Topic Author
Posts: 6
Joined: Sat Aug 22, 2015 9:23 pm

Re: MT CRS as router on the stick for ESXi host

Fri Sep 18, 2015 7:27 am

One more thing - don't look @ vlan 11. It's my "production" so i didn't change the ip address assignment. Vlans we should focus on are 33 and 44.
 
User avatar
shadowskippie
Member Candidate
Member Candidate
Posts: 213
Joined: Tue Dec 21, 2010 6:20 pm

Re: MT CRS as router on the stick for ESXi host

Fri Sep 18, 2015 9:25 am

sorry, i was looking for an actually print so that i could see what the router was looking like.

ip address print, ip route print, interface print. if you can copy what it shows here. just want to make sure of some things.

One other thing. lets take the esxi host out of the equation, makes sure the problem is not with that system.

put two machines onto interfaces that are each connected to a different vlan. setup the gateways on the machines and then have them ping the other.
 
mpreissner
Member
Member
Posts: 357
Joined: Tue Mar 11, 2014 11:16 pm
Location: Columbia, MD

Re: MT CRS as router on the stick for ESXi host

Sat Sep 19, 2015 2:44 pm

You don’t need to use bridges…they’re CPU intensive, and they create the possibility of switching loops. They may get better performance than routing on certain models, but I think routing is much cleaner (personal preference). Are you trying to have the CRS do the inter-vlan routing, or do you have a router (as indicated on ether2) that you want to do the routing? I currently have a CRS226 hooked up to an RB750GL; the CRS functions only as a switch and all routing is handled by the 750. This model requires no bridges, and gets better routing performance than the CRS alone. You could do the routing with the CRS, and still not use bridges.

If you choose to use the CRS for routing, you need to add your VLAN interfaces (/interface vlan) to the Master port for the switch group (i.e. the one that can talk to the CPU for routing purposes). While you can have port 24 for ESXi as a standalone port, if you plan to put VLANs 33 and 44 on any other ports, I’d recommend you slave it to another port, and put your VLANs on the Master.

When carrying multiple VLANs on a single wire, it’s usually best to use a trunk port configuration, rather than a hybrid. To set up a trunk port, you have to allow the VLAN on the port, and you have to tag on egress. When setting up a trunk port, DO NOT use ingress-vlan-translation on that port.

Allow VLANs:
/interface ethernet switch vlan
add vlan-id=33 ports=ether24,switch1-cpu
add vlan-id=44 ports=ether24,switch1-cpu

Tag on egress:
/interface ethernet switch egress-vlan-tag
add vlan-id=33 tagged-ports=ether24,switch1-cpu
add vlan-id=44 tagged-ports=ether24,switch1-cpu

If you’re having ether24 act as a standalone port, you’ll also need to do the following:
/interface vlan
add name=vlan33 vlan-id=33 interface=ether24
add name=vlan44 vlan-id=44 interface=ether24

From here, you can add your IP addresses to your vlan interfaces:
/ip address
add address=192.168.33.1/24 interface=vlan33 network=192.168.33.0
add address=192.168.44.1/24 interface=vlan44 network=192.168.44.0

Finally, you need to make sure your ESXi host is tagging VLANs 33 and 34 on the interface. If you don’t tag, the packets won’t make it where they’re supposed to.

Who is online

Users browsing this forum: memo009525, vic666 and 42 guests