Community discussions

MikroTik App
 
danieltnc1981
newbie
Topic Author
Posts: 32
Joined: Sun Jul 16, 2017 1:27 pm

Subnet Mask 23 Work On Dhcp But Not Fixed Ip

Sun Sep 04, 2022 3:03 pm

Good morning everyone.
I have a mikrotik
Configured Lan on

192.168.1.0/23

Dhcp

192.168.0.1-192.168.1.254

The internet works, and so does the lan.

However, if on a device I set the following non-dhcp configuration with a fixed ip

192.168.0.6
255.255.254.0
192.168.1.1

I don't have internet and I don't surf in Lan

The netmask is right

Where am I wrong?

I set the netmask to 23 because 254 addresses are not enough for me.
 
User avatar
mkx
Forum Guru
Forum Guru
Posts: 11433
Joined: Thu Mar 03, 2016 10:23 pm

Re: Subnet Mask 23 Work On Dhcp But Not Fixed Ip

Sun Sep 04, 2022 3:10 pm

I have a mikrotik
Configured Lan on

192.168.1.0/23

....

192.168.0.6
255.255.254.0
192.168.1.1

Assuming the first IP address is router's LAN IP address (with /23 it's not subnet address), it seems like gateway address is set wrongly on your device with static settings.

But what exactly does "I don't surf in Lan" mean? Wrong gateway address setting doesn't block LAN communications, wrong subnet mask can block it, however combined with wrong IP address can effectively isolate device.
 
Njumaen
Frequent Visitor
Frequent Visitor
Posts: 77
Joined: Wed Feb 24, 2016 8:41 pm
Location: Bielefeld, Germany
Contact:

Re: Subnet Mask 23 Work On Dhcp But Not Fixed Ip

Sun Sep 04, 2022 3:36 pm

Network should be 192.168.0.0/23 !

Works fine here with DHCP and fixed IP.

Proven by using this https://www.calculator.net/ip-subnet-ca ... &x=68&y=10
 
danieltnc1981
newbie
Topic Author
Posts: 32
Joined: Sun Jul 16, 2017 1:27 pm

Re: Subnet Mask 23 Work On Dhcp But Not Fixed Ip

Sun Sep 04, 2022 5:54 pm

Basically my situation was that initially I had the gw on 192.168.1.0/24, the gateway was 192.168.1.1.
Now I have to add a new netmask, I have run out of dhcp addresses.
So in my mikrotik I entered 192.168.1.0/23, and as dhcp from 192.168.0.1 to 192.168.1.254
So do I have to change the address of the gw as well?
I don't understand
 
biomesh
Long time Member
Long time Member
Posts: 561
Joined: Fri Feb 10, 2012 8:25 pm

Re: Subnet Mask 23 Work On Dhcp But Not Fixed Ip

Sun Sep 04, 2022 8:48 pm

You can leave the router/gateway address the way it is, but set the network to 192.168.0.0 on the interface that has 192.168.1.1 assigned.
 
joegoldman
Forum Veteran
Forum Veteran
Posts: 766
Joined: Mon May 27, 2013 2:05 am

Re: Subnet Mask 23 Work On Dhcp But Not Fixed Ip

Mon Sep 05, 2022 12:34 am

If you're gateway still has 192.168.1.0 in NETWORK setting it may not work. The subnet/network is 192.168.0.0/23, 192.168.1.0/23 is not valid, but an address of 192.168.1.1/23 is valid - best thing to do is probably post your config export so we can see if there's any misconfiguration on your network side.

Any other devices still on 192.168.1.0/24 would not be able to talk to devices in 192.168.0.X, and that can also be affected by what DHCP settings you have, making sure all network statements are correct.

Who is online

Users browsing this forum: hatred, mszru, svmk and 36 guests