Community discussions

MikroTik App
 
wpn
just joined
Topic Author
Posts: 3
Joined: Wed May 25, 2022 12:01 pm

Dumb AP: Static IP and DHCP Client

Wed May 25, 2022 12:13 pm

Hey guys,

I configured my fist hap ac2 with Quick Set as "Home AP". All working fine. I then decided to put ether1 to the bridge, too. So I can use it as additional port and can run package updates (seems that has to be port 1). Also working fine.

My question: under IP > Addresses I now have a static IP as well as an IP from the active DHCP client (IP > DHCP). I now thought I could deactivate the DHCP client as the static IP would enough but then I also lose the Gateway address and DNS server coming over the DHCP client. How do I configure the Gateway and DNS server without DHCP client? Or should I just let it be and let the AP have two IPs?

Thanks a lot for your explanation!
 
tdw
Forum Guru
Forum Guru
Posts: 1843
Joined: Sat May 05, 2018 11:55 am

Re: Dumb AP: Static IP and DHCP Client

Wed May 25, 2022 2:05 pm

You can add a default route under IP > Route and a DNS server under IP > DNS. Alternatively if the router you are connecting this Mikrotik to supports static DHCP leases you could assign an address that way.
 
wpn
just joined
Topic Author
Posts: 3
Joined: Wed May 25, 2022 12:01 pm

Re: Dumb AP: Static IP and DHCP Client

Thu May 26, 2022 12:03 am

Thanks for the tips! I am slowly getting the hang of it.

I now deactivated the DHCP server and the DNS server is now empty. In Routes there is still one entry left:
Dst. Address 192.168.3.0/24 with Gateway %bridge - and everything still works fine. All devices still do get correct IPv4 and IPv6 addresses and DNS servers. Is that too good to be true or just how it should be? I rebooted already several times.

What did not work was searching for package updates on the router. So I put the entry
Dst. Address 0.0.0.0/0 with Gateway 192.168.3.1 back in place. Now that works too. DNS still empty. Is it that simple?

Thanks a lot!
 
tdw
Forum Guru
Forum Guru
Posts: 1843
Joined: Sat May 05, 2018 11:55 am

Re: Dumb AP: Static IP and DHCP Client

Thu May 26, 2022 12:53 am

For the route, yes. I suspect updates worked because the DNS entry was cached, add 192.168.3.1 as a DNS server too.

RouterOS can be rather a steep learning curve, it is basically linux underneath with a custom user interface on top.
 
User avatar
anav
Forum Guru
Forum Guru
Posts: 19105
Joined: Sun Feb 18, 2018 11:28 pm
Location: Nova Scotia, Canada
Contact:

Re: Dumb AP: Static IP and DHCP Client

Thu May 26, 2022 1:01 am

See the example below culled from this link........... viewtopic.php?t=182276

Assumes no vlans, just bridge and etherports....... and assumes the main subnet is 192.168.1.0 ..........
The example on the link has vlans.......
/interface bridge
add ingress-filtering=no name=bridge
/interface list
add name=management
/interface wireless
as required
/interface wireless security-profiles
as required
/interface bridge port
add bridge=bridge interface=ether1
add bridge=bridge comment=defconf interface=ether2
add bridge=bridge comment=defconf interface=wlan1
/ip neighbor discovery-settings
set discover-interface-list=management
/interface list member
add interface=bridge list=management
/ip address
add address=192.168.1.x/24 interface=bridge network=192.168.1.0  
/ip dns
set allow-remote-requests=yes servers=192.168.1.1 
/ip route
add disabled=no dst-address=0.0.0.0/0 gateway=192.168.1.1 
/ip service
set telnet disabled=yes
set ftp disabled=yes
set www disabled=yes
set ssh address=x.x.x.x
set api disabled=yes
set winbox address=as-required
set api-ssl disabled=yes
/tool mac-server
set allowed-interface-list=none
/tool mac-server mac-winbox
set allowed-interface-list=management
 
wpn
just joined
Topic Author
Posts: 3
Joined: Wed May 25, 2022 12:01 pm

Re: Dumb AP: Static IP and DHCP Client

Thu May 26, 2022 12:54 pm

Very helpful and everything works as expected. Thanks you guys, very much appreciated!

Who is online

Users browsing this forum: Ahrefs [Bot], dozer46 and 37 guests