Creating an image to flash to multiple routers

Hello,

I am not really a developer or wrt wizard yet the task has fallen to me to at my small company to figure out and set up many Beryl AX (GL-MT3000) routers as part of our product solution. These come with a custom fork of OWRT from GL.iNet.

I had initially wanted to simply utilize the custom version of OWRT that GL.iNet provides with the routers, configure the router, make a configuration archive, and restore new routers to that configuration file. However I ran into a bug(?) where entries in my dhcp file were being edited every time I started the router.

The solution seems to be installing the appropriate version of OWRT from the table of hardware and configuring that instead. After some testing I have confirmed the dhcp file issues I was having are resolved/not present in this version.

I would like to be able to simply clone the image from the configured router onto the other 20+ routers I need to set up, rather than having to flash and restore separately.

Thanks.

The best method is to use a first-boot UCI script that you can embed into a customized OpenWrt image.

1 Like

Do you have any learning resources for achieving this that you would recommend?

https://openwrt.org/docs/guide-user/base-system/uci

Once you have a script, you can add that to the image via the firmware selector custom build option. This script will run on the firstboot (i.e. first time booting after install or reset of the firmware).

I'd recommend starting simple -- add one or two entries to prove it is working, then expand as needed.

4 Likes