Bedis9 website

RockPi S (un)freezing

Posted on 2026-20-04

The Rock Pi S is a powerhouse in a tiny form factor, but it is notoriously sensitive. If you are experiencing hard freezes where SSH drops and the serial console goes silent, you aren't alone.

This guide documents the journey from a "frozen" board to a rock-solid running system.

The Symptoms of a "frozen" Board

Random freezes on the Rock Pi S often don't leave a "smoking gun" in the logs. When the system hangs, it typically manifests as:

  • D-Bus Gridlock: Commands like systemctl status or reboot time out.
  • Kernel Wait: The command df -h hangs indefinitely.
  • Protocol Errors: Systemd fails to fork new processes with a "Protocol error" message.

If your CPU and RAM aren't spiking, the issue is almost certainly a filesystem I/O hang or voltage instability.

The Silent Killer: Hard NFS Mounts

The most frequent cause of system-wide lockups on small boards is a "hard" NFS mount. By default, many Linux systems use hard mounts, which tell the kernel to wait forever if the NAS goes offline.

On a Rock Pi S, this creates a "suicide pact" between the board and the network. If a single packet is lost, the kernel enters an uninterruptible sleep, blocking D-Bus and eventually freezing the entire OS.

The Fix: Update your /etc/fstab to use "soft" mounts with aggressive timeouts:

NFS:/volume1/share  /mnt/tmp  nfs  rw,soft,intr,timeo=50,retrans=3,noatime 0 0

Taming the RK3308: The Stability Ladder

The Rockchip RK3308 is sensitive to voltage ripples. Rapid frequency switching (the ondemand governor) can cause micro-sags in power that crash the MMC controller.

To ensure 100% uptime for critical services like HAProxy, we use a "Stability Ladder" approach.

Underclocking for Reliability

Set the CPU to a fixed, lower frequency. This eliminates voltage spikes and keeps the board cool.

# Set to 408 MHz permanently in /etc/default/cpufrequtils
MIN_SPEED=408000
MAX_SPEED=408000
GOVERNOR=performance

While 408 MHz sounds slow, HAProxy is an I/O-driven beast. It handles SSL termination and reverse proxying remarkably well at this speed, as long as the network throughput remains within the Fast Ethernet limits.

Also note that I'm still in "recovery phase" on this device and I'll increase CPU speed to 600 then 816MHz.

Optimizing HAProxy for Low-Power Boards

If you are terminating SSL at 408 MHz, efficiency is your only friend.

  • Use ECDSA Certificates: Elliptic Curve math is significantly lighter on the ARMv8 architecture than traditional RSA.
  • Enable Session Resumption: Avoid full handshakes by allowing clients to resume TLS sessions.
  • Local Logging: Never log HAProxy activity directly to an NFS share. Use a local RAM log to prevent I/O wait-states.

Summary Checklist

  1. Power: Use a high-quality 5V/2A supply and a short USB-C cable.
  2. NFS: Switch all network mounts to soft,intr.
  3. CPU: Lock the governor to performance at a stable frequency.

By moving from a "reactive" frequency scaling to a "static" stable state, the Rock Pi S transforms from a hobbyist toy into a reliable piece of infrastructure.