How to add file to /etc/modules for HOST OS

Hello. How can i add wifi dongle driver for HOST OS to /etc/modules from service ? Or any other way ? Thank you.

Hi there. Another user has documented their method to doing this in the following forum thread: How to build custom kernel modules. Here is also an example project that may be useful:

Hopefully these can be useful to you

So the answer, i only need to compile custom balenaOS? But i already have a file , and right now i am doing next on HOST:

mount -ro remount,rw /
wget -O /lib/firmware/mt7601u.bin
sleep 10 && reboot &

How can i automate this ?

Hi there,

Unless for some reason that module cannot be built out-of-tree, you should actually be able to do all this from a regular service defined in your docker-compose.yml. Have a look at the following forum thread for more nuance regarding building wifi kernel modules: How can I configure tp-link wifi adapter

Is that not working for you, or perhaps there’s something else blocking you from doing that?

Hi. I do not need build. I have file. I need to put it on HOST file system to /lib/firmware/ dir. How can i do that from Guest docker app ? Is it possible ?

Maybe i can put somewhere to iso with resin-image-fs tool ?

Currently there is not a way to inject a file like this firmware in the root fs which will be preserved after OS update, so we do not have a way for doing this that we would recommend. We are currently working on a solution for this, but it is not ready yet unfortunately.

The proper way for handling this is for us to include the firmware in a next OS release. I see you are copying mt7601u.bin - is this for a Ralink MT7601U wireless adapter? Also what is the device that you are using - a Raspberry Pi or a different one?

Yes, Ralink MT7601U and Raspberry Pi. It will be great.

Thank you for the information @sergbbb,

Which specific model of the Raspberry Pi are you targeting?


Raspberry Pi 3

ср, 2 дек. 2020 г. в 19:08, Nicolas Tzovanis via balenaForums <>:

Hi, we have created an issue to add this support to balenaOS, We will update this ticket once the issue is resolved.

Hi! I’d like to tag on to this thread. I’m currently using an UP-Board and it’s official Wifi Kit. lsusb shows that to be the same chipset, MT7601U. So having that driver available for UP-Board as well would be great!

Hey there - thanks for letting us know. I’ve added your voice to the github issue for this.