Openwrt Router Firmware

tanchoo1

Master Member
Joined
Feb 12, 2008
Messages
3,135
Reaction score
687
For those of you interested in re-purposing your old mini-PC as an OpenWrt router, read on.

Main idea: Your existing wireless routers become dumb APs (no DHCP server, no DNS). Your old mini-PC becomes the actual router, and since even pretty old mini-PCs will easily have at least a couple of times the processing power of modern routers as well as a lot more memory and disk space, you can run OpenWrt x86/64 on it and turn it into a powerhouse running all kinds of useful "stuff".

Any old mini-PC will do. Even a crappy old Intel i5-4590T works wonders. AMD works well too. Minimally, it must have a 1000 Mbps RJ-45 Ethernet Port, at least one USB 3.0 port, and another USB port to connect your keyboard. HDMI is also required to connect to a display.

Side note: you would generally want a build that consumes minimal power at idle. I would say 4W - 6W is ideal. More is fine of course but do work out your monthly cost accordingly.

(Interesting note: I have even gotten this to work with old laptops since many of them fit the above requirements, plus they have their own display. The power consumption is surprisingly low at idle as well because they are designed to not drain laptop batteries quickly, so it actually works well when you run it off AC power. Only thing is that laptops are usually not designed to be turned on 24/7 and tends to generate more heat. Your mileage will vary.)

I suggest using the built in RJ-45 Ethernet Port as LAN, and a UGreen Ethernet Adapter 2500Mbps USB-C/A to RJ45 (for example: https://shopee.sg/product/859347743/27579031991) as WAN. Cheaper adapters tend to have dodgier builds whereas I have found the above UGreen adapter to be super solid. It only costs about SGD 20 so don't stinge as you want your network connection to be rock solid. For the above adapter, you will need to do "opkg update && opkg install kmod-usb-net-rtl8152". You will then see the following at bootup: r8152 x-x:x.x: load rtl8156b-2 v3 10/20/23 successfully

And there you have it. Once your hardware is sorted, you simply install OpenWrt x86/64 into your hard disk and you're good to go. There's a lot you can do with it and it would be the most powerful consumer router that you can have at an extremely low cost.

Once you have installed the latest OpenWrt 24.10.2 on it, be sure to install owut: "opkg update && opkg install owut". This makes future updates as easy as "owut upgrade". It builds a custom firmware for you based on your existing packages, downloads it, checks the checksum, and then installs the new firmware which will result in a reboot. This takes about five minutes in total. Makes future updates so much easier.

Here is the official OpenWrt x86 guide to get you started: https://openwrt.org/docs/guide-user/installation/openwrt_x86

Signing off for now. Open to questions and for experts to weigh in.
 
Last edited:

rainbow99

Master Member
Joined
May 16, 2002
Messages
2,716
Reaction score
62
if i setup a mini-PC without wifi adapter as an OpenWrt router, and then a wireless router as ap to provide wireless connectivity to my home devices, can i still connect to the mini-PC wirelessly to configure the luci settings? Is it still the default openwrt ip? i dont have any lan points setup at home. thanks.
 

xiaofan

High Supremacy Member
Joined
Sep 16, 2018
Messages
35,801
Reaction score
12,038
if i setup a mini-PC without wifi adapter as an OpenWrt router, and then a wireless router as ap to provide wireless connectivity to my home devices, can i still connect to the mini-PC wirelessly to configure the luci settings? Is it still the default openwrt ip? i dont have any lan points setup at home. thanks.

This is the typical setup anyway if you use a mini PC to run OpenWRT.

ONT --> Mini PC running OpenWRT as main router (wired, no wireless) --> wireless AP (including wireless router running in AP mode)

Example:
OpenWRT LAN IP --> 192.168.1.1 (running the DHCP server)
Wireless AP IP address --> 192.168.1.88
Your wireless client --> 192.168.1.168

From your wireless client, you can access the OpenWRT UI at 192.168.1.1 and your wireless AP web UI at 192.168.1.88.
 

xiaofan

High Supremacy Member
Joined
Sep 16, 2018
Messages
35,801
Reaction score
12,038
If you buy new Mini PC to run as an OpenWRT router, I tend to recommend buying one with quad NICs and then you can use Proxmox and run virtual OpenWRT (one NIC for Proxmox management, two NICs for OpenWRT, another one for spare or for OpenWRT which you can have two LAN segments).

If you run OpenWRT bare metal, you can do with those mini PCs with two NICs, still I tend to like to use those with at least quad NICs.

When you buy the mini PC, make sure you have minimum 8GB RAM and 128GB/256GB storage. You can re-purpose the mini PC as Linux machine later. My first mini PC running OpenWRT was an Intel J4105 CPU based mini PC with 8GB RAM, 256GB Storage and quad Inel I210 gibabit NICs, bought in Jan 2021. It was running Proxmox and virtual OpenWRT for my Singtel 1Gbps plan. It was retired in Oct 2023 when I changed to another mini PC with Intel N100 CPU and quad Intel I226-V 2.5Gbe NICs.

Recently I repurposed the Intel J4105 Mini PC to run Arch Linux and it runs Arch Linux pretty fine.
 

tanchoo1

Master Member
Joined
Feb 12, 2008
Messages
3,135
Reaction score
687
if i setup a mini-PC without wifi adapter as an OpenWrt router, and then a wireless router as ap to provide wireless connectivity to my home devices, can i still connect to the mini-PC wirelessly to configure the luci settings? Is it still the default openwrt ip? i dont have any lan points setup at home. thanks.
I think I understand the question.

Since the mini-PC doesn't have any wireless capabilities, you must have a wired backhaul connecting the mini-PC to each of your dumb APs. Else there will be no way to reach the mini-PC from the dumb APs.
 

tanchoo1

Master Member
Joined
Feb 12, 2008
Messages
3,135
Reaction score
687
If you buy new Mini PC to run as an OpenWRT router, I tend to recommend buying one with quad NICs and then you can use Proxmox and run virtual OpenWRT (one NIC for Proxmox management, two NICs for OpenWRT, another one for spare or for OpenWRT which you can have two LAN segments).

If you run OpenWRT bare metal, you can do with those mini PCs with two NICs, still I tend to like to use those with at least quad NICs.

When you buy the mini PC, make sure you have minimum 8GB RAM and 128GB/256GB storage. You can re-purpose the mini PC as Linux machine later. My first mini PC running OpenWRT was an Intel J4105 CPU based mini PC with 8GB RAM, 256GB Storage and quad Inel I210 gibabit NICs, bought in Jan 2021. It was running Proxmox and virtual OpenWRT for my Singtel 1Gbps plan. It was retired in Oct 2023 when I changed to another mini PC with Intel N100 CPU and quad Intel I226-V 2.5Gbe NICs.

Recently I repurposed the Intel J4105 Mini PC to run Arch Linux and it runs Arch Linux pretty fine.
Adding on to Xiaofan's excellent advice, yes if you have money to spend on a brand new mini-PC, go for one with minimum of two NICs. Then one port is LAN and the other is WAN, and there is no need for USB to RJ45 adapters.

If you prefer not to contribute to e-waste due to environmental and/or budget concerns, then you may repurpose your old mini-PCs, or purchase used enterprise grade mini-PCs online. Enterprise grade mini-PCs tend to be used for only three years before being disposed of; they will easily last for many more years as they are very durable.

I have had success with a cheap consumer grade Beelink mini-PC with the J4125 processor and 8GB RAM (even 4GB is plenty for OpenWrt for most use cases). Used it for years without any issues. Currently I am using a used HP EliteDesk 800 G4 with the Intel i5-8500T processor and 16GB RAM. Needless to say, it is overkill for my simple requirements and runs flawlessly with a load average of 0.00 most of the time.

Even the J4125 would have a load average of 0.00 most of the time as well as generally routers require very little CPU processing power.
 

tanchoo1

Master Member
Joined
Feb 12, 2008
Messages
3,135
Reaction score
687
A valid question is, why bother with OpenWrt and modularizing the entire setup with dumb APs and a dedicated router?

This is a great question. 95% (99%?) of people will not need this setup, and stock router firmware that comes bundled with ISP packages are good enough.

However, there are a small number of people who would like this setup for the following reasons.

1. They are technical enough; requiring at least basic networking knowledge.
2. They like to tinker.
3. They do not like stock firmware as they stop getting firmware updates pretty quickly, leaving them vulnerable to zero-day attacks.
4. They do not like stock firmware as they do not trust stock firmware. Most (all?) of them are riddled with backdoors.
5. They want to modularize their setup so that there isn't a single point of failure in their home network as is typical with single router setups (though to be fair the chance of this happening is very low).
6. They want to reduce e-waste and would like to repurpose old routers and mini-PCs as dumb APs and routers respectively.

Let's be clear that this isn't for everyone; however for home network tinkering enthusiasts with some basic networking knowledge, this could be a really interesting and fruitful home project at minimal cost.
 

a4973

Master Member
Joined
Sep 13, 2003
Messages
3,377
Reaction score
370
A valid question is, why bother with OpenWrt and modularizing the entire setup with dumb APs and a dedicated router?

This is a great question. 95% (99%?) of people will not need this setup, and stock router firmware that comes bundled with ISP packages are good enough.

However, there are a small number of people who would like this setup for the following reasons.

1. They are technical enough; requiring at least basic networking knowledge.
2. They like to tinker.
3. They do not like stock firmware as they stop getting firmware updates pretty quickly, leaving them vulnerable to zero-day attacks.
4. They do not like stock firmware as they do not trust stock firmware. Most (all?) of them are riddled with backdoors.
5. They want to modularize their setup so that there isn't a single point of failure in their home network as is typical with single router setups (though to be fair the chance of this happening is very low).
6. They want to reduce e-waste and would like to repurpose old routers and mini-PCs as dumb APs and routers respectively.

Let's be clear that this isn't for everyone; however for home network tinkering enthusiasts with some basic networking knowledge, this could be a really interesting and fruitful home project at minimal cost.
Well said!! For me the reasons are 3. and 4. why I chose to go the openwrt route.
 

rainbow99

Master Member
Joined
May 16, 2002
Messages
2,716
Reaction score
62
For those of you interested in re-purposing your old mini-PC as an OpenWrt router, read on.

Main idea: Your existing wireless routers become dumb APs (no DHCP server, no DNS). Your old mini-PC becomes the actual router, and since even pretty old mini-PCs will easily have at least a couple of times the processing power of modern routers as well as a lot more memory and disk space, you can run OpenWrt x86/64 on it and turn it into a powerhouse running all kinds of useful "stuff".

Any old mini-PC will do. Even a crappy old Intel i5-4590T works wonders. AMD works well too. Minimally, it must have a 1000 Mbps RJ-45 Ethernet Port, at least one USB 3.0 port, and another USB port to connect your keyboard. HDMI is also required to connect to a display.

Side note: you would generally want a build that consumes minimal power at idle. I would say 4W - 6W is ideal. More is fine of course but do work out your monthly cost accordingly.

(Interesting note: I have even gotten this to work with old laptops since many of them fit the above requirements, plus they have their own display. The power consumption is surprisingly low at idle as well because they are designed to not drain laptop batteries quickly, so it actually works well when you run it off AC power. Only thing is that laptops are usually not designed to be turned on 24/7 and tends to generate more heat. Your mileage will vary.)

I suggest using the built in RJ-45 Ethernet Port as LAN, and a UGreen Ethernet Adapter 2500Mbps USB-C/A to RJ45 (for example: https://shopee.sg/product/859347743/27579031991) as WAN. Cheaper adapters tend to have dodgier builds whereas I have found the above UGreen adapter to be super solid. It only costs about SGD 20 so don't stinge as you want your network connection to be rock solid. For the above adapter, you will need to do "opkg update && opkg install kmod-usb-net-rtl8152". You will then see the following at bootup: r8152 x-x:x.x: load rtl8156b-2 v3 10/20/23 successfully

And there you have it. Once your hardware is sorted, you simply install OpenWrt x86/64 into your hard disk and you're good to go. There's a lot you can do with it and it would be the most powerful consumer router that you can have at an extremely low cost.

Once you have installed the latest OpenWrt 24.10.2 on it, be sure to install owut: "opkg update && opkg install owut". This makes future updates as easy as "owut upgrade". It builds a custom firmware for you based on your existing packages, downloads it, checks the checksum, and then installs the new firmware which will result in a reboot. This takes about five minutes in total. Makes future updates so much easier.

Here is the official OpenWrt x86 guide to get you started: https://openwrt.org/docs/guide-user/installation/openwrt_x86

Signing off for now. Open to questions and for experts to weigh in.

i tried setting up but stuck, sigh. if i setup the openwrt on a usb drive, i can boot into the target x86/64 machine (see a message on promiscuous mode, not sure whether it's normal). But after that, I'm not sure how to flash openwrt into the ssd so that i dont need the usb drive anymore.

I read some guides to setup a usb drive with live linux instead, and I can also boot into the target x86 machine using the linux usb. But stuck there also.

I saw some guide to use dd, but I'm not sure at which step i should do that.

Is there a step-by-step guide i can use? Thanks.
 

TanKianW

Supremacy Member
Joined
Apr 21, 2005
Messages
6,899
Reaction score
3,605
i tried setting up but stuck, sigh. if i setup the openwrt on a usb drive, i can boot into the target x86/64 machine (see a message on promiscuous mode, not sure whether it's normal). But after that, I'm not sure how to flash openwrt into the ssd so that i dont need the usb drive anymore.

I read some guides to setup a usb drive with live linux instead, and I can also boot into the target x86 machine using the linux usb. But stuck there also.

I saw some guide to use dd, but I'm not sure at which step i should do that.

Is there a step-by-step guide i can use? Thanks.

Try these?



 
Last edited:

rainbow99

Master Member
Joined
May 16, 2002
Messages
2,716
Reaction score
62
Try these?




thanks bro. To better understand, the first video is to setup the hard drive where the openwrt is to be installed using another pc first, before putting the openwrt drive inside the target x86 machine?

For the second video, it doesnt seem to have any step to put the openwrt into the ssd?

pardon me if i misunderstood because new to this.

in my case, i already setup the x86 pc physically.

i saw from one of the guides the following steps, but don't quite understand how to do it, whether i boot into the target x86 machine using a linux usb drive or a openwrt usb drive:

------------------
But if you cannot remove the storage from the device (or do not have an adapter to connect them to the PC), you can write OpenWrt on a USB drive (or another removable storage device), then you can then insert it in a USB port or slot. When booting select the drive where you installed OpenWrt.

Then you need to identify how is the internal storage device called with lsblk or dmesg:

opkg update
opkg install lsblk
lsblk
dmesg | grep -e sd
------------------
 

TanKianW

Supremacy Member
Joined
Apr 21, 2005
Messages
6,899
Reaction score
3,605
thanks bro. To better understand, the first video is to setup the hard drive where the openwrt is to be installed using another pc first, before putting the openwrt drive inside the target x86 machine?

For the second video, it doesnt seem to have any step to put the openwrt into the ssd?

pardon me if i misunderstood because new to this.

in my case, i already setup the x86 pc physically.

Video 1: Flash a bootable Linux (OS) drive to the USB drive. Boot from the bootable USB drive to download the OpenWRT firmware and flash it to the HDD with OpenWRT, then boot from it. The tutorial using Finnix OS, for beginners, Ubuntu might be a more user-friendly option.

Video 2: Flash the USB drive with OpenWRT and boot directly from it.

Option 3: Connect your internal HDD to another PC using a "drive enclosure/adapter" over USB and flash the firmware directly to it. Then connect to the target system and boot from the HDD.

If the HDD has been set up with OpenWRT, simply select it to boot in the BIOS. You might need to disable "Secure Boot" in the BIOS.​
 

grynove

Senior Member
Joined
Feb 7, 2006
Messages
1,535
Reaction score
49
anyone having random disconnection issues with wireless for macos user? been having weird disconnection. windows client are working without issues.
i did some digging. mentioned that we need to separate 2.4 and 5g ssid. also disable fast roaming. im still having random disconnection after. although is much better.
 

tanchoo1

Master Member
Joined
Feb 12, 2008
Messages
3,135
Reaction score
687
anyone having random disconnection issues with wireless for macos user? been having weird disconnection. windows client are working without issues.
i did some digging. mentioned that we need to separate 2.4 and 5g ssid. also disable fast roaming. im still having random disconnection after. although is much better.

I would say an easy fix is to give different SSID names for the 2.4 GHz and 5 GHz bands. Perhaps one can end in -2G and the other can end in -5G. Then, connect only to the -5G SSID.

If this doesn't work, then we would need more information:

1. What is the exact brand and model of your router?
2. Are you running OpenWrt? If so, which version exactly?
3. What is the exact model of your Macbook? What version of MacOS exactly?
 
Last edited:

grynove

Senior Member
Joined
Feb 7, 2006
Messages
1,535
Reaction score
49
1. AW1000 Arcadyan running snapshot r24698. Kinda afraid to flash other firmware cause this is my only router at the moment.
2. Snapshot r24698
3. Macbook Air M2 runs on Monterey 12.4

SSID on Ch 149 80Mhz WMM On. WPA2 PSK Auto
. disabled 802.11r. optional 802.11w.
 

tanchoo1

Master Member
Joined
Feb 12, 2008
Messages
3,135
Reaction score
687
1. AW1000 Arcadyan running snapshot r24698. Kinda afraid to flash other firmware cause this is my only router at the moment.
2. Snapshot r24698
3. Macbook Air M2 runs on Monterey 12.4

SSID on Ch 149 80Mhz WMM On. WPA2 PSK Auto
. disabled 802.11r. optional 802.11w.
Wow.

Like I said I think the easiest fix is to give the 2.4GHz and 5GHz bands different SSID names. Have you already tried that?

Else it really just boils down to old firmware (Snapshot r24698 is so last year) and Monterey??? That's 2021.
 

xiaofan

High Supremacy Member
Joined
Sep 16, 2018
Messages
35,801
Reaction score
12,038
Interesting discussion here -- I am not using IDS/IPS myself but it is interesting to know that HW/SW offloading may interfere with SNORT IDS/IPS.

https://forum.openwrt.org/t/intel-n...00-mbit-line-without-cpu-saturation/237093/57

****************
This is absolutely correct, there is nothing wrong with OpenWRT or the software/hardware flow offloading feature.

Flow offloading will cause all packets in an allowed connection to bypass all of your firewall chains and rules, thus lowering cpu load and increasing throughput.

Your snort nfq rules are also somewhere in one of those chains, therefore they are also bypassed - by design.


Edit: that was not meant specifically to you, lantis, you obviously already understand.

Extra edit: This guy explains it way better than I ever could.

Ur79POx.png


********************
 

xiaofan

High Supremacy Member
Joined
Sep 16, 2018
Messages
35,801
Reaction score
12,038
The above is kind of interesting.

I checked my virtual OpenWRT installations (both using Intel N100 CPU and Proxmox PVE) and indeed Software Flow Offloading is not enabled.

But then usually we will need to enable HW/SW Flow Offloading when using wireless router running OpenWRT since often the CPU may be weak and not able to handle 1Gbps routing without HW/SW Flow Offloading.
 

xiaofan

High Supremacy Member
Joined
Sep 16, 2018
Messages
35,801
Reaction score
12,038
OpenWRT WiFi 7 support -- mainly on MediaTek MT7988A (Filogic 880) and MT7988D (Filogic 860) as of now.

The better support one is Banana Pi BPI-R4 + MT7995AV WiFi 7 module, with official support in 24.10 release.
https://openwrt.org/inbox/toh/sinovoip/bananapi_bpi-r4
https://openwrt.org/toh/hwdata/sinovoip/sinovoip_banana_pi_bpi-r4

Asus ZenWiFi BT8 support -- MT7988D (snapshot release only)
https://forum.openwrt.org/t/support-for-asus-zenwifi-bt8-tri-band-wifi7-mediatek-mt7988/220023/210
https://github.com/openwrt/openwrt/pull/18243
https://downloads.openwrt.org/snapshots/targets/mediatek/filogic/
 
Important Forum Advisory Note
This forum is moderated by volunteer moderators who will react only to members' feedback on posts. Moderators are not employees or representatives of HWZ Forums. Forum members and moderators are responsible for their own posts. Please refer to our Community Guidelines and Standards and Terms and Conditions for more information.
Top