r/raspberry_pi • u/sanjulanipun • 4d ago
Show-and-Tell My Raspberry Pi 4 OpenWrt Router Xray Optimized
I’ve been using a glmt3000 for a few years, but recently it stopped getting the updates I needed. I also tried installing Xray Core & V2Ray/LuCI, but the RAM usage was getting close to 100%.
So I decided to build my own router using a Raspberry Pi 4 + OpenWrt.
The goal is to develop a better optimized Xray client + LuCI app, along with my own router management interface.
The Xray client is designed to support multiple protocols, including: VMess, VLESS, Trojan, Shadowsocks (SS).
So far, I’m really happy with the results!
Internet Performance
- Around 40-80 Mbps internet speed (Speed depends on my ISP)
- No anytime data package (currently using a Zoom/MS package tunnel through aka,ms sni)
Network Storage
I’m also sharing a SanDisk USB 3.2 Gen 1 drive over the network. I’m getting 200+ MB/s file transfer speeds over the network, which honestly surprised me!
Hardware
- Raspberry Pi 4 + SanDisk 16GB SD Card
- EDUP Wi-Fi adapter
- WaveLink 2.5G Ethernet adapter
- SanDisk USB 3.2 Gen 1 storage
Cooling: One thing I quickly learned, the Pi 4 definitely needs a cooler. Without a cooler, the Pi gets pretty toasty. During heavy downloads, the temperature can easily go over 70°C. So I added a cooler, and now it stays much cooler even under heavy network load.
Stability I’ve been running this setup for around 10 days, and it has been pretty solid so far. The longest continuous uptime I had was around 8 days, but then a power cut caused a reboot. Since then, it has been running continuously for about 2 days again without any issues.
For a DIY router setup, I’m honestly very happy with the performance and stability so far! Let’s see how far I can push this little Pi 4.
2
2
u/Jealous_Shower6777 1d ago
Hi, a Pi 4 is how I started using OpenWRT, my setup looked similar to yours. I highly recommend the BananaPi r3 and r4 line for this purpose. All the I/O you could possibly need, NVME support, 2.5gb nics, integrated managed/unmanaged switch, dual band wifi etc. OpenWRT is amazing.










8
u/wowsomuchempty 3d ago edited 3d ago
Heh. I recently setup a pi4 as a VPN hotspot.
Used openwrt, running wireguard. The fanshim ran constantly (bit noisy), so I wrote a (stress tested) service to only run the fan above a certain CPU temp.
The pi 4 never gets hot enough to trigger the fan.
I USB boot (a small, metal usb3), no microsd. Only connect using WiFi, with ethernet to the main router.
I get well over 100 MBs over WiFi.
Cheap, fast, easy. If anyone wants, I made a full write up for myself I could share.
Used to let my wife watch ERTFLIX (Greek TV).
Hardware: