Community discussions

MikroTik App
 
User avatar
anav
Forum Guru
Forum Guru
Topic Author
Posts: 18958
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

What Type of WAN Connection Do I HAVE......

Thu Jan 17, 2019 10:17 pm

I have two wan connections a straightforward Cable connection where I can pull multiple dynamic IPs (but that dont change often).
The router easily connects and pulls an IP, no fuss no muss putting 0.0.0.0/0 in for default gateway works etc......

The other connection is via Bell Fiber. The line comes to an ONT and then comes out an ethernet cable tot he mikrotik router.
In the router I create.
a. a straight ethernet port much like cable.
b. create vlan 35 using the Base ethernet port as the interface.
c. Use the vlan as dhcp client.

The router searches for the vlan35 network and binds like the straight cable but no routing connectivity occurs automatically
I have to.
a. go to IP dhcp client
b. double click on the vlan35 interface client line
c. go to status tab
d. find the IP gateway IP for the ISP
e. place the gateway IP in the appropriate routing rule
THEN I AM connected.

So what kind of connection is this?
(Should I worry about MTU numbers or anything else??)
 
User avatar
sebastia
Forum Guru
Forum Guru
Posts: 1782
Joined: Tue Oct 12, 2010 3:23 am
Location: Antwerp, BE

Re: What Type of WAN Connection Do I HAVE......

Thu Jan 17, 2019 10:36 pm

Why didn't you configure dhcp client to put default route for you? Or if you want something fancy, use dhcp client script to "do the thing"?

MTU is normally auto-discovered. But if over plain ethnet, most likely plain 1500...
 
User avatar
anav
Forum Guru
Forum Guru
Topic Author
Posts: 18958
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: What Type of WAN Connection Do I HAVE......

Thu Jan 17, 2019 10:40 pm

Well I have a recursive fail over IP Routes setup.
that checks googe and if not up, then O OPEN DNS and if both of those fail then goes to secondary WAN.

I am open to any ideas you may have, but the router is only capable of coming up with a working accessible WAN connection with the VLAN, on A NEW LEASE, if I manually put in the IP gateway. If i recall, the default route will not work either due to the default rule does not work because there is no gateway IP established. (the router does not take the gateway IP from the bounded connection and put it in the IP route rule - I have to do this step).

How do i check what the MTU expectations are from the ISP?
 
User avatar
sebastia
Forum Guru
Forum Guru
Posts: 1782
Joined: Tue Oct 12, 2010 3:23 am
Location: Antwerp, BE

Re: What Type of WAN Connection Do I HAVE......

Thu Jan 17, 2019 11:52 pm

You mean like so https://wiki.mikrotik.com/wiki/Advanced ... per_Uplink

Can be done with script attached to your dhcp client config.
Use this example https://wiki.mikrotik.com/wiki/Manual:I ... pt_example, and add your specific stuff. Basically you would want to add two routes instead of one.

To discover MTU, you can use ping without fragmentation, one you pass MTU limit ping will stop working: ping -f -l <length> <host> (windows)
 
User avatar
anav
Forum Guru
Forum Guru
Topic Author
Posts: 18958
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: What Type of WAN Connection Do I HAVE......

Thu Jan 17, 2019 11:59 pm

Yes..........
/ip route
add check-gateway=ping distance=2 gateway=8.8.4.4 target-scope=10
add check-gateway=ping distance=3 gateway=208.67.220.220 target-scope=10
add distance=10 gateway=isp-2-gateway target-scope=10
add distance=2 dst-address=8.8.4.4/32 gateway=ISP_Main-gateway
add distance=3 dst-address=208.67.220.220/32 gateway=ISP_Main-gateway
add comment=Email_bypass distance=1 dst-address=24.222.0.20/32 gateway=\
isp-2-gateway

However, I fail to see how the script will work.
Unless the script can actually physically retrieve the ISP gateway from a bounded DHCP client connection, then the script will not be then able
to fill in the correct value in the IP route rule!
Default route setups DO NOT work.
 
User avatar
sebastia
Forum Guru
Forum Guru
Posts: 1782
Joined: Tue Oct 12, 2010 3:23 am
Location: Antwerp, BE

Re: What Type of WAN Connection Do I HAVE......

Fri Jan 18, 2019 12:06 am

Unless the script can actually physically retrieve the ISP gateway from a bounded DHCP client connection

Since you're so lazy :-p
Execute script on status change. This parameter is available in v6.39rc33+ These are available variables that are accessible for the event script:
bound - 1 - lease is added/changed; 0 - lease is removed
server-address - server address
lease-address - lease address provided by server
interface - name of interface on which client is configured
gateway-address - gateway address provided by server
vendor-specific - stores value of option 43 received from DHCP server
Example >>
 
User avatar
anav
Forum Guru
Forum Guru
Topic Author
Posts: 18958
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: What Type of WAN Connection Do I HAVE......

Fri Jan 18, 2019 6:04 am

Scripts = Greek

I dont know which are the variables I am supposed to fill in and I have no clue on how to add a second router, ie make a complete second script or somehow double up specific lines of the script, or double up variables in the script.

Not lazy just making too many assumptions about my skill levels....

Who is online

Users browsing this forum: tangent and 37 guests