Debian for Orange Pi RV2 and R2S

I couldn't find any existing ready-made bootable image of Debian for the Orange Pi RV2, so I made one myself.

It is a very minimal command-line only system, no GUI. Should be possible to install one if you need it.

Headless operation is possible, after boot-up it grabs an IP on Ethernet using DHCP (check your router logs or UI for which IP it got), then you can login by SSH.

Username is root, password is orangepi.

Orange Pi R2S works

I've confirmed this image also works on the R2S board. The DTB used is still from RV2, the system thinks it is an RV2, but I don't think this is affecting anything in any practical way. The additional dual 2.5 GbE Realtek NICs are detected just fine, as well as the onboard eMMC. May need to add the Realtek firmware package in a future release, but the currently used kernel appears to integrate the Realtek vendor driver, which includes the firmware.

To boot this image on the R2S, put your SD card into an USB card reader and plug it into the blue USB 3.0 port (the white USB 2.0 port may not support booting). Any other USB storage media may also be used, including Flash sticks, SSD and HDD. Booting from USB has a higher priority than from eMMC, so the image will boot right away. Then you can use nand-sata-install to move the system to eMMC. As such, it is not a huge deal at all that the board doesn't have an SD-card slot.

2025-09-06: v3

  • Added packages: curl dialog ethtool file ntpsec-ntpdate pciutils time usbutils wget zstd wireless-tools wpasupplicant
  • nand-sata-install now works out of the box (install dialog to make it work on previous releases)

2025-08-23: v2

  • Disabled auto-login on HDMI and serial consoles. To disable that on the previously released image, delete these files:
    • /usr/lib/systemd/system/getty@.service.d/override.conf
    • /usr/lib/systemd/system/serial-getty@.service.d/override.conf
  • Added packages: eatmydata manpages man-db btrfs-progs xfsprogs. Let me know of any small but essential packages you think it'd be nice to have from the get-go.
  • Switched from 'performance' to 'ondemand' CPU governor by default.

How it was made

Inspired by and based on this comment by misterhsp.

Had to “add Trixie support” into their build scripts, basically adding “trixie” everywhere “bookworm” is mentioned, or cloning entries and copying folders for bookworm and naming them trixie: orangepi-build-trixie-v3.patch

This was built on an amd64 Trixie system. The build scripts install some dependencies automatically (and hence want 'root'), and some need to be installed manually:

apt-get install build-essential linux-base lz4 git imagemagick qemu-user-static binfmt-support uuid-runtime acl psmisc sudo

With all dependencies installed and having the patched scripts, it is possible to run:

export NO_HOST_RELEASE_CHECK=yes
LANG=C ./build.sh  BOARD=orangepirv2 BRANCH=current BUILD_OPT=image RELEASE=trixie BUILD_MINIMAL=yes BUILD_DESKTOP=no KERNEL_CONFIGURE=no GOVERNOR=ondemand

Kernel

This image currently uses the vendor 6.6.63 kernel. Diffing that to the vanilla 6.6.63 yields a 140 MB patch. Tried bumping the version of vanilla somewhat and checking if patch still cleanly applies, was successful up to 6.6.75 inclusive, until the first conflict. Might be something to explore, if nothing else, it should be possible to get the latest 6.6 series here (6.6.102 as of now).

There is also a 6.15 (at least) kernel, supporting Orange Pi RV2.

Performance

One random observation, running an OpenSSL ChaCha20 benchmark (openssl speed -evp chacha20) gets around 10 times higher performance compared to what I got on the vendor Ubuntu image. OpenSSL in Trixie is somewhat newer and now prints a list of RISC-V extensions during the test, supposedly it did not use any of those in Ubuntu.

Given the nascent nature of RISC-V, any update to newer software or distro might bring huge leaps in performance, sometimes simply because exactly the same software was built by a newer compiler.

Contact me

If you have any questions or suggestions, you can reach me by E-Mail, or in Reddit comments.


rv-debian.txt · Last modified: 2025-09-06 20:06 UTC by rm