OpenWRT open source on MikroTik devices (hAP ac2 etc.)

For more than 3 years I’m using 2 hAPac2 routers and am happy with them
(I have also some more MT devices like some big switches).

Just for fun today I installed the open source router software OpenWRT
on one of the hAPac2, initially just in RAM only for just testing first.
It works :slight_smile:
It has a WebGUI and a Linux shell as CLI with root access.
This means one can install packets from the OpenWRT repository,
as well write and run own programs on the router by using a
C/C++ cross-compiler toolchain (gcc) on the desktop PC.

I haven’t installed the toolchain yet (see link below), but will do soon.
I’ve some experience in such cross-compiler toolchains as I did similar some years ago on a MIPS board.

Since OpenWRT was installed in RAM (initramfs), after rebooting
the router again boots RouterOS, but one can of course also install OpenWRT on the flash memory.

I used this install guide (for Linux):
https://forum.openwrt.org/t/step-by-step-installation-on-a-mikrotik-hap-ac/151780

See also:
https://en.wikipedia.org/wiki/OpenWRT
https://openwrt.org/toh/mikrotik/start
https://openwrt.org/toh/mikrotik/hap_ac2

At MUM few years I asked MikroTik about packages like in OpenWRT, Asus. They told “no”. And years later they bring Docker.

But can docker be used on such a small device like the hAPac2 ?
As I understand it, docker requires much disk memory, 100+ MB or so, whereas such a hAPac2 has got only 128 MB :slight_smile:

USB flash for Docker? I did not try that.
Docker images could be really small, on Alpine Linux only few megabytes.
ac2 is an old device anyway to run ROS 7 on it.

Thank you for this thread.
I am not a network pro but I am interested in trying OpenWRT on a hAP ac3.

Some questions to start with:

  1. What are your impressions? How does it compare to RouterOS? Pros and cons?
  2. Does installing OpenWRT void the warranty of the device?
  3. Is it possible to revert to RouterOS safely?
  4. Is it possible to try it first, e.g. is it possible to install OpenWRT in a VM on a PC?

https://openwrt.org/toh/mikrotik/start
https://openwrt.org/toh/mikrotik/common

  1. I need to do some network programming and install the program on the router (I can’t and won’t use docker etc. for this).
    RouterOS is closed source and the user does not have any root access,
    OpenWrt is open source and the user has root access, so my task can be realized only in OpenWrt.

  2. I don’t think it has an effect on the warranty.
    But it is surely safer to do/try it first on an older similar hardware with expired warranty.

  3. Yes, it’s possible to revert to RouterOS safely. There are multiple methods:
    a) Install OpenWrt just in RAM only. At next reboot of the router it reverts back to RouterOS.
    b) Overwrite OpenWrt by doing a netinstall of RouterOS, and then restore from your backup file (named *.backup).

  4. I’m just a beginner in OpenWrt myself. I would say to try out the “Installing OpenWrt into RAM” method, see #3a above.

Here’s the OpenWrt doc:
https://openwrt.org/docs/start

@mutluit, the main issue is that the hAP ac3 doesn’t appear to be supported…

Many old supported routers can be purchased for almost nothing if one wants to try OpenWRT (all supported models are listed on the official site).

Yes, you are right. I think it’s just a matter of time till it gets supported. It depends on the demand from the users.

Update:
Just found this: ac3 is already supported. Check “ac3” in table below or at https://downloads.openwrt.org/releases/23.05.0/targets/ipq40xx/mikrotik/ :
MikroTik_hAP_ac3_supported.png

Thank you.
I would have to learn more.
BTW, currently openwrt.org seems down.