PINE64
OpenWRT on the Rock64 - Printable Version

+- PINE64 (https://forum.pine64.org)
+-- Forum: ROCK64 (https://forum.pine64.org/forumdisplay.php?fid=85)
+--- Forum: General Discussion on ROCK64 (https://forum.pine64.org/forumdisplay.php?fid=86)
+--- Thread: OpenWRT on the Rock64 (/showthread.php?tid=16305)

Pages: 1 2


OpenWRT on the Rock64 - CanadianBacon - 03-12-2022

I have started the process of getting OpenWRT working on the Rock64.

I have a working image alongside a custom repo for packages which can be found here, download links for the SD Card images are front and centre: https://openwrt.cdnbcn.net/

When installing the SD Card image, you will have to manually configure /etc/opkg/distfeeds.conf with my custom repo, however I'll fix this in a later build.

The main issues currently are as follows:
    - USB3 port isn't working
    - Onboard Ethernet doesn't reset correctly 100% of the time

The source code can be found at https://github.com/CanadianBaconBoi/openwrt/tree/rock64.
It is based on the work of lucize however it has been updated for a modern version of OpenWRT.

There is a thread with some fixes for the aforementioned issues below, however I have been short on time recently and haven't been able to get around to implementing them yet.
https://forum.pine64.org/showthread.php?tid=11012

Any help would be greatly appreciated in pulling these in, I'll continue to host the package repo for free until this is pulled into upstream.


RE: OpenWRT on the Rock64 - helpmerock - 03-14-2022

Thanks, CanadianBacon,

Used win32diskimager - did not work. Used Linux - dd method did not work.

mine Rock64 is V2 - No USB boot enable. (https://github.com/ayufan-rock64/linux-build/blob/master/recipes/flash-spi.md)

What's your version? Did you enable USB boot in past? If yes, it sometimes does not boot with regular images.


RE: OpenWRT on the Rock64 - CanadianBacon - 03-14-2022

(03-14-2022, 08:18 AM)helpmerock Wrote: Thanks, CanadianBacon,

Used win32diskimager - did not work. Used Linux - dd method did not work.

mine Rock64 is V2 - No USB boot enable. (https://github.com/ayufan-rock64/linux-build/blob/master/recipes/flash-spi.md)

What's your version? Did you enable USB boot in past? If yes, it sometimes does not boot with regular images.

I have a Rock64 V2 also and I haven't enabled USB boot.

I'll outline the exact steps I took;
1. Download SD card image from here
2. Open CMD and run gzip -d `openwrt-snapshot-r19092-7abce5da96-rockchip-armv8-pine64_rock64-ext4-sysupgrade.img.gz` to decompress in place
3. Open Win32DiskImager, select image, and burn to SD card.
4. Connect Ethernet on rock64 to laptop
5. ssh into root@192.168.1.1


RE: OpenWRT on the Rock64 - helpmerock - 03-15-2022

Thanks CanadianBacon,

First Bad news: I tried all as well as another SD card but did not boot.
Now, Good News: I installed old OpenWrt then for the firmware update - used your image. It worked.

Now, I have to play & let you know.

I could not update file: distfeeds.conf. When I inserted the SD card in Linux & try to edit - it says read ONLY.

Can I update in GUI in OpenWRT?


RE: OpenWRT on the Rock64 - CanadianBacon - 03-15-2022

(03-15-2022, 09:41 AM)helpmerock Wrote: Thanks CanadianBacon,

First Bad news: I tried all as well as another SD card but did not boot.
Now, Good News:  I installed old OpenWrt then for the firmware update - used your image. It worked.

Now, I have to play & let you know.

I could not update file: distfeeds.conf. When I inserted the SD card in Linux & try to edit - it says read ONLY.

Can I update in GUI in OpenWRT?

On my image distfeeds.conf is editable, it's possible the old image you have mounts it as readonly, you could try to modify the image you have.
You should also make sure you are root when you edit the file.


RE: OpenWRT on the Rock64 - CT456 - 03-31-2022

(03-14-2022, 01:44 PM)CanadianBacon Wrote:
(03-14-2022, 08:18 AM)helpmerock Wrote: Thanks, CanadianBacon,

Used win32diskimager - did not work. Used Linux - dd method did not work.

mine Rock64 is V2 - No USB boot enable. (https://github.com/ayufan-rock64/linux-build/blob/master/recipes/flash-spi.md)

What's your version? Did you enable USB boot in past? If yes, it sometimes does not boot with regular images.

I have a Rock64 V2 also and I haven't enabled USB boot.

I'll outline the exact steps I took;
1. Download SD card image from here
2. Open CMD and run gzip -d `openwrt-snapshot-r19092-7abce5da96-rockchip-armv8-pine64_rock64-ext4-sysupgrade.img.gz` to decompress in place
3. Open Win32DiskImager, select image, and burn to SD card.
4. Connect Ethernet on rock64 to laptop
5. ssh into root@192.168.1.1

worked for me Smile
big thanks

for second ethernet I connected TP-Link UE300 (kmod-usb-net-rtl8152) with USB2 port, USB3 not functioning like you said

opkg update not working with custom repo!

Updated list of available packages in /var/opkg-lists/openwrt_core
Downloading https://openwrt.cdnbcn.net/targets/rockchip/armv8/packages/Packages.sig
Signature check failed.
Remove wrong Signature file.


RE: OpenWRT on the Rock64 - anchor00 - 06-10-2022

(03-14-2022, 08:18 AM)helpmerock Wrote: Thanks, CanadianBacon,

Used win32diskimager - did not work. Used Linux - dd method did not work.

mine Rock64 is V2 - No USB boot enable. (https://github.com/ayufan-rock64/linux-build/blob/master/recipes/flash-spi.md)

What's your version? Did you enable USB boot in past? If yes, it sometimes does not boot with regular images.

I had the same issue, but after hooking up a serial cable it turns out the issue is that I flashed ayufans spi-boot image a long time ago and that version of u-boot was incapable of decompressing the kernel used in this openwrt image.  The fix was erasing the spi, so the uboot version on the sdcard could handle the kernel decompression.


RE: OpenWRT on the Rock64 - pescew - 09-15-2022

Is it possible to flash and boot this from SPI?


RE: OpenWRT on the Rock64 - wilsonYan - 10-23-2022

i've finally got around to doing a new build of openwrt for the rock64 (sdcard) (it's headless no hdmi)

Using latest glibc / linux kernel 5.15.77 / switched to firewall4  / added bridger / watchcat / basic samba4 network sharing


https://disk.yandex.com/d/K4d4knF7iBqkHw                  ext4    (just use this one if you don't know)
https://disk.yandex.com/d/IG8mO4kMOPetwQ               squashfs
https://disk.yandex.com/d/Bh6bzY-V76XqPQ                   rootfs

NOTES :
* for some reason mount points don't seem super solid so you'll have to edit fstab manually perhaps or add a mount command in the startup or /etc/rc.local
* using samba4 because ksmbd runs out of memory on large files, but samba4 also runs out of memory unless you tick "force syncronous i/o"
* I decided to try dropping dropbear in favor of sshd, this might mean you have to set a root password  via the web interface before you can ssh in (it might not)
* included patches to enable usb3.0 phy/dmc/rng drivers from here
* USB3 port might actually be stable, this image tries enabling a couple of dwc3 quirks normally on other socs

EDIT:
Just did one last update to incorporate https://github.com/openwrt/openwrt/pull/11163 (but for all targets). the ax88179, seems to benefit from using the performance governor or increasing the minimum scaling frequency.
eg. "echo performance > /sys/bus/cpu/devices/cpu0/cpufreq/scaling_governor"
You can have this setting go through on bootup by putting the line in the "system -> startup -> local startup" section.
If you use software flow offload for the firewall you can also add "nft add flowtable inet fw4 ft { counter }" to make traffic counting work.
That's the last one from me for a while.


RE: OpenWRT on the Rock64 - wilsonYan - 11-05-2022

Did a final refresh today and plan on leaving it for a while. Added a few more things like nload and btop (works nicely with kde konsole)

Anyway, this build appears to be definitely usable as a basic firewall when connected to a switch with vlan support or using usb adapters, the wireguard functionality also works, I haven't tested any wireless. The only major annoyance with it is the USB3 port may be limited bi-directionally to 1gbps or so BUT it is reliable with a rtl8153 adapter; which I can confirm can send and recieve simultaneously over 950 mbits/s on iperf3. So I assume it is then capable of routing a 1gb/s internet connection since the onboard nic also is capable of those speeds.