I’ve just ordered a nanopi R4S to replace my ISP router, Hopefully it will improve things, I have a 500/70 connection plan and I would like to have SQM to improve my bufferbloat, I know this router can do 1 gigabit up and down with SQM enabled so that shouldn’t be a problem, Just a few things I’m unsure of.
Has I need to flash the openwrt file onto a micro SD, What capacity should I go for? I was thinking something like a 128 GB SanDisk Ultra SDXC.
When flashing the openwrt image there is two options, ext4 or squashfs, Which one is preferable.
I’ve used openwrt before on a few older routers when i was on a much slower connection plan and setup SQM perfectly, However, I don’t want to configure openwrt via the SHH/cams as this will blow my mind, I just want to flash the image on the micro SD card and configure the settings via the web GUI.
If there is anymore stuff I should consider or got any tips please let me know
if you actually need more than 100-200 MB (and that only because of the inefficient f2fs fs overhead), you're doing something wrong - it's a router, not a general purpose server (and you really want to reduce your attack surface on your border gateway).
matter of preference, squashfs allows factory resetting.
What Capacity do you recommend to use on the SD card?
(and you really want to reduce your attack surface on your border gateway) - What do you mean in a non technical way
I was going to flash it with the Squashfs but I’ve seen a few people suggesting to use the ext4 file, what’s the difference? This will be the first time using Openwrt on a SD card I’ve always flashed openwrt on the stock firmwares of routers what support Openwrt, so it’s a learning curve for me,
There’s me thinking I need a good capacity SD, I will just get a 32GB one, Saved me a few quid thanks
Now I know I don’t need a decent SD card, on to the Openwrt image, Which image file did you use to flash Openwrt EXT4/Squashfs?
I’ve always used squashfs when flashing the file on standard routers but this is my first time using a SD card with Openwrt so not sure what’s what.
From the previous comment, Squashfs can do factory reset which I prefer as I’ll be using that until I get more familiar around Openwrt, Has long as I can configure the nanopi R4S via a web browser and not the SHH I should be fine from there, and I can install the SQM, my aim, Openwrt/Nanopi R4S - SQM, UpNp as I’m a gamer
Ive just received the R4S I’ve successfully flashed the SquashFS image on to a 32GB microSD card and all running perfect fine, However I’ve noticed I only have around 98 storage/disk space, What’s the easiest way to increase the capacity?
At the moment I just have UpNp LuCI-App package installed but I will be installing SQM soon and other packages but I will hit a wall soon will the limited storage.
As I’m still learning how openwrt works etc I appreciate if step by step instructions please
Because system upgrades flash an image to the raw flash storage just like your new installation did, wiping the partition table and filesystem etc, you lose any data in the extended area as well and you need to resize the filesystem every time and restore all your data from backups. I chose to use a ext4 filesystem on a usb flash drive and mount it. It usable on OpenWrt and my linux computer.
After a system upgrade on the sd card, I restore my config, reboot and all works as before with access to the data on the usb drive.
I write the statistics data files to the usb drive so I have long term stats etc. and reduce wear on the sd card minimizing the risk of a system failure due to media going bad. I also keep config backups and other data on the usb storage as well as on my pc.
A larger layout will need ext4, but seriously, re-read what slh and you yourself wrote above, and just stick with squashfs. Squashfs is easy - it keeps your settings when you flash an OpenWrt update or reset.
You'll have to work incredibly hard to make use of just ~100MB storage on a gateway router operating system. So don't work so hard. Keep things easy. And for goodness sake, stop worrying about all that unused space on your 32 GB SD card. Let it go to waste already!
No walls in your future. Certainly not soon. Probably never. I'm using squashfs on my R4S with those packages and more and I'm not even close to a wall.
In the unlikely event you ever get close, build your images with the firmware selector and add your packages to its customize list. The squashfs image with packages will be smaller than the alternative of adding the packages to an image later. You'll grab the packages compiled for whatever kernel version snapshot is on if you try snapshot someday. Your packages will already be included no matter what version you choose. It's easier that way. Starting to see the recurring theme here yet ?
Thanks guys for the support, a lot to take in as you can imagine, I guess 100 MiB isn’t to bad, I have just setup DNS over HTTPS which required two packages leaves me now with 44% used.
I’m trying my best to setup SQM with my connection, Trying to get a A+ plus isn’t not playing ball, I do get a A which isn’t to bad considering and is a step up, Link layer I don’t quite understand I’ve just set that to 42 going on some research from other people threads, I use PPPoE - 500/70
Looking at the docs for the nanopi R4S on openwrt it says: If you restart or change settings with SQM, it will reset the CPU affinity and you will need to re-apply settings.
Putting the commands in rc.local should work, assuming the IRQ numbers are somewhat static, which they seem to be. You may want to double check the IRQ numbers in /proc/interrupts and then do a reboot and check again to make sure they stay the same.
#eth0 IRQ on A53 cores echo f > /proc/irq/35/smp_affinity #eth1 IRQ on A53 cores echo f > /proc/irq/87/smp_affinity #eth0 queue on A72 cores echo 30 > /sys/class/net/eth0/queues/rx-0/rps_cpus #eth1 queue on A72 cores echo 30 > /sys/class/net/eth1/queues/rx-0/rps_cpus
I’m not sure if this is still a ongoing issue with the latest openwrt build, Also I’m not good with SHH only the Web GUI interface.
I am no expert on the details of how OpenWrt fills up space with packages, but I can at least share my experience with you. I run snapshot squashfs images built with the firmware selector after adding my custom packages list. This is how much space I have left on my R4S...
,
.
.
.
After adding these packages to the "customize" list.
Note my package list also includes DNS over HTTPS, SQM, VPNs, and several other goodies, and I still 82 MiB free. If you have significantly less free space left, you might give the firmware selector a try to next time you upgrade your image.
I have DOCSIS 3.0 ISP service, so my baseline unloaded latency is nothing to brag about. But layer CAKE on my R4S is definitely an improvement for loaded latency. I've also had no issues with fairness across my home network with WFH video conferencing, Netflix streaming and kids downloading Steam games in parallel. I'm on a 500/20 speed plan though, so I can't comment personally on Gigabit SQM capability - my R4S CPU is grotesquely underutilized.
I tune CAKE on a wired PC, but I rarely make use of it on a wired client. For the most part I'm on WiFi. And that adds another wrinkle to whether the latency is at the Gateway or in the WiFi connection.
The reason I asked was you need to reset the CPU after a SQM change but I’m not sure if this is just when your running the Full gigabit, I’m on a 500/70 plan but having a issue getting A+ on the bufferbloat score.
What’s your bufferbloat score if you don’t mind me asking?
My ISP throughput is a bit variable throughout the day, so I don't get too greedy on my ingress/egress SQM limits. Waveform is a bit inconsistent in my location as well. I do not set manual CPU affinity in irqbalance. Packet steering is checked. Software flow offloading is checked. I'm running SNAPSHOT r25773-766ec55966 on the R4S and dumb AP. With that, here are my Waveform results today.
I thought software offloading would interfere with SQM well from what I’ve read anyways, Not quite sure what packet steering does? I now changed to layer of cake with cake, and seeing better results. Link layer 44 again I haven’t a clue what’s the correct number just going on research again. I think the CPU run on the lowest with SQM enable and not the bigger cores, I wouldn’t have a clue how to manually set the cores up.
Software offloading doesn't help SQM directly, but doesn't interfere with it in my experience. I formerly used an ER-X as my gateway and noticed SQM throughput improved slightly with software flow offloading enabled - perhaps due to it freeing up a little CPU for SQM by offloading the few packets not processing through the CPU for SQM on the WAN interface. I leave it on out of habit. It probably makes no difference at all to SQM throughput on the R4S due to there being plenty of CPU to go around regardless on the R4S.
There is one other thing a little different I have set. I've set the min CPU frequency on all cores to 600 MHz to reduce the need for the clock rate to be increased throughout the day to handle CPU load increases. Either way, my ISP speed is by no means maxing out the R4S CPU.
I think the main R4S forum thread has a few good discussions on packet steering. NanoPi R4S-RK3399 is a great new OpenWrt device
Search/read through that for good info on packet steering, irq affinity, SQM etc.
I’ve just enabled packet steering and installed the Irqbalence package and now getting A+ happy days, I will try the offloading option and see how I get on as well.
Do you have a issue sometimes when you reboot the device something the LAN doesn’t work, Ive had the issue about three times now?