RPI5 & Package Manager Issues

Good day to all!

I have been working with OpenWRT since 2016 off and on. Prior to last week I normally would use OpenWRT on actual existing routers. However, recently with the huge push for ISPs providing more than just single gigabit networks I have discovered port compatibility issues with ASUS consumer hardware.

Long story short I added a dual RTL8125 2.5Gbe HAT to my RPI5 that was laying around and walla, ASUS hardware now works great as an AP with the RPI5 handles to ONT - AP Routing, even at 2.5Gbe speeds.

I was not prepared for the removal of opkg as the SNAPSHOT builder does not recognize opkg nor apk-tools. I have my RPI5 on a newer snapshot now because I tried using an "upgrade" path and it corrupted the previous SNAPSHOT I had working.

Did I back it up? No, that would have been smart!

So now to my ask or request.

As I am not a wizard with OpenWRT linux I have yet to find a page on how to install packages using WGET or the link from the internet. Current SNAPSHOT does NOT have opkg nor apk and im not versed on how to manually add either of these packages back without rebuilding a new image using some of the information from this forum.

For my use case I must have r8169-firmware & kmod for my ethernet HAT to work.

Any help would be greatly appreciated!

PS. SNAPSHOTS are the ONLY currently supported build version that works on RPI5.

root@OpenWrt:~# ubus call system board
{
        "kernel": "6.6.60",
        "hostname": "OpenWrt",
        "system": "ARMv8 Processor rev 1",
        "model": "Raspberry Pi 5 Model B Rev 1.0",
        "board_name": "raspberrypi,5-model-b",
        "rootfs_type": "ext4",
        "release": {
                "distribution": "OpenWrt",
                "version": "SNAPSHOT",
                "revision": "r28085-6720c4ccba",
                "target": "bcm27xx/bcm2712",
                "description": "OpenWrt SNAPSHOT r28085-6720c4ccba",
                "builddate": "1731585818"
        }
}

root@OpenWrt:~# find /lib/apk/packages
/lib/apk/packages
/lib/apk/packages/base-files.conffiles
/lib/apk/packages/base-files.conffiles_static
/lib/apk/packages/base-files.list
/lib/apk/packages/bcm27xx-gpu-fw.list
/lib/apk/packages/bcm27xx-utils.list
/lib/apk/packages/brcmfmac-firmware-usb.list
/lib/apk/packages/brcmfmac-nvram-43455-sdio.list
/lib/apk/packages/busybox.conffiles
/lib/apk/packages/busybox.conffiles_static
/lib/apk/packages/busybox.list
/lib/apk/packages/busybox.rusers
/lib/apk/packages/ca-bundle.list
/lib/apk/packages/cgi-io.list
/lib/apk/packages/cypress-firmware-43455-sdio.list
/lib/apk/packages/dnsmasq.conffiles
/lib/apk/packages/dnsmasq.conffiles_static
/lib/apk/packages/dnsmasq.list
/lib/apk/packages/dnsmasq.rusers
/lib/apk/packages/dropbear.alternatives
/lib/apk/packages/dropbear.conffiles
/lib/apk/packages/dropbear.conffiles_static
/lib/apk/packages/dropbear.list
/lib/apk/packages/e2fsprogs.conffiles
/lib/apk/packages/e2fsprogs.conffiles_static
/lib/apk/packages/e2fsprogs.list
/lib/apk/packages/firewall4.conffiles
/lib/apk/packages/firewall4.conffiles_static
/lib/apk/packages/firewall4.list
/lib/apk/packages/fstools.list
/lib/apk/packages/fwtool.list
/lib/apk/packages/getrandom.list
/lib/apk/packages/hostapd-common.list
/lib/apk/packages/iw.list
/lib/apk/packages/iwinfo.list
/lib/apk/packages/jansson.list
/lib/apk/packages/jshn.list
/lib/apk/packages/jsonfilter.list
/lib/apk/packages/kernel.list
/lib/apk/packages/kmod-brcmfmac.list
/lib/apk/packages/kmod-brcmutil.list
/lib/apk/packages/kmod-cfg80211.list
/lib/apk/packages/kmod-crypto-crc32c.list
/lib/apk/packages/kmod-crypto-hash.list
/lib/apk/packages/kmod-fs-vfat.list
/lib/apk/packages/kmod-hid-generic.list
/lib/apk/packages/kmod-hid.list
/lib/apk/packages/kmod-hwmon-core.list
/lib/apk/packages/kmod-hwmon-pwmfan.list
/lib/apk/packages/kmod-input-core.list
/lib/apk/packages/kmod-input-evdev.list
/lib/apk/packages/kmod-lib-crc-ccitt.list
/lib/apk/packages/kmod-lib-crc32c.list
/lib/apk/packages/kmod-libphy.list
/lib/apk/packages/kmod-mdio-devres.list
/lib/apk/packages/kmod-mii.list
/lib/apk/packages/kmod-mmc.list
/lib/apk/packages/kmod-nf-conntrack.list
/lib/apk/packages/kmod-nf-conntrack6.list
/lib/apk/packages/kmod-nf-flow.list
/lib/apk/packages/kmod-nf-log.list
/lib/apk/packages/kmod-nf-log6.list
/lib/apk/packages/kmod-nf-nat.list
/lib/apk/packages/kmod-nf-reject.list
/lib/apk/packages/kmod-nf-reject6.list
/lib/apk/packages/kmod-nfnetlink.list
/lib/apk/packages/kmod-nft-core.list
/lib/apk/packages/kmod-nft-fib.list
/lib/apk/packages/kmod-nft-nat.list
/lib/apk/packages/kmod-nft-offload.list
/lib/apk/packages/kmod-nls-base.list
/lib/apk/packages/kmod-nls-cp437.list
/lib/apk/packages/kmod-nls-iso8859-1.list
/lib/apk/packages/kmod-nls-utf8.list
/lib/apk/packages/kmod-phy-realtek.list
/lib/apk/packages/kmod-ppp.list
/lib/apk/packages/kmod-pppoe.list
/lib/apk/packages/kmod-pppox.list
/lib/apk/packages/kmod-r8169.list
/lib/apk/packages/kmod-slhc.list
/lib/apk/packages/kmod-sound-arm-bcm2835.list
/lib/apk/packages/kmod-sound-core.list
/lib/apk/packages/kmod-thermal.list
/lib/apk/packages/kmod-usb-core.list
/lib/apk/packages/kmod-usb-hid.list
/lib/apk/packages/libblkid.list
/lib/apk/packages/libblobmsg-json.list
/lib/apk/packages/libc.list
/lib/apk/packages/libcomerr.list
/lib/apk/packages/libe2p.list
/lib/apk/packages/libext2fs.list
/lib/apk/packages/libf2fs.list
/lib/apk/packages/libfdt.list
/lib/apk/packages/libgcc.list
/lib/apk/packages/libiwinfo-data.list
/lib/apk/packages/libiwinfo.list
/lib/apk/packages/libjson-c.list
/lib/apk/packages/libjson-script.list
/lib/apk/packages/liblucihttp-ucode.list
/lib/apk/packages/liblucihttp.list
/lib/apk/packages/libmbedtls.list
/lib/apk/packages/libmnl.list
/lib/apk/packages/libnftnl.list
/lib/apk/packages/libnl-tiny.list
/lib/apk/packages/libpthread.list
/lib/apk/packages/librt.list
/lib/apk/packages/libsmartcols.list
/lib/apk/packages/libss.list
/lib/apk/packages/libubox.list
/lib/apk/packages/libubus.list
/lib/apk/packages/libuci.list
/lib/apk/packages/libuclient.list
/lib/apk/packages/libucode.list
/lib/apk/packages/libudebug.list
/lib/apk/packages/libustream-mbedtls.list
/lib/apk/packages/libuuid.list
/lib/apk/packages/logd.alternatives
/lib/apk/packages/logd.list
/lib/apk/packages/logd.rusers
/lib/apk/packages/luci-app-firewall.list
/lib/apk/packages/luci-app-package-manager.list
/lib/apk/packages/luci-base.conffiles
/lib/apk/packages/luci-base.conffiles_static
/lib/apk/packages/luci-base.list
/lib/apk/packages/luci-light.list
/lib/apk/packages/luci-mod-admin-full.list
/lib/apk/packages/luci-mod-network.list
/lib/apk/packages/luci-mod-status.list
/lib/apk/packages/luci-mod-system.list
/lib/apk/packages/luci-proto-ipv6.list
/lib/apk/packages/luci-proto-ppp.list
/lib/apk/packages/luci-theme-bootstrap.list
/lib/apk/packages/luci.list
/lib/apk/packages/mkf2fs.list
/lib/apk/packages/mtd.list
/lib/apk/packages/netifd.conffiles
/lib/apk/packages/netifd.conffiles_static
/lib/apk/packages/netifd.list
/lib/apk/packages/nftables-json.list
/lib/apk/packages/odhcp6c.conffiles
/lib/apk/packages/odhcp6c.conffiles_static
/lib/apk/packages/odhcp6c.list
/lib/apk/packages/odhcpd-ipv6only.list
/lib/apk/packages/openwrt-keyring.list
/lib/apk/packages/partx-utils.list
/lib/apk/packages/ppp-mod-pppoe.list
/lib/apk/packages/ppp.conffiles
/lib/apk/packages/ppp.conffiles_static
/lib/apk/packages/ppp.list
/lib/apk/packages/procd-seccomp.list
/lib/apk/packages/procd-ujail.list
/lib/apk/packages/procd.list
/lib/apk/packages/procd.rusers
/lib/apk/packages/r8169-firmware.list
/lib/apk/packages/rpcd-mod-file.list
/lib/apk/packages/rpcd-mod-iwinfo.list
/lib/apk/packages/rpcd-mod-luci.list
/lib/apk/packages/rpcd-mod-rrdns.list
/lib/apk/packages/rpcd-mod-ucode.list
/lib/apk/packages/rpcd.conffiles
/lib/apk/packages/rpcd.conffiles_static
/lib/apk/packages/rpcd.list
/lib/apk/packages/ubox.alternatives
/lib/apk/packages/ubox.conffiles
/lib/apk/packages/ubox.conffiles_static
/lib/apk/packages/ubox.list
/lib/apk/packages/ubus.list
/lib/apk/packages/ubusd.list
/lib/apk/packages/ubusd.rusers
/lib/apk/packages/uci.list
/lib/apk/packages/uclient-fetch.alternatives
/lib/apk/packages/uclient-fetch.list
/lib/apk/packages/ucode-mod-fs.list
/lib/apk/packages/ucode-mod-html.list
/lib/apk/packages/ucode-mod-math.list
/lib/apk/packages/ucode-mod-nl80211.list
/lib/apk/packages/ucode-mod-rtnl.list
/lib/apk/packages/ucode-mod-ubus.list
/lib/apk/packages/ucode-mod-uci.list
/lib/apk/packages/ucode-mod-uloop.list
/lib/apk/packages/ucode.list
/lib/apk/packages/uhttpd-mod-ubus.list
/lib/apk/packages/uhttpd.conffiles
/lib/apk/packages/uhttpd.conffiles_static
/lib/apk/packages/uhttpd.list
/lib/apk/packages/urandom-seed.list
/lib/apk/packages/usign.list
/lib/apk/packages/wifi-scripts.list
/lib/apk/packages/wireless-regdb.list
/lib/apk/packages/wpad-basic-mbedtls.list
/lib/apk/packages/wpad-basic-mbedtls.rusers

Made a new snap this morning with the following packages for the RPI5.

**Defaults:**
base-files bcm27xx-gpu-fw bcm27xx-utils ca-bundle dnsmasq dropbear e2fsprogs firewall4 fstools kmod-fs-vfat kmod-nft-offload kmod-nls-cp437 kmod-nls-iso8859-1 kmod-sound-arm-bcm2835 kmod-sound-core kmod-usb-hid libc libgcc libustream-mbedtls logd mkf2fs mtd netifd nftables odhcp6c odhcpd-ipv6only partx-utils ppp ppp-mod-pppoe procd-ujail uci uclient-fetch urandom-seed cypress-firmware-43455-sdio brcmfmac-nvram-43455-sdio kmod-brcmfmac wpad-basic-mbedtls kmod-hwmon-pwmfan kmod-thermal iwinfo luci 

*Add-Ons:*
r8169-firmware 
kmod-r8169 
apk 
ethtool-full 
owut 
attendedsysupgrade-common 
luci-app-attendedsysupgrade 
swconfig 
kmod-swconfig

I grabbed both the upgrade and full images and Ill give it a try later today. Does anyone have any input on what other packages would be useful in this situation? I assume the apk one I added is the tool I need for the CLI commands to work?

Yes, that should work (or you could be more specific and specify the apk-mbedtls package directly, but that's the default).

$ apk info apk
apk-mbedtls-3.0.0_pre20241108-r2 description:
apk package manager (mbedtls)

apk-mbedtls-3.0.0_pre20241108-r2 webpage:
https://gitlab.alpinelinux.org/alpine/apk-tools.git

apk-mbedtls-3.0.0_pre20241108-r2 installed size:
320 KiB

apk-mbedtls-3.0.0_pre20241108-r2 description:
apk package manager (mbedtls)

apk-mbedtls-3.0.0_pre20241108-r2 webpage:
https://gitlab.alpinelinux.org/alpine/apk-tools.git

apk-mbedtls-3.0.0_pre20241108-r2 installed size:
320 KiB

apk-openssl-3.0.0_pre20241108-r2 description:
apk package manager (openssl)

apk-openssl-3.0.0_pre20241108-r2 webpage:
https://gitlab.alpinelinux.org/alpine/apk-tools.git

apk-openssl-3.0.0_pre20241108-r2 installed size:
320 KiB

And note that owut is still broken due to the missing ubus packagelist call on SNAPSHOT...

1 Like

You're using snapshots of OpenWrt main, but you can also use snapshots of the 24.10 release branch. 24.10 will be the next OpenWrt stable release series, but there haven't been any release candidates yet, let alone a final release. For now, 24.10 still uses opkg, but the apk migration may come there as well if they can work out the issues it currently has in OpenWrt main.

1 Like

Honestly, as dumb as it sounds my only issue was getting the apk package into the snapshots. APK is just as easy to use as opkg. Alpines documentation was easy to understand. Now that I know that I have to explicitly call apk in builder bot.

Where I got hung up is I wanted to do it from CLI like I would in a Debian desktop distro but I'm just not experienced enough to know how to do that with OpenWRT.

apk-tools does not work in the builder bot meaning the snapshot has no CLI commands for apk nor another package manager to pull it in.

I looked in the database for packages and found apk was the package name I needed. Probably could clean up a bunch of misunderstandings by just copying Alpines documentation and change apk to apk-tools in the repository or make a page for APK on OpenWRT and make sure the package name is the same as the OpenWRT repository.

While you may have sorted out this particular issue involving apk, the thing to keep in mind is that OpenWrt main is the absolute bleeding edge branch of OpenWrt, and can incorporate major changes like this at any time, and potentially catch you off guard. It's akin to Debian sid, but for your network infrastructure. It's intended primarily for developers and secondary test routers.

Snapshots (both main and release branch) are also untested, and require more frequent updating, because when installing additional packages on a live install you can run into kernel version dependency issues if your kernel is even slightly out of date.

Personally, as a non-developer, I try to stick to the latest stable release or the latest release candidate. If neither of those support my hardware, I may consider a release branch snapshot, but that's as far as I go. I do keep track of main on git and the openwrt-devel archive to know where OpenWrt is headed, but I don't run it myself.

I do have a Pi 5 and am interested in the dual 2.5 GbE HAT you mention. Where did you get it? Do you mean this one?

Yes that's the one. I have a PCIe switch and an NVME M.2 HAT. The PCIe switch I got though doesn't support booting behind the PCIe switch, nor the 2.5Gbe HAT. There is supposed to be another board coming out soon for the PCIe switch that supports stuff behind it better.

I got interesting things planned for this. Im gonna move to ubuntu and docker openWRT after I get everything sorted.

I watched a video that Pi5 is capable of routing up to 6Gbps so Im gonna see how hard I can push it and some other stuff.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.