OpenWRT

OpenWRT is one of the most popular router/firewalls in the world. Many ISP and WiFi router manufacturers uses it widely. It runs on mnimum HW and for that it's just what the lab needs. #openwrt #router #firewall

OpenWRT

A free open source firewall and router for homelabs and WiFi devices. Networking is the essential thing in all IT and we use a lot of subnets and VLANs in oure homelabs. For any homelab you need a set of routers. My latest routers are all on OpenWrt. That said I still love my pfSense but I like to try different stuff. First I hade some problems but this way is easy and fast to implement router VMs. I love OpenWrt because it's tiny and therefore suitable for running all over the place, as a router on Proxmox, WiFi boxes and RspberryPis.

Pre work

OpenWRT has a reputation to be hard to install - it's not. Just follow a few easy steps.

  1. First create a VM and install a live image of any Linux desktop you like.
  2. In that desktop I use the Browser to locate and download the latest image of the OpenWrt (generic-squashfs-combined.img.gz) and
  3. download it and
  4. extract it with gunzip.
  5. Now place the file on the disk and reboot the VM.
I'm using openwrt-23.05.0-rc2-x86-64-generic-squashfs-combined.img.gz

For HW recommendations see my article on pfSense link

Installation

When the VM boots up it's time to do the install.

  1. In the console type these 5 commands, use any IP address you like and can use.
uci set network.lan.ipaddres=192.0.2.1
uci set network.lan.gateway=192.0.2.1
uci set network.lan.dns=1.1.1.1
uci commit network
reboot

You shouldn't need this but ...

opkg install luci
/etc/init.d/uhttpd start
reboot

After a new reboot you can login to the VM over the network and first you shold set a strong and complicated password for the router.

Set the password - a long and complicated one

Configuration

You need to plan the network and the firewall from to your needs. This below is just a example of some things.


References

OpenWRT home [1] OpenWRT [2] Documentation [3]


  1. OpenWRT home page ↩︎

  2. On wikipedia ↩︎

  3. Read more in the userguid also see FAQ or ask on the forum ↩︎