Hi all ;
i have the following ip’s from a wireless isp and i want to put a MikroTik OS behind it to make the service better to the client .
the ip’s as follow
ip : 10.80.40.44
subnet : 255.0.0.0
gateway and dns : 10.1.1.1
when i would like to add the route for this connection , it don’t which interface should make the routing and it give an unknown for the interface .
how to route such ip’s when the ip is not in the same range of the gateway ?
with best regards .
I guess I am missing the point. The IP address set you posted is in the same range (subnet) as the gateway you posted. It is the netmask that determines how much of that address is local.
Hi ;
First thanks for your reply .
let say you have a pc with MikroTik OS with two lan cards , the first is wan for the internet and the second is lan for the clients .
after you configue the ip addresses for the lan cards with
ip : 10.80.40.44
subnet : 255.0.0.0
for the wan and when you go to / ip route and you add the following static route :
/ ip route
add dst-address=0.0.0.0/0 gateway=10.80.40.1 scope=255 target-scope=10
comment=“” disabled=no
you will see that the route recognize the interface named wan for this route and you could reach your gateway and internet .
but if you trye to add the following static route :
/ ip route
add dst-address=0.0.0.0/0 gateway=10.1.1.1 scope=255 target-scope=10
comment=“” disabled=no
it will not recognize the lan card which will connect the MT to the isp gateway and it give you unknown for the interface .
i hope this will help you more .
waiting your feedback .
with best regards .
Check /ip address
Insure the address you have assigned to ether1 (or your wan port) is correct.
Should be 10.80.40.44/8 ← notice the ‘8’
Then I use
/ip route add gateway=10.1.1.1
BTW, this IP assignment prevents you from using any 10.x.x.x IP address on your local ports.
Hi ;
Thanks for this information maybe i was using it as /24 , i will try it today and see if the MT will recognize the ethernet card or not .
what do you mean by it will prevent me from using any 10.x.x.x ip address on my local ports ?
waiting your feedback .
with best regards .
Hi again ;
Thanks again for your help .
i test it and it works fine , it was i fault . i think i used / 24 which made the problem .
i need to ask you about the routing .
you said the network 10.1.1.1 - 10.255.255.255 are pc’s belong to wan network so i can not use them as another network .
i am testing a server with these ip’s :
wan 192.168.3.3/24
lan 192.168.6.1/24
i think they are seprate networks and i could use them , what do you see ? .
with best regards .