Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
OpenWRT on Orange Pi Zero using Armbian uBoot and Kernel
1. Install Armbian_5.24.161216_Orangepizero_Ubuntu_xenial_3.4.113.img onto a uSD card using Win32DiskImager or Ubuntu Disk Image Writer
2. (Optional) Mount the uSD in Ubuntu Laptop and expand the partition using GParted.
3. Delete everything from uSD except /boot, /lib/modules and /lib/firmware.
4. Mount openwrt-15.05.1-sunxi-root.ext4 on Ubuntu using loopback interface on /mnt/openwrt
#mount -o loop openwrt-15.05.1-sunxi-root.ext4 /mnt/openwrt
5. Copy over the contents of /mnt/openwrt to the root of uSD by merging folders when prompted.
6. Modify /etc/init.d/boot and add 'ulimit -n 10000' before '/sbin/kmloader' command (line39).
7. Change directory to /lib/modules/3.4.113-sun8i - "#cd /lib/modules/3.4.113-sun8i"
8. Create - "#touch"
9. Edit - "#nano"
10. Copy the below contents into that file, save (Ctrl + O) and close (Ctrl + X) file.
for x in `find -name *.ko`
ln -s $x .
11. Then make executable - "#chmod +x"
12. Execute - "#./"
13. To enable WiFi - #printf "xradio_wlan\nxradio_wlan" >> /etc/modules.d/xradio_wlan
14. Replace Lan section in /etc/config/network with the below. (You can customize the below to suit you LAN and Router configuration.)
Option 1:
config interface 'lan'
option proto 'static'
option netmask ''
option ipaddr ''
option ifname 'eth0'
Option 2:
config interface 'lan'
option proto 'dhcp'
option ifname 'eth0'
15. Transfer the uSD to OPiZero and power up.
16. 'telnet', update password using '#passwd root' and then exit.
If you are unable to login,
wait for 10 mins to complete first boot up,
switch off OPiZero,
remove uSD and
repeat steps from network configuration using /etc/config/network
17. 'ssh' - peace.
Copy link

dodolloh commented Jan 4, 2017

can u explain about step 7.
i found error in step 7.
it is make file. sh? or just type in terminal
thx 4 attention.
please replay...

Copy link

dodolloh commented Jan 5, 2017

thx bro

Copy link

praveenbm5 commented Jan 5, 2017

Hello Dodolloh,

I have elaborated the previous step 7 into finer steps. Let me know if you still run into difficulties.

Copy link

hillz2 commented Jan 26, 2017

What are the bugs you've found so far ?

Copy link

darkcurrent commented Feb 18, 2017

Hi @praveenbm5,

I'am stuck at step 14 because there is no file named "network" in the directory of "/etc/config/" on the uSD card.

I think that the only difference I made was using "Armbian5.25Orangepizero_Ubuntu_xenial_default_3.4.113.img" image instead of your image you used in your document "Armbian5.24.161216Orangepizero_Ubuntu_xenial_3.4.113.img"

What do you suggest in this point?



Copy link

darkcurrent commented Feb 18, 2017

Hi again,

  1. I can not find "network" file so I created a file named "network" and put the static and dhcp config rows as you mentioned in step 14.
  2. When i transfer uSD to my orangepi zero and power it, ethernet lights gets off state in a short while and the leds on da orangepi zero board keep itself on (green led).
  3. Telnet and SSH connections wont work neither because there is no ethernet connection after powering up the board as i stated in second article

So what is your opinion @praveenbm5?

If you could help me, I'd appreciate it.


Copy link

zhenpengtang commented Mar 20, 2017

would u share the /etc/config/wireless and network files

Copy link

EUA commented Apr 22, 2017

This also works with LEDE
Only missing thing is WiFi interface at Luci.
Do you know that how to enable it?
PS: Here is how to do. :)

15. Enable wifi radio device, put this into /etc/config/wireless:

config wifi-device radio0
        option type     'mac80211'
        option channel  'auto'
        option path 'platform/soc/1c10000.mmc/mmc_host/mmc1/mmc1:0001/mmc1:0001:1'

Unfortunately, only could scan the WiFi. Not connects or AP mode via Luci, yet...

Copy link

Niagara104 commented May 12, 2017

step 10 : why create a script " ?
when you run the script "" > error

Copy link

podi-putha commented Jul 5, 2017

Hi Guys, I am dying to know how to use this as AP mode via Luci.. I've already taken a little effort. But still no use. Can somebody help me ?

Copy link

adrianmihalko commented Oct 17, 2017

Guys, I am following the guide, but I am unable to boot:

Begin: Running /scripts/init-bottom ... done.
mount: mounting /run on /root/run failed: No such file or directory
run-init: /sbin/init: No such file or directory
[ 3.640294] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00000100

/root/run is empty, /sbin/init is exist.

What's wrong here? Or could you please upload a working image?

Copy link

sonus89 commented Oct 23, 2017

Do you have a working image?

Copy link

fractalspace commented Nov 9, 2017

Here are pre-built OpenWrt flash images from orangepi website:

Copy link

lepz0r commented Sep 26, 2019

can you port newer openwrt to orange pi zero?

Copy link

kinggx9 commented Dec 3, 2019

I am using version 18 (Tried 15)
But still not successful
Don’t show wifi wireless network and don’t work

I have configured /etc/config/network

config interface 'loopback'
option ifname 'lo'
option proto 'static'
option ipaddr ''
option netmask ''

config globals 'globals'
option ula_prefix 'fdd0:3fab:1a10::/48'

config interface 'lan'
option ifname 'eth0'
option force_link '1'
option type 'bridge'
option proto 'static'
option ipaddr ''
option netmask ''
option ip6assign '60'

config interface 'wwan'
option proto 'dhcp'

I have configured /etc/config/network

config wifi-device 'radio0'
option type 'mac80211'
option hwmode '11g'
option path 'platform/sunxi-mmc.1/mmc_host/mmc1/mmc1:0001/mmc1:0001:1'
option htmode 'HT20'
option disabled '0'
option channel '2'
option txpower '20'
option country '00'
config wifi-iface
option network 'wwan'
option ssid 'AP CLIENT'
option encryption 'psk2'
option device 'radio0'
option mode 'sta'
option bssid 'C0:XX:E1:C1:E3:XX'
option key 'password'

Copy link

sajati commented Mar 24, 2021

do you have updated guide ? perhaps openwrt 19.xx.x for amlogic s905x devices ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment