Second dhcp server invalid - any suggestions?

Hello!

I am trying to set different dhcp server for each vlan interface.

1 dhcp for first vlan interface works perfectly but second does not work :frowning: .

I dont know what could be wrong....So simple task and such a big problem....

CONFIGURATION:

NAME INTERFACE RELAY ADDRESS-POOL LEASE-TIME ADD-ARP

0 dhcp1 vlan dhcp_pool6 3d
1 I dhcp2 vlan1 dhcp_pool12 3d

ADDRESS GATEWAY DNS-SERVER WINS-SERVER DOMAIN

0 10.5.50.0/24 10.5.50.1 192.168.1.254
1 10.6.50.0/24 10.6.50.1 192.168.1.254

Thank you in advance!

Post the output of:

/ip address print detail
/ip route print detail
/interface print
/interface ethernet print
/interface vlan export
/ip dhcp-server export
/ip pool export

and wrap it in code tags. What you posted isn’t sufficient to determine what causes the DHCP server instance to be invalid.

Thank you for your prompt reply Fewi!

[admin@MikroTik] > /ip address print detail
Flags: X - disabled, I - invalid, D - dynamic 
 0   ;;; default configuration
     address=192.168.88.1/24 network=192.168.88.0 broadcast=192.168.88.255 
     interface=ether1 actual-interface=ether1 

 1   ;;; hotspot network
     address=10.5.50.1/24 network=10.5.50.0 broadcast=10.5.50.255 
     interface=vlan actual-interface=vlan 

 2 D address=192.168.1.132/24 network=192.168.1.0 broadcast=192.168.1.255 
     interface=ether1 actual-interface=ether1 
[admin@MikroTik] > /ip route print detail
Flags: X - disabled, A - active, D - dynamic, 
C - connect, S - static, r - rip, b - bgp, o - ospf, m - mme, 
B - blackhole, U - unreachable, P - prohibit 
 0 ADS  dst-address=0.0.0.0/0 gateway=192.168.1.254 
        gateway-status=192.168.1.254 reachable ether1 distance=0 scope=30 
        target-scope=10 

 1 ADC  dst-address=10.5.50.0/24 pref-src=10.5.50.1 gateway=vlan 
        gateway-status=vlan reachable distance=0 scope=10 

 2 ADC  dst-address=192.168.1.0/24 pref-src=192.168.1.132 gateway=ether1 
        gateway-status=ether1 reachable distance=0 scope=10 

 3 ADC  dst-address=192.168.88.0/24 pref-src=192.168.88.1 gateway=ether1 
        gateway-status=ether1 reachable distance=0 scope=10 
[admin@MikroTik] > /interface print
Flags: D - dynamic, X - disabled, R - running, S - slave 
 #     NAME                                        TYPE             MTU   L2MTU
 0  R  ;;; WAN
       ether1                                      ether            1500  1526 
 1  R  ;;; WLAN
       vlan                                        wlan             1500  2290 
 2     vlan1                                       wlan             1500  2290 
[admin@MikroTik] > /interface ethernet print
Flags: X - disabled, R - running, S - slave 
 #    NAME      MTU   MAC-ADDRESS       ARP        MASTER-PORT      SWITCH     
 0 R  ;;; WAN
      ether1    1500  00:0C:42:94:AC:36 enabled   
[admin@MikroTik] > /interface vlan export
# jan/02/1970 00:19:34 by RouterOS 4.11
# software id = EBEW-YEIH
#
[admin@MikroTik] > /ip dhcp-server export
# jan/02/1970 00:19:34 by RouterOS 4.11
# software id = EBEW-YEIH
#
/ip dhcp-server
add address-pool=dhcp_pool1 authoritative=after-2sec-delay bootp-support=\
    static disabled=no interface=vlan lease-time=3d name=dhcp1
add address-pool=dhcp_pool2 authoritative=after-2sec-delay bootp-support=\
    static disabled=no interface=vlan1 lease-time=3d name=dhcp2
/ip dhcp-server config
set store-leases-disk=5m
/ip dhcp-server network
add address=10.5.50.0/24 comment="" dns-server=192.168.1.254 gateway=\
    10.5.50.1
add address=10.6.50.0/24 comment="" dns-server=192.168.1.254 gateway=\
    10.6.50.1
[admin@MikroTik] > /ip pool export
# jan/02/1970 00:20:09 by RouterOS 4.11
# software id = EBEW-YEIH
#
/ip pool
add name=dhcp_pool1 ranges=10.5.50.2-10.5.50.254
add name=dhcp_pool2 ranges=10.6.50.2-10.6.50.254
[admin@MikroTik] >

The ‘vlan1’ is a WLAN interface, and it’s not running. Probably because no one is connected. DHCP servers on interfaces that aren’t running are invalid. The moment the WLAN interface comes up due to someone being connected the DHCP server will be valid.

Thank you for your help … Problem solved!!!